
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How do you specify a DBLINK in a database connection string?
Hello:
I have a need to be able to specify a dblink in a new connection string to a SQL Server database. Does anyone know how to do this? I'm attempting to connect to database A which has a dblink to database B on another server. As always, thanks in advance for any and all responses.
Accepted Solutions


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If both databases are SQL Server then it shouldn't need anything special in the connection string, you would just need to specify the database on the linked server in the SQL Select script (i.e server.database.schema.table).
Just build the connection to db A as you normally would. Database A should then handle the permissions and connection to the linked server.
flipside
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You should connect to database A by using single connection of that DB and then same as database B with different host. Then concatenate them it will came to know whether data is coming up. I am thinking you need atleast one single common field from A & B

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Anil:
Thanks for the response. I should have explained further. The ID I'm using does not have access to Server / Database B. That's why I want to connect to it using Server / Database A's DBLINK. I've successfully tested that outside of Qlikview. I don't know how to build the connection string within Qlikview and Qlikview does not appear to give you an option via the normal connection methodology, unless I'm missing something.
I'm trying to use OLE DB to connect with since it's a SQL Server database.


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If both databases are SQL Server then it shouldn't need anything special in the connection string, you would just need to specify the database on the linked server in the SQL Select script (i.e server.database.schema.table).
Just build the connection to db A as you normally would. Database A should then handle the permissions and connection to the linked server.
flipside

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Dave:
Thanks for the reply. Duh!!! I had a mental block and was thinking I needed to put something in the connection string itself. I tested your solution and it works. Thank you very much.
