all groups > sql server msde > january 2005 >
You're in the

sql server msde

group:

Adding a .sql to MSDE Server


Adding a .sql to MSDE Server Mustafa Rabie
1/27/2005 7:44:25 PM
sql server msde:
Hi All,

I have a .SQL script file that contains database definitions. How can i run
the .sql script file to add this database to my MSDE SQL server?

Thanks for your help
mustafa

Re: Adding a .sql to MSDE Server Steve Thompson
1/28/2005 10:14:25 AM
[quoted text, click to view]

Start a command prompt and use OSQL... enter: OSQL -? to get the available
options.

Steve

Re: Adding a .sql to MSDE Server J.A.
1/29/2005 5:21:36 PM
Hi, this is from "Microsoft SQL Server 2000 Sample Database Scripts"
[http://www.microsoft.com/downloads/details.aspx?FamilyId=06616212-0356-46A0-8DA2-EEBC53A68034&displaylang=en]

To run the scripts using osql:

1.. Open a Command Prompt window.
2.. From the command prompt, use the cd command to navigate to the folder
containing the SQL Server 2000 Sample Database Scripts:
cd c:\program files\SQL Server 2000 Sample Databases

3.. Run osql specifying either Instpubs.sql or Instnwnd.sql as the input
file. These are some examples:
a.. To install the Northwind database on a default instance on the same
computer:
osql -E -i instnwnd.sql

b.. To install the pubs database on a default instance on a different
computer:
osql -E -S ComputerName -i instpubs.sql

c.. To install the Northwind database on a named instance:
osql -E -S ComputerName/InstanceName -i instnwnd.sql


--
J.Alberto
[ccs-ve]
Nota: no enviar mensajes a mi direccion e-mail,
solo spam. Avisar para asignarle un filtro y no sea
eliminado.

AddThis Social Bookmark Button