All Forums Tools
08 May 2015
BTEQ IMPORT SKIP Command

Hello ,
I need help on using BTEQ SKIP Command while Importing data from File to Table, with the help of few posts in this forum i understand that skip command should be used like below

 

.Import Vartext',' file=C:\Users\Sridhar\Desktop\teradata\BTEQ Scripts Outputs\sridhar4.txt, SKIP=10;

 

when i tried above it is thoughing error on File Open becuase No such file or no Directory exits and when i tried with out SKip command it is working.

 

Below are My Script:-

 

.logon 127.0.0.1/tduser,tduser

.Import Vartext',' file=C:\Users\Sridhar\Desktop\teradata\BTEQ Scripts Outputs\sridhar4.txt, SKIP=10;

 

 

.quiet on

 

database samples;

 

delete from emp_details_multiset;

 

.Repeat *

 

Using 

 

 in_no (varchar(10))

,in_name (varchar(50))

,in_sal (varchar(10))

,in_dept (varchar(10))

,in_loc (varchar(20)) 

 

Insert into emp_details_multiset (emp_id,emp_name,salary,dept,loc)

values(:in_no,:in_name,:in_sal,:in_dept,:in_loc);

 

select * from emp_details_multiset;

 

.quiet off

.quit

.logoff

 

Thanks,

Sridhar.

 
 

Sridhar Esampalli
dnoeth 4628 posts Joined 11/04
09 May 2015

There's a blank within the filepath, you must quote it:
.Import Vartext',' file="C:\Users\Sridhar\Desktop\teradata\BTEQ Scripts Outputs\sridhar4.txt", SKIP=10;

Dieter

09 May 2015

Thanks ..Its wokring now..I missed the quotes ..You rock Dieter..!! :-D  cheerssss

Sridhar Esampalli

You must sign in to leave a comment.