importing in sql assistant

Database
N/A

importing in sql assistant

I am trying to import data into teradata using sql assistant, using '|' as a delimiter. The '|' is also at the end of each record. I am not able to load the data with the '|' at the end of the record and I can't find any place in sql assistant to tell it that there is a delimter at the end of each record. Can anyone tell me how to get around this? If I edit the file and take out the '|' at the end of the record it loads fine but my files are too large to reasonably do this all the time. Thank you.

Example:

data is:
1234567 |avginv |tulwhse | 1 | 2| 3| doesn't work
1234567 |avginv |tulwhse | 1 | 2| 3 works

My insert is :

insert into avginv_table (?,?,?,?,?,?)

I have tried adding another column to the table thinking I could add a null value but when I try it using:

insert into avginv_table (?,?,?,?,?,?,)

I get an error that I have the wrong number of positional values.

Thank you.
1 REPLY

Re: importing in sql assistant

I would add the extra column (as you mentioned) and then add a 7th question mark to your insert:

insert into avginv_table (?,?,?,?,?,?,?)

I believe that you need as many question marks as you have fields in your input data.

Hope that helps.

Thanks,
Barry