Showing posts with label connecting. Show all posts
Showing posts with label connecting. Show all posts

Wednesday, March 21, 2012

Problems with new MSDE installation

Hi,
I've a problem with connecting to my local MSDE installation. I'm using Windows XP Pro SP1 and logged in as administrator.

I've installed MSDE without further options (=setup SAPWD="password"). After that I installed some examples from Microsofts '101 Visual Basic.NET applications' using 'setup SAPWD="password" INSTANCENAME="NetSDK"'. Now I have 2 services running, 'MSSQLServer' and 'MSSQL$NetSDK'.

Then I followed the examples from a german book and created a Dataset etc. to access data from the Northwind database. The following line is created as SQLConnection1:

Me.SqlConnection1.ConnectionString = "workstation id=""COMPUTERNAME"";packet size=4096;integrated security=SSPI;data source=" & _
"""(local)\NetSDK"";persist security info=False;initial catalog=Northwind"
CType(Me.DataSet11, System.ComponentModel.ISupportInitialize).EndInit( )

When I right-click on the SQLDataAdapter1 and select 'Preview Data' everything works fine and I could see 9 Employee records. But when I then start the application it could not connect to the server. The error appears already in the first line, a simple connection call:
Me.SqlConnection1.Open()

Please could someone help me solve this issue? I already read several postings, here, on other sides, and on MSDN. I found information about a user account 'APSNET' which I am not allowed to implement due to security reasons. I also found the information about named pipes and TCP/IP, and so I added 'Network Library =dbmssocn' to the end of the SQLConnection-string, but with no success :-(

Many Thanks in advance for your support!Maybe try this type of connectionstring :

driver={SQL Server};server=ServerName;uid=sa;pwd=password;data base=Northwind

Friday, March 9, 2012

Problems with disconnected recordsets i Yukon

We have a VB6 application using ADO 2.8 connecting to SQL Server.

We use disconnected recordset to load data to client-side. The client does updates in the recordset and then sends it back to server-side component that converts the recordset into SQL to update the database. No problems in SQL 2000 but on Yukon we get error when trying to update the disconnected recordset on the client.

Error: -2147217887 Multiple-step operation generated errors. Check each status value.

Error only occurs on recordsets which obviously won't work it was a connected recordset; for example a UNION sql.

Is this the way Yukon is supposed to work? Is there anyway to disable this new functionality to really get a disconnected recordset?

One thing that would work is to create a recordset from scratch based on the loaded recordset and copy all data into this new recordset. But it seems like a lot of work doing this each time.

I suspect that Yukon is more accurately reporting that certain columns are not updatable and ADO is marking the disconnected recordset fields as read only. I'll see if there is a way to disable this. One thing you could do to see if this is the case is save the ADO recordset to XML and compare XML from SQL 2000 and Yukon to see what is different.|||

I have a similar problem, did you find any solution to this? I've tried all ADO recordset properties, but I can't find anything.

I saved ADO recordset to XML from SQL 2000 and SQL 2005. There was one difference that is propably the cause. XML from SQL 2005 was missing rs:writeunknown property from attributes. I just don't want to create a recordset first and copy data from original recordset or save the recordset to xml and modify it.

|||Unfortunately I never found any better solution than the one I described.

Problems with disconnected recordsets i Yukon

We have a VB6 application using ADO 2.8 connecting to SQL Server.

We use disconnected recordset to load data to client-side. The client does updates in the recordset and then sends it back to server-side component that converts the recordset into SQL to update the database. No problems in SQL 2000 but on Yukon we get error when trying to update the disconnected recordset on the client.

Error: -2147217887 Multiple-step operation generated errors. Check each status value.

Error only occurs on recordsets which obviously won't work it was a connected recordset; for example a UNION sql.

Is this the way Yukon is supposed to work? Is there anyway to disable this new functionality to really get a disconnected recordset?

One thing that would work is to create a recordset from scratch based on the loaded recordset and copy all data into this new recordset. But it seems like a lot of work doing this each time.

I suspect that Yukon is more accurately reporting that certain columns are not updatable and ADO is marking the disconnected recordset fields as read only. I'll see if there is a way to disable this. One thing you could do to see if this is the case is save the ADO recordset to XML and compare XML from SQL 2000 and Yukon to see what is different.|||

I have a similar problem, did you find any solution to this? I've tried all ADO recordset properties, but I can't find anything.

I saved ADO recordset to XML from SQL 2000 and SQL 2005. There was one difference that is propably the cause. XML from SQL 2005 was missing rs:writeunknown property from attributes. I just don't want to create a recordset first and copy data from original recordset or save the recordset to xml and modify it.

|||Unfortunately I never found any better solution than the one I described.

Problems with disconnected recordsets i Yukon

We have a VB6 application using ADO 2.8 connecting to SQL Server.

We use disconnected recordset to load data to client-side. The client does updates in the recordset and then sends it back to server-side component that converts the recordset into SQL to update the database. No problems in SQL 2000 but on Yukon we get error when trying to update the disconnected recordset on the client.

Error: -2147217887 Multiple-step operation generated errors. Check each status value.

Error only occurs on recordsets which obviously won't work it was a connected recordset; for example a UNION sql.

Is this the way Yukon is supposed to work? Is there anyway to disable this new functionality to really get a disconnected recordset?

One thing that would work is to create a recordset from scratch based on the loaded recordset and copy all data into this new recordset. But it seems like a lot of work doing this each time.

I suspect that Yukon is more accurately reporting that certain columns are not updatable and ADO is marking the disconnected recordset fields as read only. I'll see if there is a way to disable this. One thing you could do to see if this is the case is save the ADO recordset to XML and compare XML from SQL 2000 and Yukon to see what is different.|||

I have a similar problem, did you find any solution to this? I've tried all ADO recordset properties, but I can't find anything.

I saved ADO recordset to XML from SQL 2000 and SQL 2005. There was one difference that is propably the cause. XML from SQL 2005 was missing rs:writeunknown property from attributes. I just don't want to create a recordset first and copy data from original recordset or save the recordset to xml and modify it.

|||Unfortunately I never found any better solution than the one I described.

Wednesday, March 7, 2012

Problems with connecting to sql server table

Hello, I have SQL server installed on my stand alone PC. In summary the problem I am having is connecting to the data base through my web form, when the web application runs. In more detail, here is the problem:

I am using the data form wizard to display Data from a NorthWind data table in SQL server. I create a data set name dsCustomers, and then through the wizard specify (local) as the server name. I also select that I would like to use Windows NT integrated security to log on to the server.

I then continuue through the server and the Wizard indicates that I can connect to the NorthWind Data Base. I am able to view the data table to choose "Customers". I continue with the remaining information in the wizard and finish the process. Now when I run the program/(HTML web form) my web page comes up with a button I have labeled "load". When I press this button I want my data to be displayed in my web form.

The problem is that when I press the "load" button, I get an error page saying the following:

login failed for user 'BVCOMPUTER\ASPNET'

I traced into the code and the failure occurs when the internal code is called: this.oleDbConnection1.open()

Note that basically I am trying to run the sample code in Kalanis book for MCP 70-315. This is on page 358 of his book for the program StepByStep5_11.aspx.

I would appreciate someones help as I am stuck on this problem.

Sincerely,

William

You need to add the BVCOMPUTER\ASPNET Windows user to SQL Server as a user with rights to the database involved, or use SQL Server security and pass in a username and password.|||

Hello thanks, but please I still need help!! So you say I need to add the BVCOMPUTER\ASPNET Windows user to SQL server as a user with rights to the database involved.How do I do this??

Just fyi, it might not matter but just to let you know, currently when I do queries in Query Analyzer, the Query Dialog box list the following string:

BVCOMPUTER.master.BVCOMPUTER\smokey

|||

If you have Enterprise Manager, expand out the Security folder for the correct server, click on Logins, and then right click, and select New Login from the context menu.

Click on hte button next to theName textbox and pick the ASPNET user from the current machine (presuming the Web server and Database server are the same machine).

Problems with connecting to Sql Server 2005 from Java application, HELP!

Hello, Everybody.

Help me please with one problem which I'm facing with while deploying java server application on my computer (this java app is jBilling). I have configured it as it was said in docs, I have added environment variable CLASPATH as Microsoft documentation said. I'm using SQL Server JDBC driver 1.2 by Microsoft. The result is that I find this message in log file:

2007-05-27 17:21:41,906 WARN [org.jboss.resource.connectionmanager.JBossManagedConnectionPool] Throwable while attempting to get a new connection: null
org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable: (org.jboss.resource.JBossResourceException: Failed to register driver for: com.microsoft.jdbc.sqlserver.SQLServerDriver; - nested throwable: (java.lang.ClassNotFoundException: No ClassLoaders found for: com.microsoft.jdbc.sqlserver.SQLServerDriver))
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.createManagedConnection(LocalManagedConnectionFactory.java:168)
... and so on.

I have copied sqljdbc.jar to lib folder of the server. That's how I specified connection string:

jdbc:microsoftTongue Tiedqlserver://localhost:1434;DatabaseName=Billing;integratedSecurity=false;

Can not think out what to do else. Maybe somebody knows what to do about it?

Many thanks

Looking at your connection string URL:

jdbc:microsoftqlserver://localhost:1434;DatabaseName=Billing;integratedSecurity=false;

You are ending up trying to load the SQL Server 2000 JDBC driver.

The SQL Server 2005 JDBC v1.x driver uses the following connection string URL:

jdbcTongue Tiedqlserver://

So if you would like to use the 2005 JDBC driver (highly recommended over the 2000 JDBC driver), your resulting connection string URL will look like:

jdbcTongue Tiedqlserver://localhost:1434;DatabaseName=Billing;integratedSecurity=false;

Note: I assume you specified the SQL user name and password somewhere else and that the SQL Server instance is running on the same machine as the JBoss application.

Also, are you trying to connect to the DAC port? 1434 is typically reserved for the DAC port. I would recommend connecting to the normal TCP port of 1433 (if default TCP port settings are used).

HTH,

Jimmy

Problems with connecting to SQL Server 2005 Express

Here's my code so far:

[source]using System;
using System.Collections.Generic;
using System.Text;
using System.Data.SqlClient;

namespace Database
{
class Database_Main
{
SqlConnectionString ConnStr = new SqlConnectionString();

public Database_Main()
{

SqlConnection Connection = new SqlConnection(@."user id=Afr0;password=prins;server=(local);Trusted_Connection=yes;database=Nimdalin;");
Connection.Open();
}
}
}
[/source]

The message I get says that:

"An error has occured while establishing a connection to the server."

What could be the possible reasons for this? Is there any way to configure my server to accept remote connections amongst other things? All the times I've seen people mentioning this they say that you can turn this on in the SQL Server Configuration Manager, but I can't find out where in the program that option is! Also, how do I check which users are available to my database? I've added a user + pass by using SQL code, but I'd like to make sure that it's there just in case.

I usually find out how to write the query string from http://www.connectionstrings.com/

Your connectionstring has some contradictive parts in it. If you want to use a user/password you should probably use this instead

"Server=localhost;Database=Nimdalin;User ID=Afr0;Password=prins;Trusted_Connection=False"

To enable remote connection you can use the surface area configuration tool

I can start it from the Start menu: Start->All Programs->Microsoft SQL Server 2005->Configuration Tools->SQL Server Surface Area Configuration

There you have options to enable remote connection among others.

|||

Hi Afr0,

SQL Server Express comes with all the remote protocols disabled by default. In addition to the SAC, you can also use the SQL Server Configuration Manager (Start -> All Programs -> Microsoft SQL Server 2005 -> Configuration Tools -> SQL Server Configuration Manager). Just expand SQL Server 2005 Network Configuration and select the SQL Express instance and you'll see the list of supported protocols. Also, make sure that your SQL Browser is enabled and your firewall isn't blocking the connections. (See the following KB articles about enabling a firewall, http://support.microsoft.com/kb/287932/en-us, http://support.microsoft.com/kb/841249/en-us).

In addtion, Ming posted a great help guide in the SQL Protocols blog:
http://blogs.msdn.com/sql_protocols/archive/2006/03/23/558651.aspx

Let me know how it goes.

Il-Sung.

Problems with connecting to SQL database on network

Hello.

I have read many posts and documentation on the subject but have not been able to find the answer.So I am posting here in hope that someone could give me good answer.

We are developing an ording system in my company and with weborderingsystem and an backoffice system. We use windows2k3 where sqlserver 2005 is installed and running with our database. Our webapplication is working with this database and is connected to it. This works fine. I am developing backofficepart whick is an C# application and point of this app is that user can check out sent orders, look up orders and customers.

i use C# express to develop this, and use database explorer to try to connect to my the database.

My machine is running WinXp pro and server is win2k3 with SQL Server 2005 on it.

I get this error:

"The file \\810....... is on a network path that is not supported for databasefiles....

the path is this:

\\810-sql2k5\allkopiprivat.test\AllkopiPrivatTest.mdf

Can anyone give me an answer to tell me if this is possible at all or give me an suggestion on how to go about hsi problem. I need my application to connect to another machine on the network that is running SQL server.

PLEASE help.

You should use a connection string to connect to your database from your C# application...not a UNC path. Remember that you are trying to access a database server, not a shared file.|||

Hi.

I changed my connectionstring in my app.config file to access the server but that did not help alot.

do you maybe have a link to some literature or could explain me what to do

|||

This post anwsers your question:
http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=324783&SiteID=1

Problems with connecting an Oracle DB

Hi,
I linked a SQL Server 2005 to an Oracle DB 7.3
I can run a query like
select * from SERVERNAME..TABLENAME
and I receive the data
But if I run
select * from SERVERNAME..SCHEMANAME.TABLENAME
I receive the following message:
Msg 7399, Level 16, State 1, Line 1
The OLE DB provider "MSDAORA" for linked server "SERVERNAME" reported an
error. The provider did not give any information about the error.
Msg 7303, Level 16, State 1, Line 1
Cannot initialize the data source object of OLE DB provider "MSDAORA" for
linked server "SERVERNAME".
And I receive the same message after running
select * from SERVERNAME..VIEWNAME
or
sp_tables_ex @.table_server=SERVERNAME
(I don't understand why the first statement works)
I don't have such problems on a local SQL Server 2000
Any idea?
Thanks
Hello, try
exec sp_addlinkedserver 'linkedorcl', 'Oracle', 'MSDAORA', 'linkedorcl'
go
exec sp_addlinkedsrvlogin 'linkedorcl', false, 'sqluser', 'oracleuser',
'oracleuserpassword'
go
dbcc traceon(7399)
go
SELECT * FROM OPENQUERY(linkedorcl, 'SELECT * FROM oracleuser.SALES')
breno tozo
"Michael" wrote:

> Hi,
> I linked a SQL Server 2005 to an Oracle DB 7.3
> I can run a query like
> select * from SERVERNAME..TABLENAME
> and I receive the data
> But if I run
> select * from SERVERNAME..SCHEMANAME.TABLENAME
> I receive the following message:
> Msg 7399, Level 16, State 1, Line 1
> The OLE DB provider "MSDAORA" for linked server "SERVERNAME" reported an
> error. The provider did not give any information about the error.
> Msg 7303, Level 16, State 1, Line 1
> Cannot initialize the data source object of OLE DB provider "MSDAORA" for
> linked server "SERVERNAME".
> And I receive the same message after running
> select * from SERVERNAME..VIEWNAME
> or
> sp_tables_ex @.table_server=SERVERNAME
> (I don't understand why the first statement works)
> I don't have such problems on a local SQL Server 2000
> Any idea?
> Thanks
>
>
>
>
|||Unfortunately it doesn't works.
I still receive this error message:
Msg 7303, Level 16, State 1, Line 1
Cannot initialize the data source object of OLE DB provider "MSDAORA" for
linked server "linkedorcl".
Any new idea?
Michael
"Breno" wrote:
[vbcol=seagreen]
> Hello, try
> exec sp_addlinkedserver 'linkedorcl', 'Oracle', 'MSDAORA', 'linkedorcl'
> go
> exec sp_addlinkedsrvlogin 'linkedorcl', false, 'sqluser', 'oracleuser',
> 'oracleuserpassword'
> go
> dbcc traceon(7399)
> go
> SELECT * FROM OPENQUERY(linkedorcl, 'SELECT * FROM oracleuser.SALES')
> breno tozo
> "Michael" wrote:
|||There is a good chance that communications with an Oracle 7.3 is no longer
supported. Oracle is at relase 10g2. Even Oracle doesn't talk to a release
that old.
You at least have to be very careful with which MDAC you are using.
Joseph R.P. Maloney, CSP,CCP,CDP
"Michael" wrote:
[vbcol=seagreen]
> Unfortunately it doesn't works.
> I still receive this error message:
> Msg 7303, Level 16, State 1, Line 1
> Cannot initialize the data source object of OLE DB provider "MSDAORA" for
> linked server "linkedorcl".
> Any new idea?
> Michael
> "Breno" wrote:

Problems with connecting an Oracle DB

Hi,
I linked a SQL Server 2005 to an Oracle DB 7.3
I can run a query like
select * from SERVERNAME..TABLENAME
and I receive the data
But if I run
select * from SERVERNAME..SCHEMANAME.TABLENAME
I receive the following message:
Msg 7399, Level 16, State 1, Line 1
The OLE DB provider "MSDAORA" for linked server "SERVERNAME" reported an
error. The provider did not give any information about the error.
Msg 7303, Level 16, State 1, Line 1
Cannot initialize the data source object of OLE DB provider "MSDAORA" for
linked server "SERVERNAME".
And I receive the same message after running
select * from SERVERNAME..VIEWNAME
or
sp_tables_ex @.table_server=SERVERNAME
(I don't understand why the first statement works)
I don't have such problems on a local SQL Server 2000
Any idea?
ThanksHello, try
exec sp_addlinkedserver 'linkedorcl', 'Oracle', 'MSDAORA', 'linkedorcl'
go
exec sp_addlinkedsrvlogin 'linkedorcl', false, 'sqluser', 'oracleuser',
'oracleuserpassword'
go
dbcc traceon(7399)
go
SELECT * FROM OPENQUERY(linkedorcl, 'SELECT * FROM oracleuser.SALES')
breno tozo
"Michael" wrote:

> Hi,
> I linked a SQL Server 2005 to an Oracle DB 7.3
> I can run a query like
> select * from SERVERNAME..TABLENAME
> and I receive the data
> But if I run
> select * from SERVERNAME..SCHEMANAME.TABLENAME
> I receive the following message:
> Msg 7399, Level 16, State 1, Line 1
> The OLE DB provider "MSDAORA" for linked server "SERVERNAME" reported an
> error. The provider did not give any information about the error.
> Msg 7303, Level 16, State 1, Line 1
> Cannot initialize the data source object of OLE DB provider "MSDAORA" for
> linked server "SERVERNAME".
> And I receive the same message after running
> select * from SERVERNAME..VIEWNAME
> or
> sp_tables_ex @.table_server=SERVERNAME
> (I don't understand why the first statement works)
> I don't have such problems on a local SQL Server 2000
> Any idea?
> Thanks
>
>
>
>|||Unfortunately it doesn't works.
I still receive this error message:
Msg 7303, Level 16, State 1, Line 1
Cannot initialize the data source object of OLE DB provider "MSDAORA" for
linked server "linkedorcl".
Any new idea?
Michael
"Breno" wrote:
[vbcol=seagreen]
> Hello, try
> exec sp_addlinkedserver 'linkedorcl', 'Oracle', 'MSDAORA', 'linkedorcl'
> go
> exec sp_addlinkedsrvlogin 'linkedorcl', false, 'sqluser', 'oracleuser',
> 'oracleuserpassword'
> go
> dbcc traceon(7399)
> go
> SELECT * FROM OPENQUERY(linkedorcl, 'SELECT * FROM oracleuser.SALES')
> breno tozo
> "Michael" wrote:
>|||There is a good chance that communications with an Oracle 7.3 is no longer
supported. Oracle is at relase 10g2. Even Oracle doesn't talk to a release
that old.
You at least have to be very careful with which MDAC you are using.
--
Joseph R.P. Maloney, CSP,CCP,CDP
"Michael" wrote:
[vbcol=seagreen]
> Unfortunately it doesn't works.
> I still receive this error message:
> Msg 7303, Level 16, State 1, Line 1
> Cannot initialize the data source object of OLE DB provider "MSDAORA" for
> linked server "linkedorcl".
> Any new idea?
> Michael
> "Breno" wrote:
>

Problems with connecting an Oracle DB

Hi,
I linked a SQL Server 2005 to an Oracle DB 7.3
I can run a query like
select * from SERVERNAME..TABLENAME
and I receive the data
But if I run
select * from SERVERNAME..SCHEMANAME.TABLENAME
I receive the following message:
Msg 7399, Level 16, State 1, Line 1
The OLE DB provider "MSDAORA" for linked server "SERVERNAME" reported an
error. The provider did not give any information about the error.
Msg 7303, Level 16, State 1, Line 1
Cannot initialize the data source object of OLE DB provider "MSDAORA" for
linked server "SERVERNAME".
And I receive the same message after running
select * from SERVERNAME..VIEWNAME
or
sp_tables_ex @.table_server=SERVERNAME
(I don't understand why the first statement works)
I don't have such problems on a local SQL Server 2000
Any idea?
ThanksHello, try
exec sp_addlinkedserver 'linkedorcl', 'Oracle', 'MSDAORA', 'linkedorcl'
go
exec sp_addlinkedsrvlogin 'linkedorcl', false, 'sqluser', 'oracleuser',
'oracleuserpassword'
go
dbcc traceon(7399)
go
SELECT * FROM OPENQUERY(linkedorcl, 'SELECT * FROM oracleuser.SALES')
breno tozo
"Michael" wrote:
> Hi,
> I linked a SQL Server 2005 to an Oracle DB 7.3
> I can run a query like
> select * from SERVERNAME..TABLENAME
> and I receive the data
> But if I run
> select * from SERVERNAME..SCHEMANAME.TABLENAME
> I receive the following message:
> Msg 7399, Level 16, State 1, Line 1
> The OLE DB provider "MSDAORA" for linked server "SERVERNAME" reported an
> error. The provider did not give any information about the error.
> Msg 7303, Level 16, State 1, Line 1
> Cannot initialize the data source object of OLE DB provider "MSDAORA" for
> linked server "SERVERNAME".
> And I receive the same message after running
> select * from SERVERNAME..VIEWNAME
> or
> sp_tables_ex @.table_server=SERVERNAME
> (I don't understand why the first statement works)
> I don't have such problems on a local SQL Server 2000
> Any idea?
> Thanks
>
>
>
>|||Unfortunately it doesn't works.
I still receive this error message:
Msg 7303, Level 16, State 1, Line 1
Cannot initialize the data source object of OLE DB provider "MSDAORA" for
linked server "linkedorcl".
Any new idea?
Michael
"Breno" wrote:
> Hello, try
> exec sp_addlinkedserver 'linkedorcl', 'Oracle', 'MSDAORA', 'linkedorcl'
> go
> exec sp_addlinkedsrvlogin 'linkedorcl', false, 'sqluser', 'oracleuser',
> 'oracleuserpassword'
> go
> dbcc traceon(7399)
> go
> SELECT * FROM OPENQUERY(linkedorcl, 'SELECT * FROM oracleuser.SALES')
> breno tozo
> "Michael" wrote:
> > Hi,
> >
> > I linked a SQL Server 2005 to an Oracle DB 7.3
> > I can run a query like
> > select * from SERVERNAME..TABLENAME
> > and I receive the data
> >
> > But if I run
> > select * from SERVERNAME..SCHEMANAME.TABLENAME
> > I receive the following message:
> > Msg 7399, Level 16, State 1, Line 1
> > The OLE DB provider "MSDAORA" for linked server "SERVERNAME" reported an
> > error. The provider did not give any information about the error.
> > Msg 7303, Level 16, State 1, Line 1
> > Cannot initialize the data source object of OLE DB provider "MSDAORA" for
> > linked server "SERVERNAME".
> >
> > And I receive the same message after running
> > select * from SERVERNAME..VIEWNAME
> > or
> > sp_tables_ex @.table_server=SERVERNAME
> >
> > (I don't understand why the first statement works)
> >
> > I don't have such problems on a local SQL Server 2000
> >
> > Any idea?
> > Thanks
> >
> >
> >
> >
> >
> >
> >
> >|||There is a good chance that communications with an Oracle 7.3 is no longer
supported. Oracle is at relase 10g2. Even Oracle doesn't talk to a release
that old.
You at least have to be very careful with which MDAC you are using.
--
Joseph R.P. Maloney, CSP,CCP,CDP
"Michael" wrote:
> Unfortunately it doesn't works.
> I still receive this error message:
> Msg 7303, Level 16, State 1, Line 1
> Cannot initialize the data source object of OLE DB provider "MSDAORA" for
> linked server "linkedorcl".
> Any new idea?
> Michael
> "Breno" wrote:
> > Hello, try
> >
> > exec sp_addlinkedserver 'linkedorcl', 'Oracle', 'MSDAORA', 'linkedorcl'
> > go
> > exec sp_addlinkedsrvlogin 'linkedorcl', false, 'sqluser', 'oracleuser',
> > 'oracleuserpassword'
> > go
> >
> > dbcc traceon(7399)
> > go
> > SELECT * FROM OPENQUERY(linkedorcl, 'SELECT * FROM oracleuser.SALES')
> >
> > breno tozo
> >
> > "Michael" wrote:
> >
> > > Hi,
> > >
> > > I linked a SQL Server 2005 to an Oracle DB 7.3
> > > I can run a query like
> > > select * from SERVERNAME..TABLENAME
> > > and I receive the data
> > >
> > > But if I run
> > > select * from SERVERNAME..SCHEMANAME.TABLENAME
> > > I receive the following message:
> > > Msg 7399, Level 16, State 1, Line 1
> > > The OLE DB provider "MSDAORA" for linked server "SERVERNAME" reported an
> > > error. The provider did not give any information about the error.
> > > Msg 7303, Level 16, State 1, Line 1
> > > Cannot initialize the data source object of OLE DB provider "MSDAORA" for
> > > linked server "SERVERNAME".
> > >
> > > And I receive the same message after running
> > > select * from SERVERNAME..VIEWNAME
> > > or
> > > sp_tables_ex @.table_server=SERVERNAME
> > >
> > > (I don't understand why the first statement works)
> > >
> > > I don't have such problems on a local SQL Server 2000
> > >
> > > Any idea?
> > > Thanks
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >

Monday, February 20, 2012

problems when connecting with server

Hi, I am developing an application in where I connect with my server of SQL,

but at the time of making pull this offer one exepcion,

the code that I use is the following one

Dim rda As SqlCeRemoteDataAccess = Nothing

rda = New SqlCeRemoteDataAccess

rda.InternetUrl = "http://my-computer/SQLCE/sscesa20.dll"

rda.LocalConnectionString = "Data Source = C:\BD\rda_lab.SDF"

rda.Pull("authors", "SELECT * FROM Authors", "Provider = SQLOLEDB.1; Data Source = my-server; User ID = sa; PASSWORD = psw; initial catalog = SQLCE", RdaTrackOption.TrackingOn)

rda.Dispose()

The message that shows is:

Unhandled Execution Error

Line 40: rda.Pull("authors", "SELECT * FROM Authors..............

I have proven many things and I have not been able to solve I hope it and somebody can help me

So you're using SQL CE 2.0 (from InternetUrl property) which is not supported on desktop and yet providing path to the SDF file which is only valid on desktop (as it has drive letter). That seems to be wrong…

|||Hi Ilya Tumanov , perhaps it does not explain to me correctly.I am developing to an application Web where desire to take the data from my DataBase and to show them in a List Box, when executing the instruction pull before gives back the mentioned error to me|||

What I'm saying is: your RDA code is definitely wrong, it does not matter what exactly you're planning to do with data.

Your InternetUrl and LocalConnectionString properties are in conflict, they can't both be correct.