Skip to content

Commit d3a7323

Browse files
committed
Fixed mismatched cases on TopicID
For SQL, we use uppercase `ID`, whereas for C# we use camelCase (`Id`) per Microsoft's guidance. This mismtach causes confusion—as seen here. Whoops.
1 parent 9b58a4b commit d3a7323

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

OnTopic.Data.Sql.Database/Stored Procedures/UpdateRelationships.sql

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,12 @@ INTO Relationships (
2020
RelationshipKey,
2121
Target_TopicID
2222
)
23-
SELECT @TopicId,
23+
SELECT @TopicID,
2424
@RelationshipKey,
2525
TopicID
2626
FROM @RelatedTopics Target
2727
LEFT JOIN Relationships Existing
28-
ON Target_TopicID = TopicId
28+
ON Target_TopicID = TopicID
2929
AND Source_TopicID = @TopicID
3030
WHERE Target_TopicID IS NULL
3131

@@ -37,7 +37,7 @@ IF @DeleteUnmatched = 1
3737
DELETE EXISTING
3838
FROM @RelatedTopics Relationships
3939
RIGHT JOIN Relationships Existing
40-
ON Target_TopicID = TopicId
40+
ON Target_TopicID = TopicID
4141
WHERE Source_TopicID = @TopicID
4242
AND ISNULL(TopicID, '') = ''
4343
END

OnTopic.Data.Sql.Database/Utilities/Stored Procedures/GenerateNestedSet.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ BEGIN
118118
END; -- while
119119

120120
SELECT Stack_Top,
121-
TopicId,
121+
TopicID,
122122
RangeLeft,
123123
RangeRight
124124
FROM Topics

0 commit comments

Comments
 (0)