Forum Stats

  • 3,824,917 Users
  • 2,260,439 Discussions


returning wrong ID from query

hello guys i not really expert on oracle . I am a python developer and i have too work with oracle 11 G in a project .

I have a simple table with 3 field the problem is the first field .

I have created the numeric field called ID and after that i created a sequence and a trigger for that to build an auto increment primary key field.

everything works fine but there is a problem. when i use query to get data from table like SELECT id FROM table , the query returns ids started from 1 to end (like rownum) and not the real id from datas and ids is really important to me to get some slice of the return of query and do some thins

my python is 3.6.8

lib is cx_oracle

db version is oracle 11G standard eddition