[Interest] [Development] Listen to database update

Giuseppe D'Angelo giuseppe.dangelo at kdab.com
Mon Jun 2 14:29:24 CEST 2014


Hi,

This is the wrong list (for developers OF Qt). Moving the discussion to 
the right one (for developers WITH Qt).

Il 02/06/2014 14:25, Olivier Austina ha scritto:
> Is there a way to listen for a database updating. I have a program and I
> want to know when the database change (for insert and update event). Any
> suggestion is welcome. Thank you.

Depending on the actual database you can push notifications to Qt which 
will be emitted as signals (see QSqlDriver::notification). For instance, 
with PostgreSQL you can put a NOTIFY statement in a trigger connected to 
your table insert/updates commands.

HTH,
-- 
Join us Oct 6-8 at BCC Berlin for Qt Developer Days 2014!
Giuseppe D'Angelo | giuseppe.dangelo at kdab.com | Software Engineer
KDAB (UK) Ltd., a KDAB Group company
Tel. UK +44-1738-450410, Sweden (HQ) +46-563-540090
KDAB - Qt Experts - Platform-independent software solutions

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4048 bytes
Desc: Firma crittografica S/MIME
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20140602/9947faa3/attachment.bin>


More information about the Interest mailing list