views:

62

answers:

2

Hi, Do anyone know how to request a "live result set" in MySql when query has offset(eg: select * from table limit 10 offset 20;). it is throughing an error like

'invalid use of keyword'

.

Thanks, Vijay.

+2  A: 

you have no condition behind where and before limit ...

try

  • select * from table where (1=1) limit 10 offset 20;

or

  • select * from table limit 10 offset 20;
lexu
sorry lexu for posting worng query it should be 'select * from table limit 10 offset 20;'
Vijay Bobba
A: 

Hi, I got it... I have used the TUpdateSQL and the cachedupdates property of the TQuery is made true...now i can edit the dataset(Query1.state=dsedit)i.e., edit the cell values of the dbgrid and i used query1.post and query1.commitupdates before this at design time we should assign the updateobject property of the tquery to the particular Tupdatesql component and the updatesql comp. should contain the relavent update query in the ModifySql property.

Overall the prob. is solved using TUpdateSQL component, if my above disscussion is confusing refer the delphi help for TUpdateSQL, its very clear and easy.

Thanks for all, Vijay.

Vijay Bobba