Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Database & SysAdmin
  3. Database
  4. SQL Server 2005 express issue

SQL Server 2005 express issue

Scheduled Pinned Locked Moved Database
helpdatabasecsharpsql-servervisual-studio
9 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    ninkk
    wrote on last edited by
    #1

    Hallo, we have a pc that has Visual Studio and Sql Server 2005 Express installed on it, lets name it SERVER. We did a small project/application on SERVER with Visual Studio that has to be installed on another pc(client pc, lets name it CLIENTPC) and make some sql queries. The Database is placed on SERVER and the small project/application is placed on CLIENTPC. The application makes some queries from CLIENTPC to SERVER. Our problem is that we get error even from the beginning of the application, when we run it from CLIENTPC on myConnection.Open() method. We have to notice that the CLIENT machine does not have sql server express installed on it, and it seems that we are missing something here. In sql server 2000, installation of MDAC was enough but in server express 2005 there are no MDAC. Any idea what we have to do so client could 'see' and 'work' with SERVER database files? Thanks in advance

    M 1 Reply Last reply
    0
    • N ninkk

      Hallo, we have a pc that has Visual Studio and Sql Server 2005 Express installed on it, lets name it SERVER. We did a small project/application on SERVER with Visual Studio that has to be installed on another pc(client pc, lets name it CLIENTPC) and make some sql queries. The Database is placed on SERVER and the small project/application is placed on CLIENTPC. The application makes some queries from CLIENTPC to SERVER. Our problem is that we get error even from the beginning of the application, when we run it from CLIENTPC on myConnection.Open() method. We have to notice that the CLIENT machine does not have sql server express installed on it, and it seems that we are missing something here. In sql server 2000, installation of MDAC was enough but in server express 2005 there are no MDAC. Any idea what we have to do so client could 'see' and 'work' with SERVER database files? Thanks in advance

      M Offline
      M Offline
      Marek Grzenkowicz
      wrote on last edited by
      #2

      ninkk wrote:

      Our problem is that we get error even from the beginning of the application, when we run it from CLIENTPC on myConnection.Open() method.

      Can you post this error?

      N 1 Reply Last reply
      0
      • M Marek Grzenkowicz

        ninkk wrote:

        Our problem is that we get error even from the beginning of the application, when we run it from CLIENTPC on myConnection.Open() method.

        Can you post this error?

        N Offline
        N Offline
        ninkk
        wrote on last edited by
        #3

        Maybe i was not completely clear. The error we get is the regular windows error, the asks if we want to send this error to microsoft. There is no problem with the code we use, because when we run the application on the SERVER machine that has installed SQL SERVER 2005 express and the database files, everything works perfect. Problem occurs when we try to run the application from a CLIENT machine and it connects to the database based on SERVER machine, but in cliet machine(win XP SP2) we do not have installed sql server express or mdac. Do we have to install something or to do something else?

        M 1 Reply Last reply
        0
        • N ninkk

          Maybe i was not completely clear. The error we get is the regular windows error, the asks if we want to send this error to microsoft. There is no problem with the code we use, because when we run the application on the SERVER machine that has installed SQL SERVER 2005 express and the database files, everything works perfect. Problem occurs when we try to run the application from a CLIENT machine and it connects to the database based on SERVER machine, but in cliet machine(win XP SP2) we do not have installed sql server express or mdac. Do we have to install something or to do something else?

          M Offline
          M Offline
          Marek Grzenkowicz
          wrote on last edited by
          #4

          1. How do you connect to the database? Can you post appropriate piece of code? 2. Can you download this tool[^] on the client machine and try if you can connect to the server?

          N 1 Reply Last reply
          0
          • M Marek Grzenkowicz

            1. How do you connect to the database? Can you post appropriate piece of code? 2. Can you download this tool[^] on the client machine and try if you can connect to the server?

            N Offline
            N Offline
            ninkk
            wrote on last edited by
            #5

            1. I connect using myConnection.Open(). Before attempting to connect, myConnection.ConnectionString="Provider=SQLOLEDB.1;Persist Security Info=False;UID=user;PWD=111;Initial Catalog=MyCatalog;Data Source=SERVERPC\SQLEXPRESS" After this we make myConnection.Open() This works fine only if it runs on SERVER pc that has the sql server express and database files, and when it runs on pc CLIENT that has nothing does not work, we get windows error. 2. After trying this tool, it works fine only while executing from the SERVER pc. When i try it from CLIENT pc, we get this error: "Unable to connect:An error occured while establishing a connection to the server. When connecting to SQL Server 2005, this failure maybe caused by the fact that under the default settings SQL Server does not allow romote connections. )provider: SQL Network Interfaces, erroe: 26 - Error Locationg Server/Instance Specified" To try is we put on SQL Server tab, on Server, "clientpc\sqlexpress" and login name and password. Thanks for helping....

            N M 2 Replies Last reply
            0
            • N ninkk

              1. I connect using myConnection.Open(). Before attempting to connect, myConnection.ConnectionString="Provider=SQLOLEDB.1;Persist Security Info=False;UID=user;PWD=111;Initial Catalog=MyCatalog;Data Source=SERVERPC\SQLEXPRESS" After this we make myConnection.Open() This works fine only if it runs on SERVER pc that has the sql server express and database files, and when it runs on pc CLIENT that has nothing does not work, we get windows error. 2. After trying this tool, it works fine only while executing from the SERVER pc. When i try it from CLIENT pc, we get this error: "Unable to connect:An error occured while establishing a connection to the server. When connecting to SQL Server 2005, this failure maybe caused by the fact that under the default settings SQL Server does not allow romote connections. )provider: SQL Network Interfaces, erroe: 26 - Error Locationg Server/Instance Specified" To try is we put on SQL Server tab, on Server, "clientpc\sqlexpress" and login name and password. Thanks for helping....

              N Offline
              N Offline
              ninkk
              wrote on last edited by
              #6

              Replace this "To try is we put on SQL Server tab, on Server, "clientpc\sqlexpress" and login name and password." with this "To try it we put on SQL Server tab, on Server textbox, "serverpc\sqlexpress" and login name and password."

              1 Reply Last reply
              0
              • N ninkk

                1. I connect using myConnection.Open(). Before attempting to connect, myConnection.ConnectionString="Provider=SQLOLEDB.1;Persist Security Info=False;UID=user;PWD=111;Initial Catalog=MyCatalog;Data Source=SERVERPC\SQLEXPRESS" After this we make myConnection.Open() This works fine only if it runs on SERVER pc that has the sql server express and database files, and when it runs on pc CLIENT that has nothing does not work, we get windows error. 2. After trying this tool, it works fine only while executing from the SERVER pc. When i try it from CLIENT pc, we get this error: "Unable to connect:An error occured while establishing a connection to the server. When connecting to SQL Server 2005, this failure maybe caused by the fact that under the default settings SQL Server does not allow romote connections. )provider: SQL Network Interfaces, erroe: 26 - Error Locationg Server/Instance Specified" To try is we put on SQL Server tab, on Server, "clientpc\sqlexpress" and login name and password. Thanks for helping....

                M Offline
                M Offline
                Marek Grzenkowicz
                wrote on last edited by
                #7

                Can you see anything like SQL Server Surface Area Configuration in the Start Menu? I'm not sure if SQL Server Express Edition has this tool. If yes, check if remote connections to your database are allowed (BTW, this is what the error you posted above suggests to check).

                N 1 Reply Last reply
                0
                • M Marek Grzenkowicz

                  Can you see anything like SQL Server Surface Area Configuration in the Start Menu? I'm not sure if SQL Server Express Edition has this tool. If yes, check if remote connections to your database are allowed (BTW, this is what the error you posted above suggests to check).

                  N Offline
                  N Offline
                  ninkk
                  wrote on last edited by
                  #8

                  Yes, i found SQL Server Surface Area Configuration. I clicked on Surface Area Configuration for Services and Connection. From there i set the reomote connections to TCP\Ip for both MSSMLBIZ and SQLEXPRESS. But is still the same, cannot connect. I even set the windows firewall to off, but still not connecting.

                  M 1 Reply Last reply
                  0
                  • N ninkk

                    Yes, i found SQL Server Surface Area Configuration. I clicked on Surface Area Configuration for Services and Connection. From there i set the reomote connections to TCP\Ip for both MSSMLBIZ and SQLEXPRESS. But is still the same, cannot connect. I even set the windows firewall to off, but still not connecting.

                    M Offline
                    M Offline
                    Marek Grzenkowicz
                    wrote on last edited by
                    #9

                    Please check this link[^]. What is MSSMLBIZ?

                    1 Reply Last reply
                    0
                    Reply
                    • Reply as topic
                    Log in to reply
                    • Oldest to Newest
                    • Newest to Oldest
                    • Most Votes


                    • Login

                    • Don't have an account? Register

                    • Login or register to search.
                    • First post
                      Last post
                    0
                    • Categories
                    • Recent
                    • Tags
                    • Popular
                    • World
                    • Users
                    • Groups