Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 bcp

Author  Topic 

avmreddy17
Posting Yak Master

180 Posts

Posted - 2008-09-07 : 11:30:34
I had to change the data Types of the columns from INT to Numeric(15,4), so I BCP'ed out the data and changed the data Types from INT to NUMERIC for a few Columns and when I BCP in the data its giving an error NUMERIC Value OUT OF RANGE

Any Ideas

Thx

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-09-07 : 15:12:03
this means you have some data which cannot be converted into numeric. you have spot out bad data and cleanse it before bcping.
Go to Top of Page

jezemine
Master Smack Fu Yak Hacker

2886 Posts

Posted - 2008-09-07 : 21:15:09
if you use the -e option, bcp will show you the rows that failed to import in a log file.


elsasoft.org
Go to Top of Page

avmreddy17
Posting Yak Master

180 Posts

Posted - 2008-09-08 : 11:38:39
I am using the Queryout option in BCP and my Query is very long.
It throws the belo error

Query hints exceed maximum command buffer size of 1023 bytes (1579 bytes input)

Is there a way around this?

Thx
Go to Top of Page

jezemine
Master Smack Fu Yak Hacker

2886 Posts

Posted - 2008-09-08 : 12:20:39
put your query in a view and query the view from bcp.


elsasoft.org
Go to Top of Page

avmreddy17
Posting Yak Master

180 Posts

Posted - 2008-09-08 : 14:41:21
Thanks jezemine/Visakh
Go to Top of Page
   

- Advertisement -