I have a table called customers (id(primary key), customer name, purchase date, and receipt number(foreign key))
and
another table called purchases (receipt number(primary key), details, amount)
the mapping is done correctly (many to one)
I want to find out the most recent purchases for each customer with the amount shown. So, basically, the result is a list of unique customers, sorted by purchase date, and grouped by customers name, with the purchase amout shown. Is this possible?
How do I do that?
Any help is welcome, a concrete example will be even better
Thanks a ton
hi, I am new to hibernate and need some help
I have a table called customers (id(primary key), customer name, purchase date, and receipt number(foreign key))
and
another table called purchases (receipt number(primary key), details, amount)
the mapping is done correctly (many to one)
I want to find out the most recent purchases for each customer with the amount shown. So, basically, the result is a list of unique customers, sorted by purchase date, and grouped by customers name, with the purchase amout shown. Is this possible?
How do I do that?
Any help is welcome, a concrete example will be even better
Thanks a ton