Discussion of general topics related to the new version and its place in the world. Don't discuss new features, report bugs, ask for support, et cetera. Don't use this to spam for other boards or attack those boards!
Forum rules
Discussion of general topics related to the new release and its place in the world. Don't discuss new features, report bugs, ask for support, et cetera. Don't use this to spam for other boards or attack those boards!
ChAoS wrote:In this case the first one is more practical, although you already knew that.
Really?! My God, I'll rewrite all our sql immediately ... That's obviously not what I or indeed SHS` were saying. You can have multiple joins on tables doing complex comparisons across multiple fields which take an age to complete even with appropriate indexing ... meanwhile, the same query broken down into two or more queries may execute faster.
At this point, when I write queries, I tend to write simple ones and then do processing in PHP. Of course, this isn't because that method isn't inherently better, but because the only SQL I know is what I learned from phpBB and a brief exposure to some kind of JOIN when I was doing something that I can no longer recall. I have yet to see the power of some of the more advanced SQL queries. Shame that the advanced queries tend to be the ones I remember phpBB naysayers complaining about. e.g. "Oh no! You're using a JOIN on your posts table. Ahhhh!" etc. So I really have no idea whether JOINS are useful to be used in the real-world environment. Must be time for a relational database theory book or something.