How do I know if  query A is faster than query B ? Here are the bottom 
summaries of two execution plans for two queries generating the same 
result. I believe B is better than A. 

Query A

/*
total: 1186
BAR.BAR_DATA read: 858 (72%)
BAR.BAR_PARENT read: 82 (6%)
DATA_FOO.DF_FK2_INDEX_E read: 26 (2%)
DATA_FOO.DATA_FOO_DATA read: 220 (18%)
*/

Query B

/*
total: 15
BAR.BAR_DATA read: 5 (33%)
DATA_FOO.DF_FK2_INDEX_E read: 1 (6%)
DATA_FOO.DATA_FOO_DATA read: 4 (26%)
DATA_FOO.DATA_FOO_UUID read: 5 (33%)
*/

What does the "total" number represent? Can I use the "total" as a 
reference point to the cost of the query? I know I can look at the scan 
counts and how indices are used in the rest of the plan to optimize. But, 
can I use the total as the overall cost?

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/h2-database/-/8XXO-u9KBS0J.
To post to this group, send email to h2-database@googlegroups.com.
To unsubscribe from this group, send email to 
h2-database+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/h2-database?hl=en.

Reply via email to