none
Connect to SQL Azure via SQL Server Management Studio failed

    שאלה

  • Hi ,
    I did the steps in the Windows Azure Platform Training Kit for SQL Azure
    succeeded to connect to the master DB then create new DB and connect to it
    suddenly when I try to connect again to any of the DB's I receive this error message
    Invalid object name 'sys.configurations'. (Microsoft SQL Server, Error: 208)
    Somebody have some answers?
    Thanks
    Ron

    יום שישי 21 אוגוסט 2009 18:44

תשובות

  • You need to follow these steps when connecting:

    1. cancel out of the first connection dialog that pops up.
    2. click on the New Query button from the toolbar (upper left)
    3. entered
           Server name: full servername
           Login: just the username (no @...)
    4. Under Options, Connect to Database, I typed TestDb1
    5. Hit connect.

    Stan
    Program Manager, SQL Azure
    • סומן כתשובה על-ידי Stan Kitsis - MSFT יום רביעי 26 אוגוסט 2009 04:14
    יום שלישי 25 אוגוסט 2009 21:25
  • Ron,

    Let us know if the issues resurfaces. 

    Stan
    Program Manager, SQL Azure
    • סומן כתשובה על-ידי Stan Kitsis - MSFT יום שישי 21 אוגוסט 2009 22:18
    יום שישי 21 אוגוסט 2009 22:18

