By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
449,153 Members | 1,031 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 449,153 IT Pros & Developers. It's quick & easy.

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

P: 13
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=MSIDXS.1;";
string querystring = "Select PATH from "+name+" where FREETEXT('M05M3')";

System.Data.OleDb.OleDbConnection conn = new System.Data.OleDb.OleDbConnection(connstring);
conn.Open();
System.Data.OleDb.OleDbCommand cmd = new System.Data.OleDb.OleDbCommand(querystring, conn);
System.Data.OleDb.OleDbDataReader dr = cmd.ExecuteReader();
_gridview.DataSource = dr;
_gridview.DataBind();
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
Feb 14 '08 #1
Share this Question
Share on Google+
2 Replies


kenobewan
Expert 2.5K+
P: 4,871
Is gun the name of your db? Look like you need a better connection string. HTH.
Feb 14 '08 #2

P: 13
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..According 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.
Feb 14 '08 #3

Post your reply

Sign in to post your reply or Sign up for a free account.