• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Hibernate - Row Concatenation

 
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,
For some reason, It is always good to see ROWS concatenated for a distinct combination.

I have a requirement where:
ID NAME SUBJECT EXAMID MARKS
1 Dwarak English 1 90
1 Dwarak English 2 80
1 Dwarak XYZ 1 95

I need to show it as
ID NAME SUBJECT EXAMID MARKS
1 Dwarak English 1,2 90,80
1 Dwarak XYZ 1 95

Session session = SessionLocator.getSession();
Criteria criteria = session.createCriteria(ExamDetails.class);

The above is an example. I could have designed the table in a better way.

Can you please let me know how to do this in hibernate.
 
author and cow tipper
Posts: 5009
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Howdy Greenhorn!

Just a reminder to keep your subject lines in lower case letters. When you put it in all caps, it looks like you're shouting. I fixed it all up for ya.

 
dwarakanathan thiru
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sorry about that. I shall do that hereafter
 
What does a metric clock look like? I bet it is nothing like this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic