Jump to content

Schedule reports - files download to file system


carolopia

Recommended Posts

Hello everyone,

I have schedule to many reports to generate the result into a Excel in a folder of Jasperserver. Where are this reports? are in the data base? If are in the database in what table? or are in some file system? I need to put this Excel into a file system, how can I do this?


thanks in advance,


Regards,

Caro.

 

Link to comment
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Thanks for your answer, now I want to know how can I download this file to the file system?

I was trying with a query like "select data from jicontentresource where id  = 1198 into outfile '/user/temp " but when I execute it fail, this is the log: " [sELECT - 0 row(s), 0.000 secs]  [Error Code: 1045, SQL State: 28000]  Access denied for user 'jasperdb'@'%' (using password: YES)"

Somebody knows What can I do??

Thanks in advance,

Regards,

Caro.

Link to comment
Share on other sites

The error you are getting is because your login is invalid or you dont have permission to that table not because your sql failed. 

In order for your output to be formatted correctly add this imediatly after your file name:
FIELDS TERMINATED BY '' ENCLOSED BY '' ESCAPED BY '' LINES TERMINATED BY '' STARTING BY ''

example:
select data from JIContentResource where id=761 into outfile "/tmp/matt.xls" FIELDS TERMINATED BY '' ENCLOSED BY '' ESCAPED BY '' LINES TERMINATED BY '' STARTING BY '';

hope this helps.



Post Edited by mmulligan03 at 08/10/2011 17:12
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...