Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

How Can I Bulk Insert data like this 0.0096 & 0.0088 & 0.0055

$
0
0

I've tried FLOAT and NUMERIC(18,4).  Every time, all my numbers are stripped out, and all I get is NULL.

I'm using this:

CREATE TABLE:

Weight    numeric(18,4)

CREATE STAGING TABLE:

Weight    VARCHAR(MAX)

INSERT INTO TABLE:

Weight = CASE WHEN ISNUMERIC(Weight) = 1 THEN CAST(Weight AS numeric(18,4)) ELSE NULL END

Thanks everyone!


Knowledge is the only thing that I can give you, and still retain, and we are both better off for it.


Viewing all articles
Browse latest Browse all 23857

Trending Articles



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