Link to home
Start Free TrialLog in
Avatar of Roberto Madro R.
Roberto Madro R.Flag for United States of America

asked on

Text file into sql server

I need to read a text file and insert specific values into a table in sql server, I have the starting position and length of fields I need to read from the text file, but I needs some hints on how to go about parsing and selecting the desired values.

Your thoughts.
Thx
Avatar of JesterToo
JesterToo
Flag of United States of America image

Could you please post a sample of the text file?  One (usually) straightforward way to do this is write a script (perhaps in VBscript or something equivalent) to parse the data from the text file and insert the data into the sql table(s).

If you upload a sample file, be sure to specify the rules for parsing it including the sql table names, columns and data types.
Avatar of Roberto Madro R.

ASKER

ASKER CERTIFIED SOLUTION
Avatar of Jeff Edmunds
Jeff Edmunds
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
A SSIS package was the answer as some data elements were missing or corrupt and some needed fixing, it was a much faster method.