sql server - which kind of record this like will get? -


like ',%,%,' 

i using above in case statement record. it's not working expected.

my query -

select   case          when row_id ',%,%,'             'a'         when row_id not ',%,%,'             ''         end 'af'         myview row_id = '2464,2465,2466'  order 1 desc 

expected output - getting blank.

this like:

row_id ',%,%,' 

will match every single row_id starts , ends comma , has @ least comma in between.

your query, because of clause

where row_id = '2464,2465,2466' 

will return empty set because row_id doesn't match previous pattern.


Comments

Popular posts from this blog

sql - invalid in the select list because it is not contained in either an aggregate function -

Angularjs unit testing - ng-disabled not working when adding text to textarea -

How to start daemon on android by adb -