I did some searching around on the forum and didn’t find a thread that speaks to this issue (but I might have missed it, so apologies in advance).
I am assuming that doing a join between a global table and a blog table is not kosher. Correct?
Or, is it my lucky day, and the multi-db class does some magic to make this possible?
Here’s a simple example of the type of thing I know exists in some of the code…
SELECT * FROM $table_blog_posts, $table_blogs
WHERE $table_blogs.public = 1 AND $table_blogs.deleted = 0 AND $table_blogs.spam = 0;
Now clearly this code can be rewritten to confirm the publicness and the non-spamness and non-deletedness of the blog before it attempts to do the select… but I see this sort of thing in plugins around… Hell, I admit, I wrote some code that does this.
So, if I am correct that this code needs to be rewritten… then… does anyone have any strategies on hunting down this kind of code.
Thanks in advance.