Click here to Skip to main content
13,629,209 members
Click here to Skip to main content
Add your own
alternative version

Stats

9.6K views
614 downloads
13 bookmarked
Posted 14 Sep 2017
Licenced CPOL

A PostgreSQL Notification Example

, 11 Mar 2018
Rate this:
Please Sign up or sign in to vote.
PostgreSQL notifications Windows Forms application

Introduction

This is a fully fledged PostgreSQL notifications Windows Forms application created with Visual Studio 2013.
On the internet, I only found scraps of information on how to do notification events in PostgreSQL, but not a complete working example.

Using the Code

So here it is, the only thing that needs to be present is a database, the table and triggers will be created by the application.

I tested it with PostgreSQL 9.5 and the NpgSql driver.

After pressing the <Start> button, listening starts with the PostgreSQL "listen mynotification" command.
Notification events can be triggered from the application using the <Trigger> and <Insert row> buttons, and also by directly editing the database.

Points of Interest

More information can be found from the links below:

There is also a portable PostgreSQL version, I don't like the newest versions as they tend to be bigger and don't have PgAdminIII included with them, so my favourite remains version 9.4.5 which is only a 10 MB download.

You can download it from the link provided on top, or from:

History

  • V 1.0

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

RickZeeland
Software Developer
Netherlands Netherlands
Software developer in the Netherlands, currently working on Video Surveillance applications.
Experience: C#, C++, VB, ASP, SQL Server, PostgreSQL.
It all started with Black&White, no not the whiskey but the Sinclair ZX81 followed by several Atari's and PC's. The journey continues ...

You may also be interested in...

Comments and Discussions

 
QuestionNeed help getting this to work with Npgsql 4.x.x Pin
9lbhammer12-Jun-18 7:47
member9lbhammer12-Jun-18 7:47 
AnswerRe: Need help getting this to work with Npgsql 4.x.x Pin
RickZeeland12-Jun-18 10:00
mvpRickZeeland12-Jun-18 10:00 
GeneralRe: Need help getting this to work with Npgsql 4.x.x Pin
9lbhammer12-Jun-18 10:15
member9lbhammer12-Jun-18 10:15 
GeneralRe: Need help getting this to work with Npgsql 4.x.x Pin
RickZeeland12-Jun-18 10:21
mvpRickZeeland12-Jun-18 10:21 
QuestionA Bit More Info... Pin
C Grant Anderson12-Mar-18 8:24
professionalC Grant Anderson12-Mar-18 8:24 
AnswerRe: A Bit More Info... Pin
RickZeeland12-Mar-18 8:42
mvpRickZeeland12-Mar-18 8:42 
GeneralRe: A Bit More Info... Pin
PySams15-Mar-18 4:30
professionalPySams15-Mar-18 4:30 
GeneralRe: A Bit More Info... Pin
RickZeeland15-Mar-18 4:37
mvpRickZeeland15-Mar-18 4:37 
GeneralRe: A Bit More Info... Pin
PySams15-Mar-18 4:41
professionalPySams15-Mar-18 4:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Permalink | Advertise | Privacy | Cookies | Terms of Use | Mobile
Web04 | 2.8.180712.1 | Last Updated 11 Mar 2018
Article Copyright 2017 by RickZeeland
Everything else Copyright © CodeProject, 1999-2018
Layout: fixed | fluid