Microsoft
Software
Hardware
Network
Question : What is the matter with this stored procedure
I have this stored procedure and it is giving me a error :
Incorrect syntax near the keyword 'TABLE'.
This is the code.
set ANSI_NULLS ON
set QUOTED_IDENTIFIER ON
GO
CREATE PROCEDURE [dbo].[spInsertQuestion]
@CategoryName varchar(50),
@Question varchar(350),
@Answer varchar(500)
AS
DECLARE #TempCatId TABLE
(
tCatID int
)
INSERT INTO #TempCatID(tCatId)
SELECT CatID
FROM Category
WHERE CategoryName = @CategoryName
Answer : What is the matter with this stored procedure
CREATE PROCEDURE [dbo].[spInsertQuestion]
@CategoryName varchar(50),
@Question varchar(350),
@Answer varchar(500)
AS
DECLARE @TempCatId TABLE
(
tCatID int
)
INSERT INTO @TempCatID(tCatId)
SELECT CatID
FROM Category
WHERE CategoryName = @CategoryName
Random Solutions
How do I change the currentproject.connection during run-time (or startup)?
Excel VBA - paste value into active cell and run addin against it
Moving sql server mdf file
Findcontrol (How do I?)
Resore Failed for TEXSEL\SQLEXPRESS
Easiest way to edit a row of data in ListView using C-Sharp
help with mysql query
I need to make a MSN bot
Hiding top of screen "ribbon". E.g. binoculars, filters, etc
How to set value member in listbox using Silverlight 3.0