1.   Your data should not have opening or closing parenthesis.

    2&3.  GATEWAY is defining WaVoters as a new CSV table.

It may be helpful to remove file names from your first row.  It can confuse the 
datatyping.  You know the order and can write File1, File2, and so forth under 
StateVoterID|FName|MName| to show how they are to be redefined after they have 
been imported.

Look at GATEWAY IMPORT in the help section.

Alternatively, you might use the RBase Editor to examine the file.

Often a large file like this will have hidden characters or strings as a header 
which comes before the data.

Another approach is to work with a subset of the data.  Download a county, and 
get that to work, then multiple counties.  Or try what worked on the entire 
data.

Sometimes I imported files into Excel or another spreadsheet program because 
they have importing and editing features.  Once you get things as you like, 
export as CSV.  I believe you can continue to select whatever delimit character 
you wish.

All the best,

Randy
________________________________
From: [email protected] <[email protected]> on behalf of 
[email protected] <[email protected]>
Sent: Friday, October 7, 2022 12:31 AM
To: [email protected] <[email protected]>
Subject: RE: [RBASE-L] - Importing Data From Text File


Hello Randy,



Thank you for taking the time to help me with this!

I did as you said, changed DELIMIT=|, and verified that it was the default. 
Then ran the command. This is what happened:



R>GATEWAY IMPORT CSV voters22V2.txt CREATE WaVoters

-ERROR- Missing the opening parenthesis (2778)

-ERROR- WaVoters is an undefined table. (2038)

-ERROR- WaVoters is an undefined table. (2038)



Not sure what to think about all this. 😊



Gary



From: [email protected] <[email protected]> On Behalf Of randyp 
ctags.com
Sent: Thursday, October 6, 2022 10:03 PM
To: [email protected]
Subject: Re: [RBASE-L] - Importing Data From Text File



Dear Gary,



Try proceeding in consecutive steps:



SHOW

This will reveal your present settings.  Delimit will be ,



SET DELIMIT=|

You can use the SHOW command to see that it was changed



GATEWAY IMPORT CSV WaRegVoters.TXT CREATE WaVoters

This should import your file [WaRegVoters.TXT] as CSV using | as the 
'comma'/delimiter.  It will create a table named WaVoters, hopefully with 35 
columns.



After the file is imported, you can rename the imported columns [File1, File2, 
File3...File35] to the column names in your database.

That will convert the datatype and length.



The advantage of using | as DELIMIT is that commas in addresses will not 
scramble your data.



Sometimes there are issues with the length of a column.



All the best,



Randy Peterson

  Blue Springs, Missouri

________________________________

From: [email protected]<mailto:[email protected]> 
<[email protected]<mailto:[email protected]>> on behalf of 
[email protected]<mailto:[email protected]> 
<[email protected]<mailto:[email protected]>>
Sent: Thursday, October 6, 2022 10:53 PM
To: [email protected]<mailto:[email protected]> 
<[email protected]<mailto:[email protected]>>
Subject: [RBASE-L] - Importing Data From Text File



Hello All,



I am trying to import data from a text file, but I can not make it work. The 
file is a Vertical Bar Delimited TXT file. The file is formatted into 35 
columns of various lengths. There are approximately six million rows. I have 
tried using the Gateway utility and the Gateway Import command. The Gateway 
utility freezes when I select destination sources for each column. When I try 
importing using the command, It also freezes up. The only way out is for me to 
shut down RBase using the Task Manager. When RBase freezes up, I notice that 
the Task Manager shows that Rbase is active and is using 30% of the CPU and 
800-900 MBs of memory.



The file I am trying to import is from the State of Washington. It’s a list of 
registered voters. The file format is the only format they offer this data in. 
I have tried converting the file using Excel, but it’s too large. The first row 
of data is the column names. I have pasted the first two rows to show what the 
data looks like. I have changed the identifying data, so the data below is not 
a real person or place.



StateVoterID|FName|MName|LName|NameSuffix|Birthdate|Gender|RegStNum|RegStFrac|RegStName|RegStType|RegUnitType|RegStPreDirection|RegStPostDirection|RegStUnitNum|RegCity|RegState|RegZipCode|CountyCode|PrecinctCode|PrecinctPart|LegislativeDistrict|CongressionalDistrict|Mail1|Mail2|Mail3|Mail4|MailCity|MailZip|MailState|MailCountry|Registrationdate|AbsenteeType|LastVoted|StatusCode

3593761|SUSIE||VOTER||1976-10-03|F|1233501||250TH|PL|#|NW||C108|KENT|WA|98030|KI|2403|2403.023|47|9|||||||||2004-05-17||2020-11-03|Active



I have tried importing into an existing table with the same column names, 
length, and data type as the data file, and I have tried importing using the 
create a new table. Unfortunately, nothing seems to work for me.

I am using RBase X.5 Enterprise Version 10.5.5.10818.



Thank you,

Gary Randall



--
For group guidelines, visit 
http://www.rbase.com/support/usersgroup_guidelines.php
---
You received this message because you are subscribed to the Google Groups 
"RBASE-L" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
[email protected]<mailto:[email protected]>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/rbase-l/09e001d8da00%2451ccefb0%24f566cf10%24%40gmail.com<https://groups.google.com/d/msgid/rbase-l/09e001d8da00%2451ccefb0%24f566cf10%24%40gmail.com?utm_medium=email&utm_source=footer>.

--
For group guidelines, visit 
http://www.rbase.com/support/usersgroup_guidelines.php
---
You received this message because you are subscribed to the Google Groups 
"RBASE-L" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
[email protected]<mailto:[email protected]>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/rbase-l/PH0PR11MB5112A0EC437E5BD0FF661257C75F9%40PH0PR11MB5112.namprd11.prod.outlook.com<https://groups.google.com/d/msgid/rbase-l/PH0PR11MB5112A0EC437E5BD0FF661257C75F9%40PH0PR11MB5112.namprd11.prod.outlook.com?utm_medium=email&utm_source=footer>.

--
For group guidelines, visit 
http://www.rbase.com/support/usersgroup_guidelines.php
---
You received this message because you are subscribed to the Google Groups 
"RBASE-L" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
[email protected]<mailto:[email protected]>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/rbase-l/09f901d8da0e%24180c3480%2448249d80%24%40gmail.com<https://groups.google.com/d/msgid/rbase-l/09f901d8da0e%24180c3480%2448249d80%24%40gmail.com?utm_medium=email&utm_source=footer>.

-- 
For group guidelines, visit 
http://www.rbase.com/support/usersgroup_guidelines.php
--- 
You received this message because you are subscribed to the Google Groups 
"RBASE-L" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/rbase-l/PH0PR11MB51126DFE109D95560196F3CAC75F9%40PH0PR11MB5112.namprd11.prod.outlook.com.

Reply via email to