It's a random number already stored in the page table On Saturday, July 30, 2016, yonnel kurtz <[email protected]> wrote:
> Thank's, > > but i'm beginner... > So i don't understand. > > How use it inside my code : > array( > 'ORDER BY' => 'page_title ASC' > #'ORDER BY' => rand(), > 'LIMIT' => 10, > ), > > yonnel > > 2016-07-30 16:44 GMT+02:00 John <[email protected] <javascript:;> > >: > > > You can use page_random for that > > > > On Sat, Jul 30, 2016 at 10:42 AM, yonnel kurtz <[email protected] > <javascript:;>> > > wrote: > > > > > Hello, > > > > > > I prepare an extension for category (for myself). I need to find page > in > > a > > > sql select with "order by rand()" (mysql). > > > > > > How to do ? I have each time an error when i try. > > > This is my syntax i have : > > > > > > $res = $dbr->select( > > > array( 'page', 'categorylinks' ), > > > array( 'page_title' ), > > > array( > > > 'cl_to' => 'aricles de toto' , > > > ), > > > '', > > > array( > > > 'ORDER BY' => 'page_title ASC' > > > #'ORDER BY' => rand(), > > > 'LIMIT' => 10, > > > ), > > > array( 'categorylinks' => array( 'LEFT JOIN', array( > > > 'cl_from = page_id' ) ) ) > > > ); > > > > > > Thank's a lot > > > yonnel > > > -- > > > adresse mail : [email protected] <javascript:;> > > > mobile : 07 61 72 79 12 > > > > > > Identifiant de société : Siren : 501 161 384 > > > Code NAF : 722C > > > Siret : 501 161 384 00018 > > > Code Insee : C75017862440 > > > _______________________________________________ > > > Wikitech-l mailing list > > > [email protected] <javascript:;> > > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l > > _______________________________________________ > > Wikitech-l mailing list > > [email protected] <javascript:;> > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l > > > > > -- > adresse mail : [email protected] <javascript:;> > mobile : 07 61 72 79 12 > > Identifiant de société : Siren : 501 161 384 > Code NAF : 722C > Siret : 501 161 384 00018 > Code Insee : C75017862440 > _______________________________________________ > Wikitech-l mailing list > [email protected] <javascript:;> > https://lists.wikimedia.org/mailman/listinfo/wikitech-l _______________________________________________ Wikitech-l mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikitech-l
