This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
The solution you guys talked about on DataProvider.SqlServer2005 is working great, but I'm now trying to do the same in DataProvider.Mysql5. But I think i'm doing something wrong the Order.By and the Mysql Built in Rand() function.
|
|
|
--- mysql begin --- Entity.Attribute("Id").Function("GetNewId") CREATE VIEW RandomView --- mysql end ---
--- mssql begin --- Entity.Attribute("Id").Function("dbo.GetNewId") CREATE VIEW RandomView --- mssql end --- |
|
|
Order.By(Entity.Attribute("Id").Function("GetNewId")) Order.By(Entity.Attribute("Id").Function("dbo.GetNewId")) |
|
|
--- mysql begin --- CREATE VIEW RandomView --- mysql end ---
i'm missing "edit/change post" and "code" function in the forum :-) |
|
|
You don't say what the behaviour is -- exception, nothing happens, data not randomised, etc. If you look at the view in the MySQL query browser, is it providing random numbers? Can you write SQL in the MySQL query browser that uses the function to randomise table query results? What is the SQL generated by LightSpeed? |
|