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
 read parts of unformatted fields string

Author  Topic 

AdamWest
Constraint Violating Yak Guru

360 Posts

Posted - 2014-04-23 : 17:42:57
I have a field that will look something like this. I need to read a file and when the first 3 positions are REM, the number following is the Order number, and the initials, are the rep. this is how they are tracking for the rep, if they sent reminders to customers and when.

REM 0482348 LV 04/13

I would like to do this in SQL and also join to the order header file that will give me the invoice total for that order. what is the best approach here via SQL for these first 2 fields'
needed?

Lamprey
Master Smack Fu Yak Hacker

4614 Posts

Posted - 2014-04-23 : 18:53:44
I'm not sure what your question is, exactly. This doesn't really seam like a SQL "thang." If you need to read/parse files there are far better tools that SQL Server. Perhaps SSIS?
Go to Top of Page
   

- Advertisement -