Hi @Rock Hitman ,
A small modification on Viorel-1's query and please refer below:
select * from [dbo].[TestData] Where ([ID]-1) /12 =@PINNum
Equals to
Select * from [dbo].[TestData] Where [ID] between ((@PINNum*12) + 1) AND (@PINNum+1)*12
Best regards
Melissa
If the answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.