Site Sponsored By: SQLDSC - SQL Server Desired State Configuration
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.
So, I know I'll put this in a case statement, but i'm not sure about converting the Mid and InStrRev functions to something in SQL. Any help would be much appreciated! Thanks
dataguru1971
Master Smack Fu Yak Hacker
1464 Posts
Posted - 2011-01-28 : 18:14:12
CASE WHEN ColumnA is not nullthen substring(ColumnA,5,CHARINDEX('/',REVERSE(columnA))-5) else null endPoor planning on your part does not constitute an emergency on my part.
Brittney10
Posting Yak Master
154 Posts
Posted - 2011-01-31 : 15:35:28
Thanks! I got it working!
dataguru1971
Master Smack Fu Yak Hacker
1464 Posts
Posted - 2011-01-31 : 15:43:19
Glad to help.Poor planning on your part does not constitute an emergency on my part.