Locking

Categories: Code Problem / Data Structures and Algorithms / Recursion (32) Code Problem / Data Structures and Algorithms / Binary Search (30) Code Problem / Data Structures and Algorithms / Linked Lists (26) Code Problem / Data Structures and Algorithms / Backtracking (26) Code Problem / Data Structures and Algorithms / Stacks and Queues (25) Code Problem / Data Structures and Algorithms / Hashing (24) Databases / SQL / Backup and Recovery (19) Code Problem / Data Structures and Algorithms / Arrays and Strings (19) Databases / SQL / Database Normalization (18) Code Problem / Data Structures and Algorithms / Time Complexity (17) Databases / SQL / Locking (16) Databases / SQL / Replication (15) Databases / SQL / SQL Queries (13) Code Problem / Data Structures and Algorithms / Graphs (13) Databases / SQL / Database Security (13)  More...

Recent solutions:

Check these solutions from our community:
Databases / SQL DifficultyHard SQL
Design a SQL query that will return the titles of all books that are currently checked out from a library catalog.
About this solution: The candidate's solution is complete and solves the problem. The candidate's approach is straightforward and easy to understand.
Nov 28
Databases / SQL DifficultyHard SQL
This technical problem deals with getting all rows from a table, even if some of the rows are locked. The solution is to write a SQL query that will return all rows from the table.
About this solution: The candidate's solution is correct and demonstrates a good understanding of how to use the NOLOCK hint to read data from a table without being blocked by other processes.
Nov 25
Databases / SQL DifficultyHard SQL
Write a SQL query to sum the balances of all rows with an id greater than 5.
About this solution: The candidate's solution is correct and demonstrates a level of completeness. The candidate has correctly used the SUM function to add up the balances of all rows with an id that is greater than 5.
Nov 23
Databases / SQL DifficultyHard SQL
Given a table of data with three columns: id, start, and end, this SQL query will find all pairs of rows where the start and end times overlap.
About this solution: The candidate's solution is correct and demonstrates a good understanding of SQL. The solution is also optimal, as it uses a JOIN to find all pairs of rows that overlap.
Nov 20
Databases / SQL DifficultyHard SQL
This technical problem involves writing a query to find the number of items that are locked by each user in a given table. The output should show the user ID and the number of items locked for each user.
About this solution: This solution is complete and solves the problem. The approach is straightforward and easy to follow.
Nov 20
Databases / SQL DifficultyMedium SQL
Write a SQL query to find the names of all the items that have a price greater than or equal to $10.
About this solution: The solution above is optimal because it uses the WHERE clause to filter the results to only include items with a price greater than or equal to 10.
Nov 10
Databases / SQL DifficultyMedium SQL
This technical problem involves writing a SQL query to return the names of employees who have been with the company for more than 5 years.
About this solution: The candidate's solution is correct and uses an optimal approach.
Nov 09
Databases / SQL DifficultyMedium SQL
This technical problem asks for a SQL query to find all pairs of rows in a table where the values in the two columns are equal. The example input and output show what such a query would return.
About this solution: The candidate's solution is correct and demonstrates a level of completeness. The solution solves the problem and is a general approach.
Nov 08