[odb-users] Request return different results if executed in command line

Boris Kolpackov boris at codesynthesis.com
Mon Dec 15 08:41:06 EST 2014


Hi Romain,

Romain Gros <grosr.romain at gmail.com> writes:

> I am experiencing this problem on MySQL and PostgreSQL.

If you get the same difference in behavior using both databases then
there is definitely some logical difference between the two queries
that you are running. It is very unlikely to be a bug in the runtime
or a configuration issue.

One thing that you can do is to try to simplify the query by going
back one step at a time and see where the difference disappears (or
you get the result that you would expect). For example, remove
aggregation and see if you get the expected number of rows.

If that doesn't help, then I would need a complete working example
that reproduces the problem. In the fragments that you have provided
I don't see anything wrong.


> PPS: I had another quick question, is it possible to make sub-queries in
> the where clause using ODB instead of writing pure sql in the query?

There is no direct support yet but you should be able to write them
using the mixed style (e.g., using C++ identifier for column names,
etc).

Boris



More information about the odb-users mailing list