Hello Friends,

Here is another popular lab from Hands-On-Lab library: Working With SEQUENCE in SQL Server.

In Transact-SQL (T-SQL) 2012 SEQUENCE is a user-defined object to generate sequence of numbers based on the specifications while created. NEXT VALUE FOR function generates sequence number from the specified SEQUENCE object. This lab is divided into six exercises explaining the usage of SEQUENCE in different scenarios such as inserting sequence number into a table, generate sequence numbers in the select statement, generating sequence numbers in result set, generate sequence numbers using OVER clause.

Exercise 1: INSERT Sequence numbers into a table
Exercise 2: Generate sequence numbers in the SELECT statement
Exercise 3: Generate repeating sequence numbers in the result set
Exercise 4: Generate sequence numbers using OVER clause
Exercise 5: Self-Assessment
Exercise 6: T-SQL Challenge

SQLMaestros Hands-On-Labs enables the practical way of learning. Each lab document consists of multiple exercises and each exercise consists of multiple tasks. Apart from step-by-step instructions, the HOL document contains images, explanations, observations, notes, tips & tricks to ensure a great learning experience. With each lab, you can practice a specific concept step-by-step. With our HOL documents, you will get hands-on with hundreds of topics in SQL Server & Microsoft Data Platform. Learn More.

Learn More

 

 

Happy Learning – The Practical Way.

Data Platform Virtual Summit 2020

Subscribe to SQLMaestros YouTube channel. If you want more learning content in your inbox, subscribe to SQLMaestros Bulletin.

SQLMaestros YouTube | SQLMaestros Bulletin | SQLMaestros Twitter