Last active
March 7, 2019 21:35
-
-
Save liuxd/f4f235ac393d6271a853d17560e8814b to your computer and use it in GitHub Desktop.
[IF EXISTS] #MSSQL
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
IF EXISTS (SELECT VCUserID FROM dbo.tPartnerVCUserAbilities WHERE VCUserID = :UserID AND SubjectID = :SubjectID) | |
BEGIN | |
UPDATE dbo.tPartnerVCUserAbilities SET [:itemName] = :itemValue WHERE VCUserID = :UserID AND SubjectID = :SubjectID | |
END | |
ELSE | |
BEGIN | |
INSERT INTO dbo.tPartnerVCUserAbilities (VCUserID, SubjectID, :itemName) VALUES (:UserID, :SubjectID, :itemValue) | |
END |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment