[base] DataQuery.order(...) 2.x API question

2012-10-09 Thread Bob MacCallum
Hi all, I'm trying to get a Reporter query from the BASE2.x API which is basically ORDER BY RAND(123) - to get reproducible random order (I can explain *why* in another email if anyone cares to know). I tried this DataQuerynet.sf.basedb.core.data.ReporterData repQuery =

Re: [base] DataQuery.order(...) 2.x API question

2012-10-09 Thread Nicklas Nordborg
On 2012-10-09 13:11, Bob MacCallum wrote: Hi all, I'm trying to get a Reporter query from the BASE2.x API which is basically ORDER BY RAND(123) - to get reproducible random order (I can explain *why* in another email if anyone cares to know). I tried this

Re: [base] DataQuery.order(...) 2.x API question

2012-10-09 Thread Bob MacCallum
Hi Nicklas, Thanks very much for the quick reply. I am *so* close to getting this working - it seems that the argument-less rand() is available in HQL but I will have to jump through a few hoops to provide the seeded version. I'll post an update later... cheers, Bob. On Tue, Oct 9, 2012 at 12:50

Re: [base] DataQuery.order(...) 2.x API question

2012-10-09 Thread Bob MacCallum
Getting closer - I have set up a custom dialect: package org.vectorbase.funcgen.hibernate; import org.hibernate.Hibernate; import org.hibernate.dialect.MySQLInnoDBDialect; import org.hibernate.dialect.function.StandardSQLFunction; public class CustomDialect extends MySQLInnoDBDialect { public

Re: [base] DataQuery.order(...) 2.x API question

2012-10-09 Thread Nicklas Nordborg
On 2012-10-09 17:24, Bob MacCallum wrote: Just for closure, I am now in business. [mysqld] tmp_table_size = 5G Background for whoever cares: I'm running something reporter-wise in parallel (4 threads) and wanted roughly equal workload per chunk of reporters (some reporters have more