Quantcast
Channel: Teradata Forums - All forums
Viewing all articles
Browse latest Browse all 27759

SQL to import string with comma (,) from a file using SQL Assistant - forum topic by thisisKumar

$
0
0

Hi, I am trying to import data from a text file using a SQLAssitant. But it is giving me an error as the string contains ",".
I am using this below syntax for inserting:
 

CREATE VOLATILE TABLE kumar_test (a INTEGER, b VARCHAR(100))

PRIMARY INDEX  ( a );

 

INSERT INTO kumar_test(?,?)

 

my file contains:

1,a

2,b

3,c

4,d

5,cd

6,'e,f'

7, x's y

 

I am able to import first 5 records sucessfully. But, I am getting an error at record 6. here I have added a another record (7) to make sure I won't get an error in the future for this scenario.

 

Thanks!

Forums: 

Viewing all articles
Browse latest Browse all 27759

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>