Did you declare the field as containing numeric data, or a real? '$999.63' > '$16695.36' is true (with or without the $sign)
999.63 > 16695.36 is false looks like you are sorting text, not numbers. >-----Original Message----- >From: [email protected] [mailto:sqlite-users- >[email protected]] On Behalf Of Jungle Boogie >Sent: Monday, 22 September, 2014 13:12 >To: [email protected] >Subject: [sqlite] sqlite max arguments assistance > >Hello All, > >select * from august where transaction_amount = (select >max(transaction_amount) from august) > >This statement should show be the merchant account with the top most >expensive >transaction from my table called august. > >Result: >$999.63 >(I trimmed out other items that I can't show). > >Same results with this: select max(transaction_amount) from august >$999.63 > > >But this is NOT the most expensive amount, but it is for a three digit >dollar >amount. > > >For example, this record is much higher in terms of transaction_amount: >$16695.36 > >This is a csv file that I've imported and I'm using SQLiteSpy with sqlite >3.8.6 as well as >FreeBSD lyander-fbsd 10.0-RELEASE-p9 FreeBSD 10.0-RELEASE-p9 #0: Mon Sep >15 >14:32:29 UTC 2014 >[email protected]:/usr/obj/usr/src/sys/GENERIC i386 >also with sqlite3.8.6 > > >How am i misunderstanding max? >-- >inum: 883510009027723 >sip: [email protected] >xmpp: [email protected] >_______________________________________________ >sqlite-users mailing list >[email protected] >http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users _______________________________________________ sqlite-users mailing list [email protected] http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

