/*
Pieces of code that is being executed
*/
// our variable holding the query
private static string QUERY_ADMISSION_PERSONAL_DATA =
@"
SELECT QCLCOGNO as LastName, QCLNOME as FirstName, QCLLINGUA as PrintLanguage FROM JXPLURIF.QUADCL00F WHERE QCLDONUM=?
SELECT QRIVALORE as Consort FROM JXPLURIF.QUADRI00F WHERE QRIDONUM=? AND QRICODICE='0106'
SELECT QRIVALORE as Children FROM JXPLURIF.QUADRI00F WHERE QRIDONUM=? AND QRICODICE='0107'
SELECT QRIVALORE as DependentChildren FROM JXPLURIF.QUADRI00F WHERE QRIDONUM=? AND QRICODICE='0108'
SELECT QRIVALORE as Family FROM JXPLURIF.QUADRI00F WHERE QRIDONUM=? AND QRICODICE='0109'
SELECT QRIVALORE as DependentFamily FROM JXPLURIF.QUADRI00F WHERE QRIDONUM=? AND QRICODICE='0110'";
...
// our ODBC connection
var conn =new OdbcConnection();
...
// querying
using (var multi = conn.QueryMultiple(QUERY_ADMISSION_PERSONAL_DATA, new DynamicParameters(
new
{
Id = id
})))
{
...
}
// the following exception is thrown
"ERROR [42000] [IBM][System i Access ODBC Driver][DB2 for i5/OS]SQL0199 - Keyword SELECT not expected. Valid tokens: FOR WITH FETCH ORDER UNION EXCEPT OPTIMIZE.",