NickName:akshita007 Ask DateTime:2016-05-01T03:42:51 mysql c api limit function mysql_query(conn,"SELECT abstract FROM papers limit 4 "); Can we use variables in limit function in C-api.Like I have to iteratively extract 10 rows,so something of the form: mysql_query(conn,"SELECT abstract FROM papers limit $i $i+10 "); Copyright Notice:Content Author:「akshita007」,Reproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.Link to original article:https://stackoverflow.com/questions/36959416/mysql-c-api-limit-function Answers user3277192 2016-04-30T21:00:22 what you seek is \"OFFSET\"\n\ne.g. SELECT abstract FROM papers LIMIT 10 OFFSET 20\ngives 10 results (skipping over the first 20)\n\nRef: http://dev.mysql.com/doc/refman/5.7/en/select.html",