July 13, 2018 at 1:33 pm
Solomon Rutzky - Friday, July 13, 2018 1:09 PMLynn Pettis - Friday, July 13, 2018 12:57 PMSolomon Rutzky - Friday, July 13, 2018 12:23 PMPlease also note that transaction names are treated as having a binary Collation (not case-sensitive as the documentation currently states), regardless of the Instance-level or Database-level Collations.For details, please see the Transaction Names section of the following post: What’s in a Name?: Inside the Wacky World of T-SQL Identifiers
Take care,
Solomon...I thought that binary collations were case-sensitive? Decided to check for myself and was surprised.
It is a very common misconception that binary comparisons are case-sensitive (or anything sensitive, such as accent-sensitive, or width sensitive, etc), which is why I was clarifying there. Regarding the "checking", were you referring to this post:
No, Binary Collations are not Case-Sensitive
Take care,
Solomon...
Had not seen that. I was just going on what you said earlier.
July 14, 2018 at 5:49 am
Solomon Rutzky - Friday, July 13, 2018 12:23 PMThe name can be in excess of 32 characters, but only the first 32 characters are actually used.
Hi Steve. Regarding the statement from the article quoted above (pertaining to transaction name length), please note that the silent truncation you are referring to only applies to using a variable for the transaction name. If you are using a literal / constant for the transaction name, then you will get an error if you attempt to use more than 32 characters.
Please also note that transaction names are treated as having a binary Collation (not case-sensitive as the documentation currently states), regardless of the Instance-level or Database-level Collations.
For details, please see the Transaction Names section of the following post: What’s in a Name?: Inside the Wacky World of T-SQL Identifiers
Take care,
Solomon...
I wasn't aware of that, thanks for the information.
Steve.
July 16, 2018 at 2:33 am
Solomon Rutzky - Friday, July 13, 2018 9:45 AMsTTu - Monday, January 4, 2016 4:17 AMInteresting stuff and a few things I wasn't aware of.Would have liked to see errors and xact_abort covered also as this has caught me out in the past.Hi there. I posted an answer to DBA.StackExchange a few years ago on this topic and did include error handling, XACT_ABORT, XACT_STATE(), etc:
How to rollback when 3 stored procedures are started from one stored procedure
I hadn't seen that but very glad you pointed it out, what an excellent response - an article in itself!
Viewing 3 posts - 16 through 17 (of 17 total)
You must be logged in to reply to this topic. Login to reply