Let suppose my database data structure is like that
ShopId Transaction
001 1.000
001 2.000
001 3.000
002 1.000
002 2.000
002 3.000
Now it is might possible that some transaction are missing let suppose
002 4.000
002 6.000
In above table 5.000 transaction of table is missing.
I want to write a query that find the missing sequence number like above in my database.
So my query will return result
shopid transaction
002 5.000