SQL ASCII Function Use and Examples
The ASCII function is used to return the ASCII value for the first character in a string.
2025-05-16
The ASCII function is used to return the ASCII value for the first character in a string.
2025-05-16
Microsoft provides T-SQL developers with three functions (rand, newid, and crypt_gen_random) for generating random numbers. Each of these functions is effective at returning random values, but feature sets associated with each function make them best suited to different use cases. This tip’s Solution section presents an overview of common use cases for random numbers in SQL Server along with references to learn more about random numbers in SQL Server.
2025-05-12
Learn how to work with dates and calculate particular dates or elapsed time periods with some of the functions available in SQL Server.
2025-05-09
2,099 reads
2025-05-07
397 reads
I know SQL cursors exist, but I am not sure how or why to use them. Can you provide a SQL cursor example? Can you give any guidance on when to use a SQL Server cursor?
2025-05-07
In a previous topic we discussed how to pass parameters into a stored procedure, but another option is to pass parameter values back out from a stored procedure. One option for this may be that you call another stored procedure that does not return any data, but returns parameter values to be used by the calling stored procedure.
2025-05-02
2025-04-23
386 reads
I have a lot of SQL update queries where I need to make IF/ELSE types of decisions. In some cases, I am using a cursor but looping through thousands of rows for update takes a long time. I also use some dynamic SQL to handle some query parameter decision making. Is there a better alternative?
2025-04-23
See how ISNULL and COALESCE behave in different situations and ensure you know which one to pick when.
2025-04-18
4,640 reads
Learn how to use the UPDATE statement, along with a few things to be aware of when changing data.
2025-04-11
1,514 reads
I was sick of changing context in Azure Data Studio while cleaning up things...
By Zikato
The crime spree in Digitown is not ending. This time 20 cars have been...
By Steve Jones
One of our mission statements in the Book of Redgate says: attempt to do...
Comments posted to this topic are about the item Shining a Light on Shadow...
Hi, I would love to hear if anyone can tell me why a CAST...
hi, one of our sister division's erp extract view is going thru at least...
In SQL Server, when the buffer manager write pages to disk, page protection is added to the pages. There are two types of protection: torn page protection and checksum page protection. What happens with regards to concurrency with page protection during writes?
See possible answers