fixing a truncated table name#3571
Open
tohidemyname wants to merge 1 commit intonhibernate:masterfrom
Open
Conversation
hazzik
reviewed
Jul 2, 2024
| { | ||
| string name = base.GenerateTemporaryTableName(baseTableName); | ||
| return name.Length > 30 ? name.Substring(1, (30) - (1)) : name; | ||
| return name.Length > 30 ? name.Substring(0, (30) - (1)) : name; |
Member
There was a problem hiding this comment.
Suggested change
| return name.Length > 30 ? name.Substring(0, (30) - (1)) : name; | |
| return name.Length > 30 ? name.Substring(0, 30) : name; |
hazzik
reviewed
Jul 2, 2024
Comment on lines
+156
to
+158
| Assert.AreEqual( | ||
| 30, | ||
| temporaryTableName.Length); |
Member
There was a problem hiding this comment.
Suggested change
| Assert.AreEqual( | |
| 30, | |
| temporaryTableName.Length); | |
| Assert.That(temporaryTableName, Has.Length.EqualTo(30)); |
hazzik
reviewed
Jul 2, 2024
Comment on lines
+159
to
+162
| Assert.AreEqual( | ||
| "HT_TABLE_NAME_THAT_EXCEEDS_30_", | ||
| temporaryTableName | ||
| ); |
Member
There was a problem hiding this comment.
Suggested change
| Assert.AreEqual( | |
| "HT_TABLE_NAME_THAT_EXCEEDS_30_", | |
| temporaryTableName | |
| ); | |
| Assert.That(temporaryTableName, Is.EqualTo("HT_TABLE_NAME_THAT_EXCEEDS_30_")); |
Contributor
Author
|
@hazzik Thanks for the revision. It looks great for me. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When the Oracle8iDialect creates a temporary table name for tables with names longer than 27 characters, the "H" from the usual temporary table name prefix ("HT_") is truncated.
fix #3456