Hello there,
I have just faced a really weird problem with a query in SQL SERVER 2000.
I had a database with collation SQL_Latin1_Gene ral_CP1_CI_AS and converted it in a new database with collation Greek_CI_AI.
The conversion was absolutelly correct. Tables, views, sps, functions etc. where succesfully transfered into the new database. The new database is working fine, but I faced a problem with a "select-from-where-like" query.
I have a table named account with a column name code (varchar(255)). some values are:
'54.00'
'54.00.01.000'
'54.00.01.001'
'54.00.01.002'
etc.
This query does not return any values!
While this returns correct values
The problem is with zeros (they are not number but characters).
The following query also returns correct values
Overall, the problem occurs only when 'like' statement and character '0' come together...
I'm REALLY CONFUSED!!!
If anyone has any ideas I would really like to listen to them...
I have just faced a really weird problem with a query in SQL SERVER 2000.
I had a database with collation SQL_Latin1_Gene ral_CP1_CI_AS and converted it in a new database with collation Greek_CI_AI.
The conversion was absolutelly correct. Tables, views, sps, functions etc. where succesfully transfered into the new database. The new database is working fine, but I faced a problem with a "select-from-where-like" query.
I have a table named account with a column name code (varchar(255)). some values are:
'54.00'
'54.00.01.000'
'54.00.01.001'
'54.00.01.002'
etc.
This query does not return any values!
Code:
select * from account where code like '54.00%'
Code:
select * from account where code like '54.%'
The following query also returns correct values
Code:
select * from account where code = '54.00'
I'm REALLY CONFUSED!!!
If anyone has any ideas I would really like to listen to them...
Comment