If you pass the string "INSERT INTO table1(highlimit,lowlimit) VALUES (mes1,mes2)", mes1 and mes2 are not subsituted with their values if they are variables. You need first to build the string you are passing to DBImmediateSQL e.g:
char sql_cmd[200];
sprintf (sql_cmd, "INSERT INTO table1(highlimit,lowlimit) VALUES (%f,%f)", mes1, mes2);
resCode = DBImmediateSQL(hdbc, sql_cmd);
You may have a look on this post with the same problem