Database Query
The compare between database query is not really efficient for the following reasons:
the format of the data may be not the same for date or number.
if you transform the number into character, the alignment may become different. It's usual to get text on the left side whereas number are on the right side.