From the course: Microsoft SQL Server 2019 Essential Training
Unlock the full course today
Join today to access over 24,900 courses taught by industry experts.
Create a view of the data - SQL Server Tutorial
From the course: Microsoft SQL Server 2019 Essential Training
Create a view of the data
- [Instructor] Any time that you pull information out of a SQL Server table, you're using a select statement that queries a list of tables and columns and processes the data according to your requirements. Select statements can get pretty complex, especially when multiple table joins and filtering criteria are in play. You can save the syntax of a select statement for future use by creating it as a view object. To create a view of the data stored in the Landon Hotel database, I'm going to find the views folder underneath the database, and right click on it and say new view. This brings up this window that says add table, and the view that I want to build involves the guest table, the room reservations table, and the rooms table. You can either select each one of these, then press the add button here, or you can simply double click on each one in the list. Once all three tables have been added, you can go ahead and close…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.