Hi, I just ran: explain select max(changelog_id) from changelog changelog_id is an int and the primary key of changelog, which has 184551 rows.
And the gist of the explaination is: TABLE SCAN 828 RESULT IS COPIED , COSTVALUE IS 1657 It seems to me that it ought to be cheaper to walk down the index and find the max, in fact I should think the cost would be in the 'hood of a simple match. Is this a missing feature, a bug, something that is caused by my data or what? BTW, select count(*) and select count(changelog_id) on that table has the same strategy / costvalue Investigating a bit further I have found out that the SYSPRIMARYKEYINDEX isn't used, how can that happen for a table that has 184551 rows? -- Regards Flemming Frandsen aka. Dion/Swamp http://dion.swamp.dk _______________________________________________ sapdb.general mailing list [EMAIL PROTECTED] http://listserv.sap.com/mailman/listinfo/sapdb.general
