1. mysql_fetch_assoc is faster than mysql_fetch_array because it selects less information, correct?
Is it really faster? Is is it significant? Meaby you could say that mysql_fetch_assoc consumes a little less memory, but i would never take that into consideration for changing my code. It's less expensive to buy some extra RAM.
2. Is it possible to get a database integer and perform operations on it without running a query to select the integer, then running another query to update it? If so, how?
Code: Select all
UPDATE table SET counter=2*counter+1;
Code: Select all
3. Does the loading speed of a page depend on the processor of the machine it's being hosted on.. the processor of the machine viewing it.. or both?
(a) time to request the page
(b) time to generate the page (also consider time to access the database etc..)
(c) time to fetch the page
(d) time to render the page
Imho bandwith has a great influence on (a) and (c), where cpu crunching will have great influence on (b) and (d)