On Tue, Oct 4, 2011 at 9:25 PM, Tommy Pham <tommyhp2@xxxxxxxxx> wrote: > There would be a difference in performance since the the expression has to > be reevaluated, including the function FROM_BASE, every time versus one time > evaluation of prepared statement. This is true, but it should be pointed out that for a large majority of web applications the performance hit given by either prepared statements or base64 encoding is going to be miniscule compared to the bottlenecks already present at the db-access and network-latency layers. Sites that approach needing to actively worry about the performance hit from either method are rare, and it's doubtful that the solution used would be to remove the tactic, assuming the reasons for the approach being used are sound and still present. > > > >> As for the added complexity, if you have SQL statements all over your code >> then yes it will add a time overhead, but any codebase of a significant size >> should be using a centralised API for database access such that changes like >> this have a very limited scope. >> > > Isn't that one of the major points of OOP? Still, what about new > developers, having to remember that additional (and most likely unneeded) > complexity, to the project which they would like to build additional > modules/plugins for? > The paragraph you're replying to is saying that this shouldn't be a pain if your code is well organized. If your codebase is sane, these details should be transparent to new developers. If they can't be, then new developers get a chance to learn things :P -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php