Getting errror -->Invalid catalog name 'Search'. SQLSTATE=42000

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • manojuniverse
    New Member
    • Aug 2007
    • 13

    Getting errror -->Invalid catalog name 'Search'. SQLSTATE=42000

    Hi ,

    I have indexed folder on my remote computer. I am trying to access catalog of that indexed folder using asp.net as follow.

    string name = "MYserver".gun. .Scope()";
    string connstring = "Provider=MSIDX S.1;";
    string querystring = "Select PATH from "+name+" where FREETEXT('M05M3 ')";

    System.Data.Ole Db.OleDbConnect ion conn = new System.Data.Ole Db.OleDbConnect ion(connstring) ;
    conn.Open();
    System.Data.Ole Db.OleDbCommand cmd = new System.Data.Ole Db.OleDbCommand (querystring, conn);
    System.Data.Ole Db.OleDbDataRea der dr = cmd.ExecuteRead er();
    _gridview.DataS ource = dr;
    _gridview.DataB ind();
    conn.Close();


    When I exectue this code I get "Invalid catalog name 'gun'. SQLSTATE=42000 " error.. While If instead of "Myserver" name I give my local computer name and catalog , it is running fine.


    If anybody could help me Why I am getting this error for remote computer.. I searched on net but nobody has given solution of this..

    A lot of thanks in advance

    Thanks and Regards

    Manoj
  • kenobewan
    Recognized Expert Specialist
    • Dec 2006
    • 4871

    #2
    Is gun the name of your db? Look like you need a better connection string. HTH.

    Comment

    • manojuniverse
      New Member
      • Aug 2007
      • 13

      #3
      Originally posted by kenobewan
      Is gun the name of your db? Look like you need a better connection string. HTH.
      Hi,

      Thanks for reply..

      Gun is name of my catalog that I have created on my remote server..
      As far as connection string is concerned..Acco rding to "http://msdn2.microsoft .com/en-us/library/ms810655.aspx" for MSIDXS provider we donot need any thing extra to give to connection string..


      So If you could suggest me something else or If I am wrong , let me know..I am really struck in this and not finding any solution.

      Comment

      Working...