Number Sequence Query

Поиск
Список
Период
Сортировка
От John Nix
Тема Number Sequence Query
Дата
Msg-id Pine.LNX.4.44.0210091609010.9811-100000@server.sblug.org
обсуждение исходный текст
Ответы Re: Number Sequence Query  (Josh Berkus <josh@agliodbs.com>)
Список pgsql-novice
I have a field with case numbers in it that I need to find out what
numbers are left out in the sequence.  The numbers can be formatted fairly
strangely, so let me give you an example:

 case_num
----------
 020018
 020020
 020021
 02002201
 020024

I'm only really looking at the numbers that start with 02 and the number
sequence is the 4 numbers right after the 02.  As you can see by my
example, 020023 is missing.  I would like to be able to run a query to
see all the missing numbers in sequence.  I'm not even sure where to start
looking for information.  I did searches from Google and in the groups
(which normally answers my questions), but I can't find anything.  Can
someone help me with this?  Thanks...

John


В списке pgsql-novice по дате отправления:

Предыдущее
От: Josh Berkus
Дата:
Сообщение: Re: Setting up PAM authentication
Следующее
От: "Devinder K Rajput"
Дата:
Сообщение: Re: Number Sequence Query