Re: How to subscribe Microsoft Sql server
Xiaobiao Yin <[email protected]>
| Newsgroups | gmane.comp.db.tds.freetds |
|---|---|
| Message-ID | <KL1PR02MB1285F698A8277464CCA7A34CE8E30@KL1PR02MB1285.apcprd02.prod.outlook.com> |
Hi Frediano
Thank your for timely reply.
For query notifications, it depends a SQL Server ODBC driver<http://www.easysoft.com/products/data_access/odbc-sql-server-driver/index.html> which is not free.
For trigger, I need to implement a program in windows to subscribe the notification
and then transform this information to Linux. This might be a backup method.
Is there a way to use open source to implement this requirement?
Thank
________________________________
From: FreeTDS <[email protected]> on behalf of Frediano Ziglio <[email protected]>
Sent: Wednesday, August 31, 2016 4:39 PM
To: FreeTDS Development Group
Subject: Re: [freetds] How to subscribe Microsoft Sql server
2016-08-30 23:15 GMT+01:00 Xiaobiao Yin <[email protected]>:
> Hi Experts
>
>
> I am very new to FreeTDS and SQL server.
>
> so far I can connect the MS SQL server 2005 from CentOS 7.2 using C program.
>
>
> My requirement is that if the SQL database changed (such as insert ,delete or update some items),
>
> is there a way to know this change?
>
>
> After looking through the APIs, I found there is no such APIs to subscribe specified SQL database table.
>
> Generally, I need to polling this specified table and see if the return results is the same as the last query, but it
>
> seems a little bit complex and no efficiency.
>
>
> So my question is:
>
> Is there an API to subscribe specified table in SQL server database.
>
>
> Any comment and hint is welcome.
>
> Thanks in advance.
>
> Eric
>
One option is query notifications, for instance see
http://www.easysoft.com/support/kb/kb01069.html.
How do I use SQL Server Query Notifications from Linux and ...<http://www.easysoft.com/support/kb/kb01069.html>
www.easysoft.com
Query notifications, introduced in SQL Server 2005, allow an application to request a notification from SQL Server when the results of query change.
The other option is triggers, see
https://msdn.microsoft.com/en-us/library/ms189799.aspx.
Frediano
_______________________________________________
FreeTDS mailing list
[email protected]
http://lists.ibiblio.org/mailman/listinfo/freetds