כל התגובות

  • Afrer drop and re-create the second DB it's resolved for now..
    יום שישי 21 אוגוסט 2009 20:43
  • Ron,

    Let us know if the issues resurfaces. 

    Stan
    Program Manager, SQL Azure
    • סומן כתשובה על-ידי Stan Kitsis - MSFT יום שישי 21 אוגוסט 2009 22:18
    יום שישי 21 אוגוסט 2009 22:18
  • Same Error. Trying to connect from SSMS 2008, both to master Database and to <MyDatabase>.
    יום שלישי 25 אוגוסט 2009 09:18
  • You need to follow these steps when connecting:

    1. cancel out of the first connection dialog that pops up.
    2. click on the New Query button from the toolbar (upper left)
    3. entered
           Server name: full servername
           Login: just the username (no @...)
    4. Under Options, Connect to Database, I typed TestDb1
    5. Hit connect.

    Stan
    Program Manager, SQL Azure
    • סומן כתשובה על-ידי Stan Kitsis - MSFT יום רביעי 26 אוגוסט 2009 04:14
    יום שלישי 25 אוגוסט 2009 21:25
  • Hello Stan

    I followed your instruction and still get error as follows,

    'ansi_nulls' is not a recognized SET option

    I am using ssms 2008.
    יום רביעי 26 אוגוסט 2009 00:45
  • This is just a warning.  Click ok and you should be connected.

    Stan
    Program Manager, SQL Azure
    • סומן כתשובה על-ידי Stan Kitsis - MSFT יום רביעי 26 אוגוסט 2009 07:14
    • סימון כתשובה בוטל על-ידי Stan Kitsis - MSFT יום רביעי 26 אוגוסט 2009 07:16
    יום רביעי 26 אוגוסט 2009 04:13
  • Thanks Stan. It works now.
    יום רביעי 26 אוגוסט 2009 05:07
  • Hi,

    I am also facing this problem.

    Steps to reproduce the error:-
    1. Connect to database using 'New Query'
    2. Exceute the query after connection with the server is connected.
    3. Now try reconnecting to another database using the same query window.

    It will give "Invalid object name 'sys.configurations'. (Microsoft SQL Server, Error: 208) " Error.


    Thanks, Sonia
    • הוצע כתשובה על-ידי Ash0007 יום שלישי 15 פברואר 2011 16:01
    יום רביעי 26 אוגוסט 2009 09:34
  • I've just had this error too.

    I was following the steps in the August training kit to move a SQL database to the cloud.
    I had been connected to my local SQL Server database to generate the script and modify it to fit SQL Azure.
    I disconnected from my local server, then attempted a new connection to the SQL Azure database I previously setup getting the error "Invalid object name 'sys.configurations'. (Microsoft SQL Server, Error: 208) "

    יום רביעי 26 אוגוסט 2009 10:21
  • I also tried to connect to SQL Azure through SSMS 2008 but got error saying
    "Cannot connect to server. Verify that instance name is correct and SQL Server is configured to allow remote connections."
    Pleae help


    Thanks,
    Tejas

    • הוצע כתשובה על-ידי Eric Hawthorne יום רביעי 20 ינואר 2010 02:44
    יום רביעי 26 אוגוסט 2009 11:30
  • Hi,

    You need port 1433 to be opened in your Office Firewall.

    Try out once from connecting any machine in your office outside the company firewall.
    Thanks, Sonia
    • הוצע כתשובה על-ידי tejasjoshi יום חמישי 10 ספטמבר 2009 04:10
    יום חמישי 27 אוגוסט 2009 04:03
  • Hi,
    Port 1433 is already open. I have checked that. Still giving the same error

    "Cannot connect to xxx.ctp.database.windows.net A network related or instance specific error occured while establishing the connection to SQL Server. The server was not found or accessible. Verify that instance name is correct and that SQL Server is configured to allow remote connections(Provider:TCP Provider, error:0-No such host is known)(Microsoft SQL Server, Error:11001)"

    Plese help

    Thanks,
    Tejas

    יום חמישי 27 אוגוסט 2009 07:22
  • Tejas,

    Have you tried using sqlcmd?  If not, can you see if it works for you:

    sqlcmd  -S serverName.ctp.databae.windows.net -U userID@serverName -P password

    Stan


    Program Manager, SQL Azure
    יום חמישי 27 אוגוסט 2009 07:57
  • Also did you tried connecting to it from outside company's network?
    Thanks, Sonia
    יום חמישי 27 אוגוסט 2009 08:33
  • I can connect with sqlcmd, but from SSMS 2005, I get the following error:

    TITLE: Connect to Server
    ------------------------------
    Cannot connect to foobar.ctp.database.windows.net.
    ------------------------------
    ADDITIONAL INFORMATION:
    This version of Microsoft SQL Server Management Studio can only be used to connect to SQL Server 2000 and SQL Server 2005 servers. (ConnectionDlg)

    Do I need SSMS2008?

    m_
    יום חמישי 27 אוגוסט 2009 18:15
  • You need to use SSMS 2008 to connect.
    Thanks, Sonia
    יום שישי 28 אוגוסט 2009 04:17
  • @Stan,
                  Hi Stan I tried it through sqlcmd but it gives me a syntax error at S. Following is the code that i wrote

    1> sqlcmd -S xxx.ctp.database.windows.net -U yyy@xxx  -P zzz -d master
    2> CREATE TABLE MyAzureTale(id int NOT NULL, description varchar(50) NULL)
    3> GO
    Msg 102, Level 15, State 1, Server WIN-OLYD3Y278J4, Line 1
    Incorrect syntax near 'S'.


    @Sonia, 
                 I havent tried to use from any other computer outside my company network as I do not have SSMS else where..

    יום שישי 28 אוגוסט 2009 05:01
  • Ok tejas, looks like you are connected.  You are getting an error because you can't create any objects in master database.  You need to create a database first.  Once you connect to master, issue CREATE DATABASE <dbname> statement.  After the database is created, reconnect to that database using
    sqlcmd -S tcp:xxx.ctp.database.windows.net -U yyy@xxx  -P zzz -d <dbname>

    Once connected to your new database, you should be able to create tables.

    Stan

    Program Manager, SQL Azure
    יום שישי 28 אוגוסט 2009 06:19
  • Hi Stan,
                    I did as per you suggested but still got the same error.

    1> CREATE DATABASE TestDatabase
    2> GO
    1> sqlcmd -S xxx.ctp.database.windows.net -U yyy@xxx -P zzz -d TestDatabase
    2> CREATE TABLE MyAzureTable(id int NOT NULL, description varchar(50) NULL)
    3> GO
    Msg 102, Level 15, State 1, Server WIN-OLYD3Y278J4, Line 1
    Incorrect syntax near 'S'.

                 Also let me tell you that I do have another database already on my SQL Azure that I had created using the portal. But when I tried to use that I still got the same error.
    יום שישי 28 אוגוסט 2009 07:18
  • Hi,
    I didn't have this problem again.
    Thanks
    שבת 29 אוגוסט 2009 16:51
  • Hi Stan,
               Also note this error when I tried to go through my command prompt

    C:\Users\Administrator>sqlcmd -S tcp:xxx.ctp.database.windows.net -U yyy@xxx -P zzz -d master
    HResult 0x274C, Level 16, State 1
    TCP Provider: A connection attempt failed because the connected party did not pr
    operly respond after a period of time, or established connection failed because
    connected host has failed to respond.

    Sqlcmd: Error: Microsoft SQL Native Client : An error has occurred while establi
    shing a connection to the server. When connecting to SQL Server 2005, this failu
    re may be caused by the fact that under the default settings SQL Server does not
     allow remote connections..
    Sqlcmd: Error: Microsoft SQL Native Client : Login timeout expired.

    יום שני 31 אוגוסט 2009 06:11
  • The error "Invalid object name 'sys.configurations'" persist, using SSMS 2008, no @, no firewall. It worked once and the error just keeps coming. I tried to go to options connect to the database and then "browse server" I got a new error: "Invalid object name 'sys.server_principals'"

    Here what happens, when I cancel out the first dialog and re-open with a "new query" it works with an error message: "ANSI_NULLS is not a recognized set option", after canceling out the error message I cannot see the server name or database name in the object explorer window. The query window seems is working and I am able to query the server objects.


    Any idea?

    יום שישי 04 ספטמבר 2009 18:27
  • Bob129 -

    I believe the Object Explorer stuff is currently not available in SSMS pointing to SQL Azure. You have to use the query window - although the connection will time out if you leave it for more than a few minutes and you will need to reconnect.

    יום שישי 04 ספטמבר 2009 18:30
    מנחה דיון
  • Here what happens, when I cancel out the first dialog and re-open with a "new query" it works with an error message: "ANSI_NULLS is not a recognized set option", after canceling out the error message I cannot see the server name or database name in the object explorer window. The query window seems is working and I am able to query the server objects.


    Any idea?


    Bob,

    This is the current behavior. You have to cancel out of the first connection dialog and use the New Query option to connect.  Click Ok on the ANSI_NULLS message and you should be able to run the queries. The object browser isn't working. We are fixing all of these issues, but for now this is how it is.

    Stan
    Program Manager, SQL Azure
    יום שישי 04 ספטמבר 2009 18:33
  • Hi Stan,
               The problem has been resolved. It was due to company network ( as suggested by Sonia).

    Now I have one more requirement. I dont know whether this is the right forum to ask but would still put up the question.

    I have requirement in which I want to create a multi tenant applicaton

    My requirement is to have URL's like the following

    Base URL: http://www.abc.com

    Whenever a tenant comes and registers at this place he should have his own subdomain whose URL should be like

    Tenant url:http://www.xyz.abc.com

    The traditional way to do this would as I know would be to use the following method

    Registering *.abc.com in my dns server and thus any request having xxx.abc.com would be redirected to my server and then I can take handle of the URL through HttpHandler and do the work we want.(Instead of HttpHandler we can even write the rules at IIS level, which is though not desired)

    Now do we have a provision to do this in Windows Azure ? Does Azure provide with a framework to help this ? And if it is possible how do I register my domain to accept any invitation preceding with anything - like *.abc.cloudapp.net to redirect to my abc.cloudapp.net application hosted on azure.

    Thanks ,
    Tejas

    יום חמישי 10 ספטמבר 2009 04:09
  • Hi Tejas,

    Could you tell how the problem is resolved?

    Also could for the Question that you have asked, please ask that in Window Azure forum.
    Thanks, Sonia
    יום חמישי 10 ספטמבר 2009 04:22
  • Hi Sonia,
                Thanks a lot for the answer. It was due to the company network only that my connection request was not able to go through fire wall and thus was not even able to access the port 1433 which I had opened. Then the company network guys gave me a direct connection to .net and there it was. Was easily abel to connect to SQL Azure. :)
    יום חמישי 10 ספטמבר 2009 06:50
  • Hi Tejas,

    Nice to hear that!

    You can move to Azure Forum to get your answer to next Question you have asked :)


    Thanks, Sonia
    יום חמישי 10 ספטמבר 2009 06:52
  • Hi,
               I had established connection with SQL Azure and it was all working perfect till now. But today I got error saying      "a connection was established with the server but then an error occurred during the login process. The specified network name is no longer available".
    any ideas?

    Thanks,
    Tejas

    יום שישי 11 ספטמבר 2009 10:20
  • Hi,
         I did not get that error again..Solved !!!

    But there is one more problem. I want to create a table in master database of SQL Azure but it says that access denied to create table in master. Is there a way that we can create a table in master database ?

    If not, is there a way that we can create a stored procedure (please note that the requirement is different here... it is to create a stored procedure in master database.. but again access denied) ?

    יום שני 14 ספטמבר 2009 03:09
  • Hi,

    can i check, are we able to connect to SQL Azure using Visual Studio?
    I've been trying the whole morning to set up a connection to SQl Azure using Visual Studio
    but everytime i get error like "Object reference not set to an instance of an object."

    are we able to connection to SQL Azure using Visual Studio?
    יום שני 14 ספטמבר 2009 07:20
  • Tejas,

    Good to see that your problem was solved.  As for master database, you cannot create any objects in master database - that includes tables and stored procedures.

    Stan
    Program Manager, SQL Azure
    יום שני 14 ספטמבר 2009 18:14
  • RedTinCan:

    Visual Studio tools are currently unable to connect to SQL Azure.  You can use SSMS instead.

    Stan
    Program Manager, SQL Azure
    יום שני 14 ספטמבר 2009 18:15
  • Tejas,

    Have you tried using sqlcmd?  If not, can you see if it works for you:

    sqlcmd  -S serverName.ctp.databae.windows.net -U userID@serverName -P password

    Stan


    Program Manager, SQL Azure

    I run the cmd ,but recevied the error like below:

    HResult 0x2746, Level 16, State 1
    TCP Provider: An existing connection was forcibly closed by the remote host.
    Sqlcmd: Error: Microsoft SQL Server Native Client 10.0 : Communication link failure
    יום שלישי 15 ספטמבר 2009 09:18
  • I think that people are having issues because in the server name you need to include "tcp:"

    1. cancel out of the first connection dialog that pops up.
    2. click on the New Query button from the toolbar (upper left)
    3. entered
           Server name: tcp:"full servername"
           Login: just the username (no @...)
    4. Under Options, Connect to Database, I typed TestDb1
    5. Hit connect.

    This worked for me on the first try.

    Frank
    • הוצע כתשובה על-ידי Frank Galarraga יום רביעי 16 ספטמבר 2009 03:01
    יום רביעי 16 ספטמבר 2009 02:55
  • Another thing that may be misleading:

    When I was first walking through the "Connecting to SQL Azure" document from the training kit, I saw that the screenshot had a whited-out area and then ".database.windows.net".  I concatenated my server name (from the SQL Azure portal) with ".database.windows.net", and this doesn't work.  You need to concatenate your server name with ".ctp.database.windows.net", at least while SQL Azure is still in CTP.  :)  Plug this in where Stan specifies "full servername" above in this thread. 
    • הוצע כתשובה על-ידי jennmar יום רביעי 16 ספטמבר 2009 04:49
    יום רביעי 16 ספטמבר 2009 04:47
  • Thanks Frank and jennmar

    I finally let it works for me.
       the arguments for sqlcmd should be like below:
    sqlcmd  -S tcp:serverName.ctp.databae.windows.net -U userID@serverName -P password
    and the -S,-U,-P could not be lower case letters.

    • הוצע כתשובה על-ידי Geting יום שישי 18 ספטמבר 2009 15:22
    יום רביעי 16 ספטמבר 2009 07:40
  • Hi Tejas

    I m glad that you are are done with your problem but i m still facing the same problem and couldnt resolve it yet. I am even trying it from my home PC but its giving the same error i.e. 'Cannot connect to xxx.ctp.database.windows.net A network related or instance specific ......... '. I have also used sqlcmd but again its giving the same error again n again. I have done everything related to Firewall. Can you please suggest some idea?

    thanks

    Achint
    יום שני 21 ספטמבר 2009 11:57
  • Hi Achint
                   First of all sorry for such a late reply. Now there are quite a few things that you need to do:
    1. If you are trying to connect from your company's network first and foremost thing to do would be to get a static ip for the machine from where you are trying to connect to SQL Azure.
    2. Also go to cliconfg.exe and see whether the port no TCP/IP is enabled and in its properties the port no is 1433.
    Hope that this helps. :-)
    יום שלישי 29 ספטמבר 2009 11:27
  • Hi Tejas,

    I dont thin that should be the solution to go with. By having a static ip on your machine just for the sake of it you are bypassing your organizations security policies.

    I hope someone can let us know how to connect to SQL Azure from a machine which is behind company's firewall.

    We tried all of the solutions mentioned above but it still does not work (Both from SSMS 2005 and SSMS 2008).

    Someone mentioned that its not possible to connnect it from SSMS 2005 but did not find it documented anywhere by microsoft.

    Thanks
    Badal
    bkk
    יום רביעי 11 נובמבר 2009 08:09
  • Hi Stan,

    I have SQL 2008 SSMS (RTM) installed on Win7
    Trying to connect to SQL Azure database using SQL CMD:

    sqlcmd  -S tcp:xxx.ctp.database.windows.net -U zzz@xxx -P ppp

    However connection fails with below error:

    ++++++++++++++++++++
    Sqlcmd: Error: Microsoft SQL Server Native Client 10.0 : A network-related or instance-specific error has occurred while establishing a connection to SQL Server.
    Server is not found or not accessible. Check if instance name is correct and if SQL Server is configured to allow remote connections.
    For more information see
    SQL Server Books Online..
    Sqlcmd: Error: Microsoft SQL Server Native Client 10.0 : Login timeout expired.
    ++++++++++++++++++++

    Pls help !

    יום שלישי 05 ינואר 2010 06:47