• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to retrieve an element from Array list?  RSS feed

 
priyanshi bhardwaj
Ranch Hand
Posts: 53
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My Array list
[Entity of type entity.test.marks with id: 25, Entity of type entity.test.marks with id: 32, Entity of type entity.test.marks with id: 39, Entity of type entity.test.marks with id: 46, Entity of type entity.test.marks with id: 53]
this is the how it is stored in database
Marks= {ArrayList@883}  size = 5
> 0 = {Marks@883} "Entity of type entity.test.marks with id: 25"
  name = "Science"
  id = {Long@8892} "25"


I want only the id field from my array list how can I do this in java?
 
priyanshi bhardwaj
Ranch Hand
Posts: 53
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I figured it out on my own. Sorry for wasting your time.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!