Unix Technical Forum

Admin Tool to Send Me Email

This is a discussion on Admin Tool to Send Me Email within the Pgsql General forums, part of the PostgreSQL category; --> We have been using PostgreSQL on Mac OS X for about a year now. Ongoing monitoring has proven very ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > Pgsql General

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-08-2008, 08:33 PM
Garris, Nicole
 
Posts: n/a
Default Admin Tool to Send Me Email

We have been using PostgreSQL on Mac OS X for about a year now. Ongoing
monitoring has proven very easy because the DBMS engine is so reliable, and
mostly I use phpPgAdmin, an extremely useful tool. However, its worth my
while to make it even easier. I would like a tool that would send an email
whenever an error message is generated, such as messages from SQL class 53
(53100 disk full, 53200 out of memory, 53300 too many connections), class 57
operator intervention, class 58 system error, and a few others.



I looked for such a free tool on pgFoundry, Gborg, and postgresql.org's
Downloads page but didn't see anything like it. If you know of one, I would
really appreciate it if you provided the web site. Thank you!


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-08-2008, 08:33 PM
Costin Manda
 
Posts: n/a
Default Division by zero


In other SQL programs a division by zero is solved by transforming the
result to NULL. How can I make postgres have the same behaviour without
using CASE ?



---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 04-08-2008, 08:33 PM
Michael Fuhr
 
Posts: n/a
Default Re: Division by zero

On Sat, Apr 16, 2005 at 10:15:55AM +0300, Costin Manda wrote:
>
> In other SQL programs a division by zero is solved by transforming the
> result to NULL.


The SQL standards state that "If the value of a divisor is zero,
then an exception condition is raised: data exception -- division
by zero." Databases that silently convert this exception to NULL
(e.g., MySQL) are violating standards.

> How can I make postgres have the same behaviour without using CASE ?


Why don't you want to use CASE? Because it's unwieldy?

You could wrap CASE in a function and call that function instead
of using the / operator. I'd avoid any temptation to change the
behavior of the operator itself because that could cause problems
in other code that isn't expecting it.

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 04-08-2008, 08:33 PM
Craig Bryden
 
Posts: n/a
Default Re: Division by zero

Hi Costin

I am very experienced with MS-SQL and have had very basic training on Oracle
and both of these raise an exception as well. I would suggest that a RDBMS
that automatically converts to null is way off the standards.

Craig


----- Original Message -----
From: "Costin Manda" <siderite@madnet.ro>
To: <pgsql-general@postgresql.org>
Sent: Saturday, April 16, 2005 9:15 AM
Subject: [GENERAL] Division by zero


>
> In other SQL programs a division by zero is solved by transforming the
> result to NULL. How can I make postgres have the same behaviour without
> using CASE ?
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 8: explain analyze is your friend
>
>



---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo@postgresql.org so that your
message can get through to the mailing list cleanly

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 05:21 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com