Page 1 of 1

Csweb

Posted: February 5th, 2019, 4:36 am
by col Ar
Hi. Is it possible to deploy. Dat in CSWeb? Or do I only need. csdb files only

Re: Csweb

Posted: February 5th, 2019, 6:48 am
by josh
You should use .csdb for data synchronization in CSWeb. csdb files have additional information in them required for "smart" synchronization of data that is not in text format files (.dat). Only csdb files can be used with the syncdata() function. You can use syncfile() to upload/download text files to/from a CSWeb server but this will always transfer the entire file rather than transferring just the cases that have been added/modified.

Re: Csweb

Posted: February 5th, 2019, 6:51 am
by Gregory Martin
You must use .csdb files. Using data synchronization requires a lot of metadata that isn't available for text files.

Re: Csweb

Posted: February 5th, 2019, 10:59 am
by col Ar
I did upgrade all my dat files to csdb. They are lookup files. I first opened the file with data viewer, then supplied its dictionary, then went to tools and converted to csdb and maintained the original names . However, now my app can read these csdb but when I select a lookup eg district, nothing happens.

Re: Csweb

Posted: February 5th, 2019, 3:12 pm
by Gregory Martin
When you run your program, are you selecting the .csdb files? We have used .csdb files in many projects as lookup files, so the problem is likely with your application or with what files you're selecting.

You can send your application to cspro@lists.census.gov and we can look at it.

Re: Csweb

Posted: February 7th, 2019, 8:46 am
by col Ar
Thanks, I just realized that the .dat files are a bit easy to edit and add entries than .csdb when viewed in Notepad++.
Is there a better viewer and editor for the .CSDB files other than Data Viewer and Notepad++?
If not, is there a guide on how to add entries to the csdb files?

Re: Csweb

Posted: February 7th, 2019, 11:28 am
by Gregory Martin
You can only safely edit .csdb files within CSPro applications (CSEntry, or running a batch application). If you need to modify the case contents, then you should stick with text files. Each data file type has its purposes.

Re: Csweb

Posted: February 11th, 2019, 7:00 am
by col Ar
So Gregory, if I get you right, if I have previous data in dat format, I can't convert them to csdb? I have been using dataviewer to convert dat to csdb by opening dat, supply its dict then tools and convert. I see my data is just fine. So, unless I am doing a mistake, kindly clarify

Re: Csweb

Posted: February 11th, 2019, 7:11 am
by josh
What Greg is saying that you can't edit csdb files directly in notepad. To edit a csdb file you should use a CSPro data entry application or batch edit application. Text files can be edited in notepad although even that is not recommended as it is very easy to mess up your data if you don't know what you are doing.

Conversion between text and csdb can be done in DataViewer with no problem as you have seen.