Viewing 8 posts - 1 through 8 (of 8 total)
I get an error due to one of the current descriptions.. Also like 79 which has C4 shows 4 but no CNT so its value should not show up.
May 23, 2018 at 4:38 pm
Thanks for the help, it's appreciated.
May 23, 2018 at 3:45 pm
SQL 2012 R2
It is an ERP product that has come up through the years.
May 23, 2018 at 3:32 pm
I fixed it this way
SELECT ROWID, ID, DESCRIPTION, CASE WHEN DESCRIPTION LIKE '%CNT%' THEN RIGHT(RTRIM(SUBSTRING(DESCRIPTION, 1, PATINDEX('%CNT%', DESCRIPTION) - 1)), PATINDEX('%[^0-9]%',
LTRIM(REVERSE(SUBSTRING(DESCRIPTION, 1,...
May 23, 2018 at 3:31 pm
So I figured out not all DESCRIPTION fields have CNT in them so it's returning a null value. I did a filter description like '%CNT%' then I was able to...
May 23, 2018 at 3:29 pm
I am getting an error.
Msg 537, Level 16, State 3, Line 1
Invalid length parameter passed to the LEFT or SUBSTRING function.
I tried playing with it...
May 23, 2018 at 2:45 pm
The data I am looking for to be returned from a select statement is the 2 or 3 digit number to the right on the text ' CNT'
I...
May 23, 2018 at 1:27 pm
Sorry.. I should have put an example of what I was looking for.
From this : GLP1 SUPPORT 60 CNT/BT I want the number 60 only.
60 Count...
May 23, 2018 at 12:17 pm
Viewing 8 posts - 1 through 8 (of 8 total)