David Nelson Posted May 11, 2015 Posted May 11, 2015 I saw it was added new in 13 but I do not remember its name so I can not find it to read up on how to do it. It was something new added to SQL so we could ask for only the top x records. What is it called? Thank you for reading.
Ocean West Posted May 11, 2015 Posted May 11, 2015 (edited) ExecuteSQL ( sqlQuery; fieldSeparator; rowSeparator {;arguments...} ) here is a great resource for discovering how to implement it. http://filemakerhacks.com/2012/10/19/the-missing-fm-12-executesql-reference/ offset and fetch is what you need http://help.filemaker.com/app/answers/detail/a_id/12061/~/specifying-offset-and-fetch-first-clauses-in-filemaker-pro-using-the-executesql Edited May 11, 2015 by Ocean West 2
sal88 Posted August 18, 2015 Posted August 18, 2015 (edited) Has anyone had a problem using fetch with arguments (i.e. substituting the value with a '?')? e.g. executesql (" SELECT * FROM t1 FETCH FIRST ?ROWS ONLY ";"";"";settings::global_row_specify) does not work for me. But this does: executesql (" SELECT * FROM t1 FETCH FIRST " & settings::global_row_specify & " ROWS ONLY ";"";"";"") Edited August 20, 2015 by sal88
eos Posted August 18, 2015 Posted August 18, 2015 Has anyone had a problem using fetch with arguments (i.e. substituting the value with a '?')? That does not work; but you can use ExecuteSQL ( " SELECT * FROM t1 FETCH FIRST " & settings::global_row_specify " ROWS ONLY " ; "" ; "" )
Recommended Posts
This topic is 3522 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now