February 23, 2011 at 8:01 am
Hi,
I have a view that returns this data:
ID ; Name ;
10 Martha
100 Martha2
12 Martha3
1000 Martha4
..................
..................
I whant that if the ID is 10, then the Id returned become 0.
Like this:
ID ; Name ;
0 Martha
100 Martha2
12 Martha3
1000 Martha4
..................
..................
How can i accomplish this?
Thank you
February 23, 2011 at 8:04 am
Odd question, but why?
SELECT
CASE
WHEN X = 10 THEN 0
ELSE X
END
February 23, 2011 at 8:07 am
Yap,
The problem is how to put that on this:
"SELECT TOP (100) PERCENT '1'+replace(rf.repf_id,'.','') as repf_id"
This is my ID column
February 23, 2011 at 8:11 am
I found how to do it.
Thank you very much
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply