Subject Re: [firebird-support] Re: Help with strange answer in WHERE clause
Author Arno Brinkman
Hi,

Subject: [firebird-support] Re: Help with strange answer in WHERE clause


> Thank you. The problem is that the field might also have letters, so
> I will have to use a single comparison instead of a range.
> Thanks again.

You could leftpad your numbers with zeros, that's how i do it.

'00250'
'00999'
'01000'

SELECT Count(*) FROM TableX WHERE <= '01000'

will return all three example above.


May be it's better to ask yourself if it isn't possible to use only numbers.

Regards,
Arno Brinkman
ABVisie

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Firebird open source database (based on IB-OE) with many SQL-99 features :
http://www.firebirdsql.org
http://www.firebirdsql.info
http://www.fingerbird.de/
http://www.comunidade-firebird.org/

Support list for Interbase and Firebird users :
firebird-support@yahoogroups.com

Nederlandse firebird nieuwsgroep :
news://80.126.130.81