Professional Web Applications Themes

Server Name. Database Name - Microsoft SQL / MS SQL Server

What exactly is the syntax you are using? What does "fails" mean... do you get an error message, and what is the error message? Is servername a registered/linked server? Do you have adequate permissions to tablename in databasename? Did you try using the "dbo" prefix on tablename? "Venugopal Vemuri" <com> wrote in message news:025801c365a9$edad6cb0$gbl... ...

  1. #1

    Default Re: Server Name. Database Name

    What exactly is the syntax you are using? What does "fails" mean... do you
    get an error message, and what is the error message? Is servername a
    registered/linked server? Do you have adequate permissions to tablename in
    databasename? Did you try using the "dbo" prefix on tablename?



    "Venugopal Vemuri" <com> wrote in message
    news:025801c365a9$edad6cb0$gbl... 


    Aaron Guest

  2. #2

    Default Server Name. Database Name

    It is ServerName.Databasename.DbOwner.Tablename. Incase if
    you want to assign default database owner name you can get
    by using .. opertor after databasename.

    select * from ServerName.Databasename.DbOwner.Tablename is
    correct syntax.

    Also, if you are trying to link the query to other server
    make sure that you have registered it as linked server.

    Sammy
     
    Sammy Guest

  3. #3

    Default Re: Server Name. Database Name

    Hi,
    The syantax i am using is
    select * from 01Server.dbtest..tbltest
    I have tried the statement with and without dbo but it
    gives ne an error message Line 1: Incorrect syntax
    near '01'. 01Server shows up as a registered server on
    the enterprise manager on my machine. An early reply
    would be appreciated.
    Regards,
    Venugopal
     
    does "fails" mean... do you 
    servername a 
    permissions to tablename in 
    tablename? [/ref]
    early 
    >
    >
    >.
    >[/ref]
    Venugopal Guest

  4. #4

    Default Re: Server Name. Database Name

    In addition to the others comments, for the 4-part name to work the DBA must
    have set up a linked server for you...(Takes only a minute)
    "Venugopal Vemuri" <com> wrote in message
    news:025801c365a9$edad6cb0$gbl... 


    Wayne Guest

  5. #5

    Default Re: Server Name. Database Name

    Venugopal:

    Since your server name begins with a numeric character,
    you must enclose in brackets. Try:

    select * from [01Server].dbtest..tbltest

    HTH
    Vern
     
    >does "fails" mean... do you 
    >servername a 
    >permissions to tablename in 
    >tablename? [/ref][/ref]
    the [/ref]
    >early 
    >>
    >>
    >>.
    >>[/ref]
    >.
    >[/ref]
    Vern Guest

  6. #6

    Default Re: Server Name. Database Name

    Venogopal,

    I believe this has been an annoying little problem with MS Sql Server for a
    while now. "dbo" is not implied as the owner in any cross server queries.
    You have to explicitly define it.

    select * from servername.databasename.dbo.tablename

    Hope this helps,

    Bill

    "Venugopal Vemuri" <com> wrote in message
    news:025801c365a9$edad6cb0$gbl... 


    Alter Guest

Similar Threads

  1. Max. no of database in a server?
    By howa in forum MySQL
    Replies: 15
    Last Post: January 5th, 03:43 AM
  2. Read Point of Sale database and update server database
    By turtle in forum Macromedia ColdFusion
    Replies: 4
    Last Post: July 20th, 09:41 PM
  3. When the database server is down...
    By frankjshin in forum Coldfusion - Advanced Techniques
    Replies: 5
    Last Post: July 11th, 05:53 PM
  4. Replies: 3
    Last Post: July 13th, 02:58 AM

Bookmarks

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139