The API docs reference these 3 methods:
// secure (ID is quoted but matched anyway)
In the last one, the actual value isn't quoted into the string, so you end up with a prepared statement without the values embedded, while the former two will result in a completely different query in each iteration.
Not knowing the ins and outs of query caching, I would assume that the 3rd option would be the fastest, since the query would only need to be prepared once, and then could be reused.
Can anyone confirm this?
Cheers,
David
没有评论:
发表评论