SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Linked Server weirdness to Sybase


Linked Server weirdness to Sybase

Author
Message
bw03
bw03
Forum Newbie
Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)

Group: General Forum Members
Points: 3 Visits: 192
This is for a linked server on SQL 2008 R2.

Here are the facts:

SQL 2008 R2 on Microsoft Windows Server 2003 R2 (SP2)


I created a Sybase Linked server and it works fine for me.

When one of the developers try to use it, SELECT * FROM OPENQUERY(mylinkedserver, 'select * from table1'), he gets this message: Cannot create an instance of OLE DB provider "ASEOLEDB" for linked server "mylinkedserver".

The developer AD login is also setup as a sysadmin on the sql server instance.

The developer has no problems using an Oracle linked server

When I make the developer an administrator to the server itself, the linked server works for him.

Any ideas why? We cannot make the developer an admin to the server itself so we took him out of the "Administrators" group and the linked server no longer works.

Edit: Here's the script to create the linked server. Names, Dates, Ports, Places, and other stuff have been change to protect the innocent.


EXEC master.dbo.sp_addlinkedserver @server = N'mylinkedserver', @srvproduct=N'Sybase', @provider=N'ASEOLEDB', @datasrc=N'sybaseServer,8888'
EXEC master.dbo.sp_addlinkedsrvlogin @rmtsrvname=N'mylinkedserver',@useself=N'False',@locallogin=NULL,@rmtuser=N'username',@rmtpassword='########'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'collation compatible', @optvalue=N'false'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'data access', @optvalue=N'true'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'dist', @optvalue=N'false'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'pub', @optvalue=N'false'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'rpc', @optvalue=N'false'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'rpc out', @optvalue=N'false'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'sub', @optvalue=N'false'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'connect timeout', @optvalue=N'0'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'collation name', @optvalue=null
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'lazy schema validation', @optvalue=N'false'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'query timeout', @optvalue=N'0'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'use remote collation', @optvalue=N'true'
GO

EXEC master.dbo.sp_serveroption @server=N'mylinkedserver', @optname=N'remote proc transaction promotion', @optvalue=N'true'
GO



chandan_jha18
chandan_jha18
SSC Eights!
SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)

Group: General Forum Members
Points: 897 Visits: 2134
It has been a long time since i worked in a mixed environments and my current one does not a sybase db so I can only mention few things which I can recall.

I can recall from my memory that we used to create DSNs in order to create linked server to Sybase. On your server, have you configured a system DSN for the above Sybase database? Please confirm the same.

Chandan
chandan_jha18
chandan_jha18
SSC Eights!
SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)

Group: General Forum Members
Points: 897 Visits: 2134
If your answer is 'YES' to my question above, then I can recall that system DSN can be used by everyone who is a user of that system. When you make this guy a server admin, the DSN is accessible to him otherwise not. Try adding him as a normal user(not any admin) to the server and then verify if this guy is able to use the DSN. also, we need to make sure that remote desktop ability for him remains disabled so ask your windows guys to assign him the least permissions.

Try this please.
bw03
bw03
Forum Newbie
Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)

Group: General Forum Members
Points: 3 Visits: 192
No, there are no DSNs setup on the server.
chandan_jha18
chandan_jha18
SSC Eights!
SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)

Group: General Forum Members
Points: 897 Visits: 2134
bw03 (7/27/2011)
No, there are no DSNs setup on the server.


are you on a 32-bit server or 64 bit. I am sure that i used to configure 32-bit DSNs for connecting to sybase 4 years back. not sure what is the new way being used these days.
bw03
bw03
Forum Newbie
Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)

Group: General Forum Members
Points: 3 Visits: 192
32bit. We're using the OLEDB provider not ODBC.
chandan_jha18
chandan_jha18
SSC Eights!
SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)SSC Eights! (897 reputation)

Group: General Forum Members
Points: 897 Visits: 2134
bw03 (7/27/2011)
32bit. We're using the OLEDB provider not ODBC.


You had mentione that the developer is sysadmin on sql server so i find it strange that something is stopping him.I suggest you run the profiler and ask your developer to try and fire a query using the linked server and see if something comes up in profiler.

Also, i would like you to open a question in msdn forums in an rea which deals with connections from SQL to heterogenous database engines.
Eric L Hackett
Eric L Hackett
SSC Journeyman
SSC Journeyman (90 reputation)SSC Journeyman (90 reputation)SSC Journeyman (90 reputation)SSC Journeyman (90 reputation)SSC Journeyman (90 reputation)SSC Journeyman (90 reputation)SSC Journeyman (90 reputation)SSC Journeyman (90 reputation)

Group: General Forum Members
Points: 90 Visits: 211
We had a similar instance, where a linked server that once functioned for certain users stopped functioning. Our solution was actually to increase the permissions on the Windows server for the Windows user under which the (local) server instance was running as a service. Not sure if it was a Windows OS update, or something else that caused the issue, but that solved it.
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search