top of page
Topic
Recent Posts
Archive
Tags
Table UDF
You have a database that contains the following tables: BlogCategory, BlogEntry, ProductReview, Product, and SalesPerson. The tables were...
Partitioned and Indexed views
You have a Microsoft SQL Server database named DB1 that contains the following tables: OR OR There are no foreign key relationships...
Fixing the stored procedure
You have a memory-optimized table named Customer. The table is accessed by a stored procedure named ManageCustomer. The database was...
Schema permissions using the principle of least privilege
You need to ensure the administrator can perform the tasks using the principle of least privilege. Which schema permissions should you...
Table-valued parameters
You manage a database with tables named Invoice and InvoiceDetails. Each invoice may have multiple records. Users update the...
@@TRANCOUNT (T-SQL)
Many good resources for @@TRANCOUNT: https://docs.microsoft.com/en-us/sql/t-sql/functions/trancount-transact-sql?view=sql-server-ver15...
Enabling the collection of Info. for natively compiled stored procedures
The goal of using memory-optimized tables is to execute processes as quickly as possible. Consequently, you could be surprised that some...
Capturing natively complied stored procedure by Extended Events
An Extended Events session is the equivalent of a trace. When you create a session, you add an event and actions to fire with that event,...
Developing a stored procedure @Trancount
You are developing a stored procedure with the following requirements: ✑ Accepts an integer as input and inserts the value into a table....
Create Index Based on Query Plan
You use Query Store to optimize a query in a database. The query has two execution plans: ✑ Plan 2 is shown in the Plan 2 Execution...
bottom of page