SQL invalid object name

Ask a Question related to Coldfusion Database Access, Design and Development.

  1. #1

    Default SQL invalid object name

    I used SQL administrator to copy a database. Registered it successfully with
    XP, and CF Administrator. I can run query analyzer with the new database.
    When I change the DSN name in a .cfm it reognizes the DSN but all tables get
    a "invalid object name" error.
    All the permissions for the Database and Tables seem to be the same.
    I can not find any other permissions to check. I had the same problem a long
    time ago, but can't remember the fix.
    Help

    jci714 Guest

  2. Similar Questions and Discussions

    1. Invalid object name
      So, this keeps popping up. I'm running scripts to create databases and ODBC connections and this error pops up quite frequently. It's not good. ...
    2. Invalid Object Name??
      BTW, I'm using CFMX7 on Win2003Server
    3. Invalid Object Name??
      I am having sort of the same problem. The query works fine until I go into Enterprise Manager and edit some content in the table the query is using....
    4. Database Invalid Object Name
      Ok so I am upgrading from a coldfusion 4.5 site and I set everything up, however, I am getting the following error whenever I try to connect to a...
    5. Invalid object name 'TABLE'
      Can someone please tell me why I keep getting the following error? I think it is part of the connection but can't pin down the exact error. I would...
  3. #2

    Default Re: SQL invalid object name

    Sounds like you're using sql server.

    - What kind of connection are you using: JDBC / ODBC?
    - If you run the run the following in a cfquery and dump the results, what is
    the database name?
    SELECT DB_NAME() AS CurrentDatabaseName

    mxstu Guest

  4. #3

    Default Re: SQL invalid object name

    ODBC
    jci714 Guest

  5. #4

    Default Re: SQL invalid object name

    Maybe you haven't set the default database in the DSN, so you're in the
    "master" database. If you run the run the following in a cfquery and dump the
    results, what is the database name shown?

    SELECT DB_NAME() AS CurrentDatabaseName

    Btw - Why ODBC and not JDBC?

    mxstu Guest

  6. #5

    Default Re: SQL invalid object name

    SELECT DB_NAME() AS CurrentDatabaseName
    Returns Master
    jci714 Guest

  7. #6

    Default Re: SQL invalid object name

    That's you're problem. Just open up the DSN and set the "default" to the correct database name (ie. not "master")
    mxstu Guest

  8. #7

    Default Re: SQL invalid object name

    I changed the default to the databasename, and it still shows master. I will shut everythi9ng down and see if it takes effect when I restart. I think that is the step I was forgetting. Thanks
    jci714 Guest

  9. #8

    Default Re: SQL invalid object name

    That took care of it. I have made note of it until next time.
    Are there any advantages to using JDBC ?
    Thanks.
    jci714 Guest

  10. #9

    Default Re: SQL invalid object name

    That was the problem.
    Thanks for the quick replies.
    What is the advantage to using JDBC?
    jci714 Guest

  11. #10

    Default Re: SQL invalid object name

    using jdbc directly takes out the lag of the jdbc to odbc conversion.

    I use MSSQL2000 wih jdbc without problem.
    Scott*e Guest

Posting Permissions

  • You may not post new threads
  • You may 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