ODBC Connection

Paul 61 Reputation points
2022-09-02T15:16:23.73+00:00

What is the best way to script to achieve the following on the client Windows 10 computer at a scheduled set time (Windows Task)...
To detect specific ODBC connection, if opens, close it.

batch file or console app?

Windows for business Windows Client for IT Pros User experience Other
Developer technologies .NET .NET CLI
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Michael Taylor 60,161 Reputation points
    2022-09-02T16:08:27.607+00:00

    Powershell would be my choice. But I'm curious what you mean by a specific ODBC connection as that is per process. So you wouldn't see it from another process unless you were doing this from a database server and querying the database itself. In that case it would depend upon your DB.


  2. S.Sengupta 24,476 Reputation points MVP
    2022-09-03T01:11:35.357+00:00

    You can try ODBC Test Connection Using PowerShell or, using a DQY File.

    https://blog.devart.com/4-ways-to-test-an-odbc-connection.html

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.