Table output to csv format

Discussions about tabulating data in the designer or in batch mode
Darwin13
Posts: 5
Joined: August 23rd, 2017, 2:52 am

Table output to csv format

Postby Darwin13 » August 23rd, 2017, 2:55 am

Can I use the pff file to save the tabulation output as csv file format?

Like this?

[Run Information]
Version=CSPro 6.1
AppType=Tabulation
Operation=All

[Files]
Application=.\PPSnew6.xtb
InputData=.\P2810Y15WX.SRT
OutputTBW=.\PPSnew6.xtb.tbw
Listing=.\PPSnew6.xtb.lst

[UserFiles]
SAVEFILE=.\PPSnew6.csv


[Parameters]
ViewListing=OnError
ViewResults=No

josh
Posts: 1183
Joined: May 5th, 2014, 12:49 pm
Location: Washington DC

Re: Table output to csv format

Postby josh » August 23rd, 2017, 7:32 am

No. You can't save tables as CSV. You can copy and paste them into Excel or save as tab delimited and import that into Excel and then save as CSV from Excel.

You can also use Export Data tool to save the data itself as CSV but not the tables.

Darwin13
Posts: 5
Joined: August 23rd, 2017, 2:52 am

Re: Table output to csv format

Postby Darwin13 » August 23rd, 2017, 9:43 pm

Thanks for the reply Sir, that's what i'm doing, saving the table as tab delimited.
What I want to know is if I could bypass the clicking of the save table button and just run the pff file and it will automatically save the table as tab delimited.
What I'm currently doing now is creating a batch edit program to make the tables and write them to a txt file and run a macro program to convert all those txt file into excel format.

josh
Posts: 1183
Joined: May 5th, 2014, 12:49 pm
Location: Washington DC

Re: Table output to csv format

Postby josh » August 24th, 2017, 7:25 am

Unfortunately there is no way to automate saving the tables in a different format using the pff file.

You can use table viewer from the command line to convert from a .tbw file to tab delimited. The syntax is like:

"c:\Program Files (x86)\CSPro 7.0\TblView.exe" "C:\Users\josh\Documents\CSPro\Examples 7.0\3 - Tabulation\Adding Weights\Weighted Tables.xtb.tbw" /EXPT /TABDELIM mytabdelimfile.txt

Darwin13
Posts: 5
Joined: August 23rd, 2017, 2:52 am

Re: Table output to csv format

Postby Darwin13 » August 25th, 2017, 1:59 am

Thank you so much, this is perfect!!!

manishcspro
Posts: 6
Joined: June 26th, 2017, 2:15 pm

Re: Table output to csv format

Postby manishcspro » September 24th, 2017, 10:30 am

Method to write csvfile so that value of each valuset goes in a seperate column rather creating another row in multiple occurence records in cpro filerwrite logic...

Darwin13
Posts: 5
Joined: August 23rd, 2017, 2:52 am

Re: Table output to csv format

Postby Darwin13 » September 26th, 2017, 1:34 am

Hi Josh, the command line works well with only one table.
Is there a way i can select a specific table if i have more than one table in my tabulation?
And maybe saving all the tables in my tabulation in CSV format?

josh
Posts: 1183
Joined: May 5th, 2014, 12:49 pm
Location: Washington DC

Re: Table output to csv format

Postby josh » September 26th, 2017, 2:01 am

Unfortunately that command only exports the first table. It doesn't handle files that contain more than one table.

Darwin13
Posts: 5
Joined: August 23rd, 2017, 2:52 am

Re: Table output to csv format

Postby Darwin13 » September 27th, 2017, 5:04 am

I see, thanks josh.


Return to “Tabulation”