Finding pairs of seats

I need to perform a check to find out how many pairs of seats exist on a given performance. I can't do just a seat count because individual seats on opposite sides of the theatre are not desired. Here is a link to an image of the seat configuration and attached is a spreadsheet with the columns we have to work with:

https://securesite.lajollaplayhouse.org/_QA_/single/SYOS.aspx?p=9054

Note: The spreadsheet is the data related to the image provided.

I am having trouble figuring out a way to determine seats that are next to each other. Thanks for the help!
Capture.PNG
TX-PERF-SEAT.xlsx
rwaterzAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

ste5anSenior DeveloperCommented:

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
rwaterzAuthor Commented:
Thanks for that, i'll do some testing and see how it works out.

Wouldn't islands be what I am looking for? Gaps would be the break between seats and islands would be the pair (or greater) of seats...right?
ste5anSenior DeveloperCommented:
This is just a definion question. Islands are normally existing numbers, gaps are missing numbers. I would name already reserved seats as islands.
rwaterzAuthor Commented:
That is absolutely the solution!

I found this article: https://www.simple-talk.com/sql/t-sql-programming/the-sql-of-gaps-and-islands-in-sequences/ to be quite useful as well. I thought I'd share for others who may have a similar question. I would have never found that article without your help in identifying the type of solution I needed.

Thank you!
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft SQL Server 2008

From novice to tech pro — start learning today.