Windows Run Command
-
Hi World! what is the Windows Run Command for "SQLDataRoot" OR "SQLPath" for exp: %program files% --->open Program files. i wanna something the open the : c:\Program Files\SqlServer 2005 for DWebPro\MSSQL.1\MSSQL in other word i need this path to give to my setup to copy the database to the data path of that instance is installed. i know the instance name also but i cannot give the exact path.cause if sql server was installed in that machine there should be "MSSQL.1" and now it should change to : c:\Program Files\SqlServer 2005 for DWebPro\MSSQL.2\MSSQL So if i can give it something like %MSSQL$% it will solve the problem.
rem set mssqlver to the current version: 1, 2 etc
set mssqlver=1rem set path according to the current version
set mssqlpath="C:\Program Files\SqlServer 2005 for DWebPro\MSSQL.%mssqlver%\MSSQL"One of these days I'm going to think of a really clever signature.
-
Hi World! what is the Windows Run Command for "SQLDataRoot" OR "SQLPath" for exp: %program files% --->open Program files. i wanna something the open the : c:\Program Files\SqlServer 2005 for DWebPro\MSSQL.1\MSSQL in other word i need this path to give to my setup to copy the database to the data path of that instance is installed. i know the instance name also but i cannot give the exact path.cause if sql server was installed in that machine there should be "MSSQL.1" and now it should change to : c:\Program Files\SqlServer 2005 for DWebPro\MSSQL.2\MSSQL So if i can give it something like %MSSQL$% it will solve the problem.
Is it possible to change this path when wanna install sql express 2005 ?something like : c:\Program Files\SqlServer 2005 for DWebPro\
**_MSSQL.639_**
\MSSQL cause i can give parameter when wanna install sql server express 2005(command prompt) -
Is it possible to change this path when wanna install sql express 2005 ?something like : c:\Program Files\SqlServer 2005 for DWebPro\
**_MSSQL.639_**
\MSSQL cause i can give parameter when wanna install sql server express 2005(command prompt) -
I have shown you what you need to do, why not try some experimentation for yourself to see how you can vary that to your own needs?
One of these days I'm going to think of a really clever signature.
thanks for solution. but i dont understand where should i run that command or how to use that. My main Question is that : Is it possible to change "MSSQL.
**x**
" In this address "c:\Program Files\SqlServer 2005 for DWebPro\MSSQL.1\MSSQL" while installing sql express 2005 in command line? So that it wont generate it Automatically. I mean that i give that number while wanna install sql express 2005. Or More Clearly :I wanna change Instance Id and give my own Id while installing sql express 2005 !
Thanks in Advanced! -
thanks for solution. but i dont understand where should i run that command or how to use that. My main Question is that : Is it possible to change "MSSQL.
**x**
" In this address "c:\Program Files\SqlServer 2005 for DWebPro\MSSQL.1\MSSQL" while installing sql express 2005 in command line? So that it wont generate it Automatically. I mean that i give that number while wanna install sql express 2005. Or More Clearly :I wanna change Instance Id and give my own Id while installing sql express 2005 !
Thanks in Advanced!Your big black writing is not appreciated, normal font size and weight is perfectly adequate for all questions. As to your query, I don't know if that will work, you will need to look at the instructions for installing SQL Express.
One of these days I'm going to think of a really clever signature.
-
Your big black writing is not appreciated, normal font size and weight is perfectly adequate for all questions. As to your query, I don't know if that will work, you will need to look at the instructions for installing SQL Express.
One of these days I'm going to think of a really clever signature.
thanks for attention. But i am working on it but no idea and doesnt get ans. Plz help!
-
thanks for attention. But i am working on it but no idea and doesnt get ans. Plz help!
jojoba2011 wrote:
no idea and doesnt get ans.
As I said, you need to look at the instructions for installing SQL Express. Most products come with an installer that allows you to select the destination directory, but I do not know if you can do it with environment variables.
One of these days I'm going to think of a really clever signature.
-
jojoba2011 wrote:
no idea and doesnt get ans.
As I said, you need to look at the instructions for installing SQL Express. Most products come with an installer that allows you to select the destination directory, but I do not know if you can do it with environment variables.
One of these days I'm going to think of a really clever signature.
I didnt get any thing from it. Will you also check something for me.? Thanks in advanced !
-
I didnt get any thing from it. Will you also check something for me.? Thanks in advanced !
-
thanks for solution. but i dont understand where should i run that command or how to use that. My main Question is that : Is it possible to change "MSSQL.
**x**
" In this address "c:\Program Files\SqlServer 2005 for DWebPro\MSSQL.1\MSSQL" while installing sql express 2005 in command line? So that it wont generate it Automatically. I mean that i give that number while wanna install sql express 2005. Or More Clearly :I wanna change Instance Id and give my own Id while installing sql express 2005 !
Thanks in Advanced!There's a difference between the installation path, and an install-ID. If I understand you correctly, you're having trouble identifying which of the Sql Server-instances that's on the machine is yours. Is that correct, so far?
Bastard Programmer from Hell :suss: if you can't read my code, try converting it here[^]
-
There's a difference between the installation path, and an install-ID. If I understand you correctly, you're having trouble identifying which of the Sql Server-instances that's on the machine is yours. Is that correct, so far?
Bastard Programmer from Hell :suss: if you can't read my code, try converting it here[^]
Hi..thanks a lot...thats exactly correct but before installing i my self should give that value to sql express setup cause that value is static in my project.
-
Hi..thanks a lot...thats exactly correct but before installing i my self should give that value to sql express setup cause that value is static in my project.
Member 9473809 wrote:
thats exactly correct but before installing i my self should give that value to sql express setup
You're explaining what you "want" the software to do, not quite what you're trying to achieve. One can install Sql Server from the command prompt[^]. That way you could also predefine in which directory the app will be installed. A word of warning here; you'll be working under the assumptions that you have read/write rights in that location, and that the location exists. Both assumptions would fail on a networked PC here. What's more, most machines already have Sql Server, and it'd be preferable to hook up the database for a new app to one of the existing servers. Your app would fail again if someone moved the database to a different server. Here's the catch; I'm still wondering why you need to "know" this path. It's defined at install, fine, you could have a custom action in there that writes to the registry where it'll be located. In fact, you can "ask" Sql Server for it's storage- and backup-locations. What kind of data are you storing in there, and what kind of app are we talking about?
Bastard Programmer from Hell :suss: if you can't read my code, try converting it here[^]
-
Member 9473809 wrote:
thats exactly correct but before installing i my self should give that value to sql express setup
You're explaining what you "want" the software to do, not quite what you're trying to achieve. One can install Sql Server from the command prompt[^]. That way you could also predefine in which directory the app will be installed. A word of warning here; you'll be working under the assumptions that you have read/write rights in that location, and that the location exists. Both assumptions would fail on a networked PC here. What's more, most machines already have Sql Server, and it'd be preferable to hook up the database for a new app to one of the existing servers. Your app would fail again if someone moved the database to a different server. Here's the catch; I'm still wondering why you need to "know" this path. It's defined at install, fine, you could have a custom action in there that writes to the registry where it'll be located. In fact, you can "ask" Sql Server for it's storage- and backup-locations. What kind of data are you storing in there, and what kind of app are we talking about?
Bastard Programmer from Hell :suss: if you can't read my code, try converting it here[^]
I have read that before but isnt possible to give my own number to MSSQL.x .it creates automatically when wanna install sql. my main question is how can i give that number my self when wanna install sql express 2005 in command Prompt ? Thanks in advanced !
-
I have read that before but isnt possible to give my own number to MSSQL.x .it creates automatically when wanna install sql. my main question is how can i give that number my self when wanna install sql express 2005 in command Prompt ? Thanks in advanced !
-
hi sir, i wanna run setup via command prompt so will you please check that if its possible that to mentian that MSSQL.x in setup custom. My english isnt well. thanks in advanced!
-
hi sir, i wanna run setup via command prompt so will you please check that if its possible that to mentian that MSSQL.x in setup custom. My english isnt well. thanks in advanced!