It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Where should I put the 'opencsv-3.5.jar' file for ScriptRunner to know it?

I tried to put opencsv-3.5.jar on JIRA_HOME/lib (of course I stopped and started Jira) but in behaviour script I still have :

import au.com.bytecode.opencsv.CSVReader : unable to resolve

Is it supposed to be on JDK?

 

regards,

Franck

4 answers

<jira-install>/atlassian-jira/WEB-INF/lib

Hello,

 

Still not working...

Regards,

Franck

Hello,

 

I try to reproduce : http://www.kellyrob99.com/blog/2010/07/01/groovy-and-csv-how-to-get-your-data-out/

 

in fact

import au.com.bytecode.opencsv.CSVReader
leads to an error : unable to resolve class CSVReader
import au.com.bytecode.opencsv
is accepted
but
List<String[]> rows = new CSVReader(        new InputStreamReader(getClass().classLoader.getResourceAsStream(TEST_FILE_NAME)))
            .readAll()
leads to an error : unable to resolve class CSVReader
regards,
Franck

Hi Frack 

As Jamie suggested in a previous post https://answers.atlassian.com/questions/31674855 you can use the JIRA native com.mindprod.csv.CSVReader and then get your file 

CSVReader reader = new CSVReader(new FileReader("yourfile.csv"));

You can find the documentation for it here : http://mindprod.com/application/csv.manual.html

Suggest an answer

Log in or Sign up to answer
This widget could not be displayed.
This widget could not be displayed.
Community showcase
Published Apr 03, 2019 in Marketplace Apps

How to estimate projects more accurately?

Gaining insight into your team’s effectiveness and choosing the right estimation technique.   Estimating projects is hard. It is because people have the tendency to underestimate the time thin...

278 views 2 8
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you