Page 1 of 1

Bad record type on line 1, record ignored

Posted: August 6th, 2018, 12:29 pm
by daniedusi
I tried to import a ".dat" file from spss, the file has the ascii format, but when i tried to import it, this message appears in the data viewer: Bad record type on line 1, record ignored

Re: Bad record type on line 1, record ignored

Posted: August 6th, 2018, 1:23 pm
by josh
Normally the first character on each line in a CSPro data file tells CSPro which type of record the line represents. You can change the position and length of the record type by modifying your data dictionary. If the data that that you are importing does not have a record type then you should set the length of the record type in your dictionary to zero.

Re: Bad record type on line 1, record ignored

Posted: August 6th, 2018, 2:10 pm
by daniedusi
Thanks for the reply Josh, I tried to set the record type to lenght zero, but a warning tells me that record type must be greater than zero if ther is more than one record type. I was wondering how i add the record type on my dat file instead of modifying my CSPro dictionary

Re: Bad record type on line 1, record ignored

Posted: August 6th, 2018, 2:35 pm
by josh
I'm not sure you can import a dat from SPSS that has more than one record type. I don't use SPSS so I could be wrong but I thought in SPSS you could only have one record type per file. If I'm wrong you could probably add a variable in your SPSS for the record type and save it the appropriate column in the .dat file.

Re: Bad record type on line 1, record ignored

Posted: August 6th, 2018, 3:42 pm
by AriSilva
As far as I know there is no way you can have more than one record type in SPSS.
In the CsPro dictionary, in order to eliminate the record type, besides putting 0 as the length you have to put a 0 as the starting position. That is the way to get rid of the record type.
Then you can import your spss file.

Re: Bad record type on line 1, record ignored

Posted: August 6th, 2018, 6:10 pm
by daniedusi
Saludos desde Guatemala Ari, gracias por tu ayuda, soy tu contador de reglas.