Please, next time, create a new topic for each new subject or question : you start speaking about
qx::dao::count function, then about stored procedure, and now about
qx_query class.
It will be more easier for users of this forum to find an information if you create a new topic for each new subject...
Why do you advice to write SQL code directly?
I don't recommend one option or another option : with
qx_query class, you just have the choice, you can write your SQL query directly, or you can build it using C++ style.
As you said, the C++ style provides some advantages : auto parameters binding, and portable database (this is the case for example with the
limit() method which is different for each databases).
But sometimes, for easy and short query, I prefer to write directly the SQL.
It depends on your project and how do you prefer to write your queries.
The only limitation is : with the same instance of
qx_query class, when you start to write your query with a style (C++ style or SQL query), you can't mix them (you will have an assert in debug mode in this case).
Google says that LINQ for C++ is already in developing (boolinq or linq++). But it is for STL containers.
For SQL seems we have nothing at all.
Wrong, you have qx_query class
And thank you, I didn't know linq++ project !
PS: please, let me know when you will have tested it, if the last BETA (QxOrm 1.2.4 BETA 16) is working fine for you with the new function
qx::dao::execute_query.