Originally posted by TCovert
What am I doing wrong?
atexid like '%' order by orderid
All the % symbol means is match zero or more characters when used in conjunction with the LIKE clause. So, you query is saying to find all of these matches WHERE... AND... AND... AND... but on your last AND, you are saying to match zero or more of nothing, which of course will give no result set if all of your other columns contain data but atexid does not.
Can you insert a field name after your % symbol and try again rather than just have the % symbol alone in that last AND?
Post back with your results.