Export data from CSpro 7 to STATA

Discussions about tools to complement CSPro data processing
Andilip
Posts: 2
Joined: July 30th, 2018, 2:12 am

Export data from CSpro 7 to STATA

Postby Andilip » July 30th, 2018, 4:44 am

Hello,
I'm trying to export CSpro data to STATA. I want to create separate do files for all the records (these are all rosters).

During exporting data, when I select ID items and 1 record in the dialogue box 'CSpro Export Data' (multiple files-As separate records- join single with multiple records), exporting creates .dct, .do and .dat files, which is fine.

But, whenever I select more than 1 record, it creates only .dat file for each record. .do and .dct files are not created. Without do files, I'm unable to work with the data in STATA. Any suggestions on how to solve this problem? Now I have to export each record separately to get the .do and .dct files which is time-consuming.

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

Re: Export data from CSpro 7 to STATA

Postby josh » July 30th, 2018, 7:16 am

Export data should create a separate .dct and .do file for each record that is exported. The files will have the same name as the record so if your dictionary has two records POPULATION and MIGRATION you will get POPULATION.dct, POPULATION.do, MIGRATION.dct and MIGRATION.do. Please verify that these files are not getting created. You may want to enable showing file extensions in Windows to be able to see the different files more easily (https://www.howtohaven.com/system/show- ... orer.shtml).

If the files are not being created when you export your data please send us the export specification file, CSPro dictionary and an example data file so we can reproduce the problem. You can either post it here or send it cspro@lists.census.gov.

Andilip
Posts: 2
Joined: July 30th, 2018, 2:12 am

Re: Export data from CSpro 7 to STATA

Postby Andilip » July 31st, 2018, 2:07 am

I've enabled showing file extensions in Windows and it is clear that the files are not being created. I've sent the files in the email address.

Thanks.

lee
Posts: 1
Joined: January 14th, 2019, 3:00 pm

Re: Export data from CSpro 7 to STATA

Postby lee » January 14th, 2019, 3:06 pm

I have also been facing this problem too. Unable to create .dct and .do files. Is there a work around for this? I'm able to export to SPSS, R, Excel, etc. But when I use Stata I face several issues. Sometimes I get an "internal error" message.

aaronw
Posts: 150
Joined: June 9th, 2016, 9:38 am
Location: Washington, DC

Re: Export data from CSpro 7 to STATA

Postby aaronw » January 14th, 2019, 5:51 pm

@lee Can you send us the export specification file, CSPro dictionary, and an example data file to cspro@lists.census.gov. We'll need these files to reproduce your issue.


Return to “Tools”