Hi Lighfer,

You can use UserRes object as a key and as a value at same time, but do not
forget to override hashcode() and equals() methods.

On Wed, Feb 8, 2017 at 11:57 AM, Lighfer <ligh...@gmail.com> wrote:

> thanks for your reply.
>
> Now it works, but there is a new problem, it looks like every table must
> has
> a _key field, how to deal with middle table?
>
> example:
> class User {
>     @QuerySqlField(index = true)
>     Integer userId;
>     ...
> }
>
> class Res {
>     @QuerySqlField(index = true)
>     Integer resId;
>     ...
> }
>
> class UserRes {
>     @QuerySqlField(index = true)
>     Integer userId;
>     @QuerySqlField(index = true)
>     Integer resId;
>     ...
> }
>
> The UserRes class has no field can be used as _key.
>
>
>
> --
> View this message in context: http://apache-ignite-users.
> 70518.x6.nabble.com/pure-memory-SQL-Grid-tp10464p10501.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>

Reply via email to