Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
    Bookmark Topic Watch Topic
  • New Topic

Oracle - Retriving only latest data from a table if there is a Duplicate.

 
Shahir Deo
Ranch Hand
Posts: 80
Hibernate Java Oracle
  • Mark post as helpful
  • send pies
  • Report post to moderator
Hi Guys,

We are writing one select query to display the data in the table for Report purpose in GUI.

The Problem is In the Report we have duplicates (older data),

Ex:

Value -------------Start Date------------End Date-------------ID
1. XYZ(01) -------------21-01-13-------------21-01-14-------------01
2. XYZ(07) -------------11-01-13-------------11-01-14-------------07
3. XYZ(01) -------------21-01-12-------------21-01-13-------------01
4. XYZ(05) -------------05-01-11-------------21-06-11-------------05

After the Insertion of new record in table sr .1
it is displaying All the 1 , 2, 3, 4 .

But i need to eliminate or do not want to show the old ID :01 (sr.3) as the new ID:01 is inserted in Table.

Please Help.

Thanks
 
Martin Vajsar
Sheriff
Posts: 3752
62
Chrome Netbeans IDE Oracle
  • Mark post as helpful
  • send pies
  • Report post to moderator
Let's continue the discussion in your other thread.
 
    Bookmark Topic Watch Topic
  • New Topic