Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to pull records of the database which is in sqlserver

Status
Not open for further replies.

VenkatRastapuram

Programmer
Oct 24, 2003
46
IN
Hello Sir,

I want to pull some records of the tables, for which the database is in sqlserver. I successfully copied Sql server Tools in the IIS. I am able to get the message 'Sql Server Agent' which confirms that the sql server tools are successfully installed.

But when I am trying to pull the records it is giving two errors. First one is "An Internal Error", and the second Error is "Login Failed for DEV02\IUSR_MAKELOGI-6CT9HB".

I am sending my code.

SqlCeRemoteDataAccess rda;
rda = new SqlCeRemoteDataAccess();
try
{


sCon = "Provider=SQLOLEDB;" +
"data source=" + serverName +
";initial catalog=" + dbName +
";User ID=" +
";pwd=" +
";persist security info=False;Integrated Security=SSPI;" +
"packet size=4096";
rda.InternetUrl = ssceURL;
rda.LocalConnectionString = "Data Source=" + frmSplash.AppPath + @"\UH_DriverLog.sdf";

rda.Pull("tUser", "SELECT * FROM tUser", sCon, RdaTrackOption.TrackingOn, "rdaUserErrors");

rda.Dispose();

}
catch (SqlCeException ex)
{
for (int i = 0; i <= ex.Errors.Count - 1; i++)
{
MessageBox.Show("Index #" + i.ToString() + " Error: " + ex.Errors.ToString(), "Database Access");
}
}

Please solve this problem.

Regards,
R.venkatesh

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top