Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2004
    Posts
    40

    Unanswered: SQL Server installed?

    Does anyone know how i can find out if SQL Server is installed on the current machine, and the version that is installed?

    Thank you in advance.

  2. #2
    Join Date
    Dec 2002
    Posts
    1,245

    Re: SQL Server installed?

    fire up query analyzer, attempt to connect to the machine (assuming you have a valid account or username/password). If you can connect, run SELECT @@Version to determine the version number of SQL that you are running.

    Alternatively, look in Program Files/Microsoft SQL Server. You should see two folders: \Bin and \80 (at least 80 is what you will see for a SQL 2000 installation.

    Regards,

    hmscott

  3. #3
    Join Date
    Jan 2004
    Posts
    40
    wouldn't checking the program files/micrsoft sql server folder be not reliable, since everyone can installed it in a different location. I would like to be able to check if sql server is intalled from code, before i query something from osql for example.

  4. #4
    Join Date
    Dec 2002
    Posts
    1,245
    Aiiee, sorry, I missed your point entirely. I didn't realize that you were trying to determine whether SQL was installed from code.

    Um, can't you check for the presence of a Service from the WSH environment. Don't have a clue what the script would look like, but I know that you can start/stop services from here.

    Regards,

    hmscott

  5. #5
    Join Date
    Jan 2004
    Posts
    40
    i'm trying to do this in vb6, it seems like wsh is very scripting languages only?

    does anyone have any other ideas?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •