Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Creating Stored Procedures on SQL 2005???

0 views
Skip to first unread message

Toni

unread,
Nov 7, 2009, 12:07:57 PM11/7/09
to
I need to create stored procedures for a website that uses MS SQL 2005. My website
application is programmed using ASP (VBScript).

For "portability" of my application, can someone tell me if is it possible to create a
stored procedure using an ASP file, instead of logging into my SQL database? This would
make it easier to install the application on other websites, the "run once" file that
creates the database tables, columns, and initial data can also create the stored
procedures.

Second, can anyone show me a language reference for stored procedures? I can search for
and see plenty of EXAMPLES of stored procedures, but I can't find a language reference
for creating a new one.

Thanks!!!


Erland Sommarskog

unread,
Nov 7, 2009, 12:48:52 PM11/7/09
to
Toni (Ton...@yahoo.com) writes:
> I need to create stored procedures for a website that uses MS SQL 2005.
> My website application is programmed using ASP (VBScript).
>
> For "portability" of my application, can someone tell me if is it
> possible to create a stored procedure using an ASP file, instead of
> logging into my SQL database? This would make it easier to install the
> application on other websites, the "run once" file that creates the
> database tables, columns, and initial data can also create the stored
> procedures.

Yes, could write an ASP file that creates the stored procedures. It
would pobably be simpler to put the procedures in separate files, and
then have you ASP program, to read these files and load the files,
rather than nesting the code into the ASP script.


> Second, can anyone show me a language reference for stored procedures? I
> can search for and see plenty of EXAMPLES of stored procedures, but I
> can't find a language reference for creating a new one.

Have you looked at the topic for CREATE PROCEDURE in Books Online?


--
Erland Sommarskog, SQL Server MVP, esq...@sommarskog.se

Links for SQL Server Books Online:
SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx
SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx
SQL 2000: http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx

Uri Dimant

unread,
Nov 8, 2009, 5:42:18 AM11/8/09
to
In addition to Erland's reply
In SSMS go the View menu and navigate to Template Explorer and see the
syntax how to create variant of objects


"Toni" <Ton...@yahoo.com> wrote in message
news:efEIoz8X...@TK2MSFTNGP04.phx.gbl...

Toni

unread,
Nov 10, 2009, 12:46:47 PM11/10/09
to

"Erland Sommarskog" wrote...

> Toni (Ton...@yahoo.com) writes:
>> I need to create stored procedures for a website that uses MS SQL 2005.
>> My website application is programmed using ASP (VBScript).
>>
>> For "portability" of my application, can someone tell me if is it
>> possible to create a stored procedure using an ASP file, instead of
>> logging into my SQL database? This would make it easier to install the
>> application on other websites, the "run once" file that creates the
>> database tables, columns, and initial data can also create the stored
>> procedures.
>
> Yes, could write an ASP file that creates the stored procedures. It
> would pobably be simpler to put the procedures in separate files, and
> then have you ASP program, to read these files and load the files,
> rather than nesting the code into the ASP script.
>
>
>> Second, can anyone show me a language reference for stored procedures? I
>> can search for and see plenty of EXAMPLES of stored procedures, but I
>> can't find a language reference for creating a new one.
>
> Have you looked at the topic for CREATE PROCEDURE in Books Online?
>

It looks like CREATE PROCEDURE is what I'm looking for, thanks!
http://msdn.microsoft.com/en-us/library/aa258259%28SQL.80%29.aspx

Toni

unread,
Nov 10, 2009, 12:51:38 PM11/10/09
to
"Uri Dimant" wrote...

> In addition to Erland's reply
> In SSMS go the View menu and navigate to Template Explorer and see the syntax how to
> create variant of objects

Is SQL Server Management Studio (SSMS) only available for MS SQL 2005?
http://msdn.microsoft.com/en-us/library/ms174173.aspx

I'm asking because I can't find SSMS for MS SQL 2008, and I might upgrade.someday from
MSSQL2005 to MSSQL2008.

Thanks!!!


Uri Dimant

unread,
Nov 11, 2009, 3:03:46 AM11/11/09
to
Toni
Yes it is, but if you use SQL Server Express Edition you will need to
download it separately from MS site

"Toni" <Ton...@yahoo.com> wrote in message

news:%23nI$35iYKH...@TK2MSFTNGP03.phx.gbl...

Rick Byham, MSFT

unread,
Nov 11, 2009, 11:15:20 AM11/11/09
to
If you installed one of the regular edition, run setup again and add the
tools.
If you installed SQL Server Express Edition, get Management Studio from
https://www.microsoft.com/downloads/details.aspx?FamilyID=08e52ac2-1d62-45f6-9a4a-4b76a8564a2b&displayLang=en

--
Rick Byham, MSFT
(Implies no warranty or rights)


"Uri Dimant" <ur...@iscar.co.il> wrote in message
news:ex9HOVqY...@TK2MSFTNGP02.phx.gbl...

Toni

unread,
Nov 13, 2009, 12:46:18 PM11/13/09
to
Rick, right now, no SQL Server components are installed on my Windows XP Pro laptop.

I went to your link to download Management Studio. However, after I saved the file and
ran the .exe, it seems that it wants to install the full version of SQL Server 2008
Express - is that correct? And it will automatically install Management Studio during
the install?

Thanks,

Toni

"Rick Byham, MSFT" <ric...@microsoft.com> wrote in message
news:%236Fwrou...@TK2MSFTNGP05.phx.gbl...

Rick Byham, MSFT

unread,
Nov 16, 2009, 11:59:14 AM11/16/09
to
That link is supposed to just install Management Studio. The setup program
is the same with different options. If you run it, I think you will get a
features dialog box where you can select what you want to install. (I can't
test this because I already have everything installed on my computers and I
can't reliably predict your experience.)

--
Rick Byham, MSFT
(Implies no warranty or rights)

"Toni" <Ton...@yahoo.com> wrote in message

news:uQTr6kIZ...@TK2MSFTNGP04.phx.gbl...

0 new messages