Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8545

Re: Sybase Bulk Copy via .net DLL: Value does not fall within the expected range

$
0
0

> I have tried not using IDataReader; instead moving the data to a DataTable then calling WriteToServer with the DataTable.

 

I suspect the issue is with the mapping code - we've found some issues with this.

 

Try removing the mappings and change your SQL select from

  SqlCommand cmd = new SqlCommand("select * from TO_INTS", conn);

to (or similar)

  SqlCommand cmd = new SqlCommand("select TO_INT from TO_INTS", conn);

 

That way your DataTable should match the table you're bcp-ing into.

 

This "Received a row of length 11 whilst maximum or expected row length is 6."

certainly implies that too much data is being send.

 

I think there's a way to log the TDS packets being sent. Its not easy to decipher but not impossible. Freetds has some of the specification. I'll have a look into this.


Viewing all articles
Browse latest Browse all 8545

Trending Articles



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