I don't have any experience with SQL, but I'm thinking that zero filling both might work:
Although '5' <= '40' is false, '00000000000000000005' <= '00000000000000000040' is true. But since you should be using some glue code to validate the field from the web page anyway, can you just push the form field into a numeric before passing it to SQL? Would that do any good? Joel Rees [EMAIL PROTECTED] PS: Do posts tend to group around themes? Daniel James <[EMAIL PROTECTED]> wrote: [snipped] > Here is the problem another way... > > select '5' <= '6'; > => 1 > select '5' <= '4'; > => 0 > select '5' <= '40'; > => 0 <- eegad..... > > does anyone know how I can get around this? --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php