Linked server query from another application

  • I have a specific database that I need to run a simple select statement against. The problem is that this had to be added though the installation of prevasive SQL drivers and adding the database as a linked server. I can run sql commands against it from within the management console so I know everything is working properly.

    My goal is to use VB.net to authenticate a user based on the value in this linked server and I can't install the pervasive drivers onto the work stations. I was hoping to connect to this linked table through the sql server that its linked to.

    Is this possible and if so, what would I need to do in order to query this database

  • Not totally sure what you mean by these drivers and such but if you can view these tables through your linkserver there should be no issue coming from vb.net. SSMS creates a connection the server much the same as vb.net does.

    _______________________________________________________________

    Need help? Help us help you.

    Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.

    Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.

    Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
    Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
    Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
    Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/

  • What I meant by installing drivers was that I need to create a DSN using an ODBC for each workstation that needs to access the data. Its easier to use the linked server in SQL because the users can see that database without additional drivers for the ODBC connector. (The pervasive DB that we are connecting to needs specific drivers)

    I guess my biggest disconnect here is that VB needs a connection string that includes the database, catalog, username and password. A linked server is not a table, or from what I can see through many attempts through code.

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply