Table called most often?


(K Buttress) #1

Hello,


I'm trying to track the most often called tables when loading a fairly standard web page.



From the little investigation I have done, I can see that sq_ast seems to be heavily used among others.



Is there a structure, format and frequency to the tables that area called.



I understand that this would depend on the number of assets on a page, but in general terms is there a table(s) that would be accessed more than others?



Thanks


(Avi Miller) #2

You could probably hack PEAR's DB.php module to log out all the database queries. We use a lot of tables to build a page, depending on what's required.


(Greg Sherwood) #3

Logging queries might be easier.


The tables I think would be most frequently used are:

sq_ast

sq_ast_lnk

sq_ast_lnk_tree

sq_ast_lookup

sq_ast_lookup_value

sq_ast_perm

sq_ast_attr

sq_ast_attr_val



Those tables load assets, check permissions, print designs and load data into the page. Other tables (like sq_ast_mdata) get used depending on what data is being displayed and the functionality you use. Those tables are the main ones though.


(K Buttress) #4

You're a champ just this info I was looking for. :smiley:


(Avi Miller) #5

Any particular reason? We're always on the look out for performance enhancing techniques. :)

(K Buttress) #6

Simply to try and find a way to optimise the database a little, we have set a challenge for a DBA's, if we find the magic bullet we'll pass on the information… :wink: