Viewing 15 posts - 2,251 through 2,265 (of 3,544 total)
| Where are the suck-ups? No votes for Andy, Brian or myself.... |
Far away is close at hand in the images of elsewhere.
Anon.
July 11, 2005 at 11:09 am
| It would be nice if the posters acknowledged that the solution worked.... |
Couldn't agree more ![]()
Far away is close at hand in the images of elsewhere.
Anon.
July 11, 2005 at 7:58 am
| ....if VARCHAR then you WONT |
Not entirely true.
varchar columns may or may not have trailing spaces, they...
Far away is close at hand in the images of elsewhere.
Anon.
July 11, 2005 at 7:51 am
| Well I'd vote for myself so I get at least one vote |
That goes without saying 
Far away is close at hand in the images of elsewhere.
Anon.
July 11, 2005 at 7:34 am
| That might start a little war... not sure it's a good idea. |
Is that because you might...
Far away is close at hand in the images of elsewhere.
Anon.
July 11, 2005 at 7:24 am
![]()
Far away is close at hand in the images of elsewhere.
Anon.
July 7, 2005 at 8:17 am
np, sets a challenge to rethink the solution, always a good idea ![]()
Far away is close at hand in the images of elsewhere.
Anon.
July 7, 2005 at 8:01 am
Remi is right in that the queries are not the same
CONTAINS(ArticleDescription, 'magazine')
is the same as
LIKE '% magazine %' (yes there is a space either side of the word...
Far away is close at hand in the images of elsewhere.
Anon.
July 7, 2005 at 7:53 am
Any string manipulation is slow and it is all relative to the size of the dataset
therefore another alternative ![]()
SET @RefDes = ''
select @RefDes...
Far away is close at hand in the images of elsewhere.
Anon.
July 7, 2005 at 7:40 am
SELECT *
FROM Products WHERE ProductID IN (31, 5, 7, 9, 12)
ORDER BY CHARINDEX(', '+CAST(ProductID as varchar)+',',','+'31, 5, 7, 9, 12'+',')
or if using variable/parameter
DECLARE @ID varchar(100)
SET @ID...
Far away is close at hand in the images of elsewhere.
Anon.
July 7, 2005 at 7:29 am
SET @RefDes = ''
select @RefDes = @RefDes +
CASE WHEN CHARINDEX(','+ref_des+', ',','+@RefDes)>0 THEN '' ELSE ref_des + ', ' END
from A
right outer JOIN
B ON A.job...
Far away is close at hand in the images of elsewhere.
Anon.
July 7, 2005 at 7:16 am
1022 ![]()
daily dts import from 3rd party database
Far away is close at hand in the images of elsewhere.
Anon.
July 7, 2005 at 6:47 am
WHEN PATINDEX('[0-9][0-9][0-9][0-9][.]',CardExpDate) > 0 THEN STUFF(LEFT(CardExpDate,4),3,0,'20')
p.s. you can do the RTRIM as well if you wish
Far away is close at hand in the images of elsewhere.
Anon.
July 6, 2005 at 9:25 am
| The column should be rtrimed automatically if you have a [n]varchar column |
![]()
Far away is close at hand in the images of elsewhere.
Anon.
July 6, 2005 at 9:20 am
Works OK for me, what result do you get (or do you get an error?)
Far away is close at hand in the images of elsewhere.
Anon.
July 6, 2005 at 8:50 am
Viewing 15 posts - 2,251 through 2,265 (of 3,544 total)