CREATE PROCEDURE dbo.InsertInboxMessage
@UserID uniqueIdentifier
@Message nvarchar(Max)
AS
INSERT INTO Messages(UsersID, Messages)
VALUES(@UserID, @Message)
It tells me that I have an error near @Message and that I must declare the scalar @UserID.
How do I correct those errors?
You are missing a Comma after the first parameter declaration
CREATE PROCEDURE dbo.InsertInboxMessage
@UserID uniqueIdentifier, -- Comma goes here!
@Message nvarchar(Max)
AS
INSERT INTO Messages(UsersID, Messages)
VALUES(@UserID, @Message)
References
You need a comma in between your variables.
CREATE PROCEDURE dbo.InsertInboxMessage
@UserID uniqueIdentifier,
@Message nvarchar(Max)
AS
INSERT INTO Messages(UsersID, Messages) VALUES(@UserID, @Message)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With