Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Error in Code when creating SP
Message
De
18/09/2007 15:52:00
 
 
À
18/09/2007 15:43:09
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Stored procedures, Triggers, UDFs
Versions des environnements
SQL Server:
SQL Server 2005
Divers
Thread ID:
01255212
Message ID:
01255263
Vues:
14
< snip >
>>>>Hi Borislav,
>>>>I will try your select statement. The Tables are created, from vfp, just before the calling of the SP, because the tables need to be there beyond the SP. I am just trying to build the SP so that I can call it from vfp now.
>>>>
>>>>Thanks,
>>>>Beth
>>>
>>>No matter, run this in QA or SSMS just to create SP, then you could DROP Tables and use that SP from everywhere you need it. You don't have to fill the tables. Just don't forget GO before CREATE PROCEDURE statement. I am not sure right now if CREATE PROCEDURE must be the first line in the batch, but just in case :-).
>>
>>Okay Borislav,
>>
>>I put that my create tables into the SSMS with the create SP. But, the error still showed up, and the line Number did NOT change. Which makes the error on my create procedure line. It makes no sense!
>>This is the start for my SP without the create tables:
>>
>>-- ================================================
>>-- Template generated from Template Explorer using:
>>-- Create Procedure (New Menu).SQL
>>--
>>-- Use the Specify Values for Template Parameters
>>-- command (Ctrl-Shift-M) to fill in the parameter
>>-- values below.
>>--
>>-- This block of comments will not be included in
>>-- the definition of the procedure.
>>-- ================================================
>>SET ANSI_NULLS ON
>>GO
>>SET QUOTED_IDENTIFIER ON
>>GO
>>-- =============================================
>>-- Author:		<Elizabeth Walsh>
>>-- Create date: <29 August 2007>
>>-- Description:	<Procedure to fill temptable buspass>
>>-- =============================================
>>CREATE PROCEDURE
>>
>
>
>Where you put CREATE TABLES?
>There must be something like that:
>
&& tables created up here
>-- ================================================
>-- Template generated from Template Explorer using:
>-- Create Procedure (New Menu).SQL
>--
>-- Use the Specify Values for Template Parameters
>-- command (Ctrl-Shift-M) to fill in the parameter
>-- values below.
>--
>-- This block of comments will not be included in
>-- the definition of the procedure.
>-- ================================================
>SET ANSI_NULLS ON
>GO
>SET QUOTED_IDENTIFIER ON
>GO
>CREATE TABLE #.....
>CREATE TABLE #.....
>CREATE TABLE #.....
>GO
>
>-- =============================================
>-- Author:		<Elizabeth Walsh>
>-- Create date: <29 August 2007>
>-- Description:	<Procedure to fill temptable buspass>
>-- =============================================
>CREATE PROCEDURE ...
>
>
>What I meant is that the tables MUST exist when you create SP.

I have them, I did not put them in here, because they are so big - 122 lines by themselves. I just wanted to show you my beginning, because you were commenting on what you thought I had there.

See above for &&.

Beth
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform