[wp-hackers] Re: [wp-svn] [3012] trunk/wp-includes: Add LIMIT
1 to some of our gets.
Ryan Boren
ryan at boren.nu
Tue Nov 8 00:12:53 GMT 2005
On Mon, 2005-11-07 at 23:18 +0000, Mike Little wrote:
> On 11/7/05, m at wordpress.org <m at wordpress.org> wrote:
> >
> > Revision 3012 Author ryan Date 2005-11-07 23:09:09 +0000 (Mon, 07 Nov 2005)
> > Log Message Add LIMIT 1 to some of our gets.
> >
>
> Ryan,
> Is there some speed advantage to this?
>
> Each of the ID columns used to select is a primary key, there can only
> ever be one row returned by definition.
We had limit 1 on a couple of selects I replaced.
http://trac.wordpress.org/changeset/3013
I remember these being added to fix a performance bug a couple folks
reported, so I just added the limits to our get methods. I don't know
if they make any difference.
Ryan
More information about the wp-hackers
mailing list