On my website there are already many visits daily, so I am thinking about providing the Mysqli Db results from cache.
I am trying it like this:
$res = $mysqli->query("/*" . MYSQLND_QC_ENABLE_SWITCH . "*/" . "SELECT * FROM mytable WHERE id = $id");
while ($res->fetch_assoc()) {...}
If I am not wrong, the first time this query will come from DB and it will be stored to cache. And every further call will come from the cache only?
And my question is, if I insert another data to that table, will it be shown? Because it is not in the cache.