You can always use a sub select in your where clause: SELECT * FROM myTable WHERE ID < (select max(ID) from myTable) Mark
valter piso <[EMAIL PROTECTED]> wrote: thank you for your help. but when i run the code the page return this error.... Error Type: Microsoft JET Database Engine (0x80040E14) Cannot have aggregate function in WHERE clause (id<Max(id)). Regards Valter Dan Powderhill <[EMAIL PROTECTED]> wrote: How not to show it? Do something like this in your SQL query :- SELECT * FROM myTable WHERE ID < Max(ID) Dan ________________________________ From: Valter [mailto:[EMAIL PROTECTED] Sent: 14 March 2005 10:38 To: [email protected] Subject: [AspClassicAnyQuestionIsOk] How to .... avoid to show in my web page list the last record of my db ordered by id? Thank you for help Valter Yahoo! Groups Sponsor ADVERTISEMENT click here <http://us.ard.yahoo.com/SIG=129f17b49/M=298184.6018725.7038619.3001176/ D=groups/S=1705006764:HM/EXP=1110883094/A=2593423/R=0/SIG=11el9gslf/*htt p://www.netflix.com/Default?mqso=60190075> <http://us.adserver.yahoo.com/l?M=298184.6018725.7038619.3001176/D=group s/S=:HM/A=2593423/rand=861725171> ________________________________ Yahoo! Groups Links * To visit your group on the web, go to: http://groups.yahoo.com/group/AspClassicAnyQuestionIsOk/ * To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED] subscribe> * Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service <http://docs.yahoo.com/info/terms/> . [Non-text portions of this message have been removed] Yahoo! Groups SponsorADVERTISEMENT --------------------------------- Yahoo! Groups Links To visit your group on the web, go to: http://groups.yahoo.com/group/AspClassicAnyQuestionIsOk/ To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. --------------------------------- Do you Yahoo!? Yahoo! Small Business - Try our new resources site! [Non-text portions of this message have been removed] Yahoo! Groups SponsorADVERTISEMENT --------------------------------- Yahoo! Groups Links To visit your group on the web, go to: http://groups.yahoo.com/group/AspClassicAnyQuestionIsOk/ To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. [Non-text portions of this message have been removed] Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/AspClassicAnyQuestionIsOk/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
