Subject | RE: [firebird-support] Firebird get the list with all available id |
---|---|
Author | Leyne, Sean |
Post date | 2013-01-29T16:18:25Z |
> In a table I have records with id's 2,4,5,8. How can I receive a list with valuesThe SQL looks OK and should work.
> 1,3,6,7. I have tried in this way
>
> SELECT t1.id + 1
> FROM table t1
> WHERE NOT EXISTS (
> SELECT *
> FROM table t2
> WHERE t2.id = t1.id + 1
> )
>
> but it's not working correctly. It doesn't bring all available positions.
What is the datatype of the ID column of the table?
Sean