Forum

HomeHomeCoreCoreSamples and oth...Samples and oth...Simple File ExportSimple File Export
Previous
 
Next
New Post
5/8/2010 12:53 AM
 

Here's an example of a simple file export using OWS and SQL data. This sample uses a CSV structure but any structure and layout could be used.

I have included saving the file to a server folder, but at the moment there is an error with this part which I'm short of time to look into so if anyone else identifies this please let me know. The file download for saving works fine.

DOWNLOAD CONFIGURATION

New Post
5/8/2010 1:02 AM
 

The configuration has been corrected and it does now save the CSV file in a server folder.

New Post
5/10/2010 9:04 AM
 

I am including my finished product (minus the security) which adds, edits, and deletes 7 columns in a DB table and writes to a CSV file each time there is a change.

I made some changes to the example.

  • Moved the query and file fuctions to the OnLoad portion so that they run when the save, and delete fuctions are used.
  • Removed the time stamp from the file name because it was throwing an error. If you know how to format the time so that it does not use special charaters I will add that back in.

Sample App

Thanks for your help, it would have taken many days of trial and error without your code.

New Post
5/11/2010 12:18 PM
 

David (or anyone). I hope you have the time to answer a question. We are puzzled why OWS saves the CSV file with every entry wrapped with double quotes and want to know if OWS can save with them removed?

"System","Server","Schedule","Job","Run_Type"

Normally when we save a CSV file from Excel we can open in notepad or similar program and there are not quotes. This is causing havok with the script which pulls the CSV data for further processing.

Thanks...

New Post
5/11/2010 12:35 PM
 

Not sure which example you are pulling from but David's example doesn't include the "s

You can format the output however you want. Look at David's example, line 7. His CSV_Data Action is being defined as [RoleID,GetRoles],[RoleName,GetRoles],[Description,GetRoles]. (no quotes) If you want /don't want quotes, you just format accordingly.

Previous
 
Next
HomeHomeCoreCoreSamples and oth...Samples and oth...Simple File ExportSimple File Export


 

New York, NY • Baltimore, MD • Vienna, VA • St. Louis, MO • Seatle, WA • 410.327.0007 • info@R2Integrated.com

Bookmark & Share Bookmark and Share