[GENERAL] stripping HTML, SQL injections ...

2007-11-14 Thread madhtr
Quick question, are there any native functions in PostGreSQL 8.1.4 that will strip HTML tags, escape chars, etc? thanx:) ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] How to clear bits?

2007-09-20 Thread madhtr
nevermind, I figured it out ... fails: 0xff00 &~ 0x succeeds: 0xff00 & ~ 0x I had to add a space. - Original Message - From: "madhtr" <[EMAIL PROTECTED]> To: "PostgreSQL General" Sent: Thursday, September 20, 2007 13:

[GENERAL] How to clear bits?

2007-09-20 Thread madhtr
Hello group :) How do a clear bits in a number in PostGreSQL? in c++ its: 0xff00 &~ 0x what is it in PostGreSQL from the psql command line app? select ... Thanx:) ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner

Re: [GENERAL] pqlib in c++: PQconnectStart PQconnectPoll

2007-08-16 Thread madhtr
password=%s", host,port,dbname,user,password ); if (PGconn* lpcn = asyncconnect(cs,&cancel)){ printf("PQerrorMessage(lpcn) returns:\n\n%s\n\nPQstatus(lpcn) returns %d\n",PQerrorMessage(lpcn),PQstatus(lpcn)); PQfinish(lpcn); }; return 0; }; /////

Re: [GENERAL] pqlib in c++: PQconnectStart PQconnectPoll

2007-08-16 Thread madhtr
ok, ty :) - Original Message - From: "Alvaro Herrera" <[EMAIL PROTECTED]> To: "madhtr" <[EMAIL PROTECTED]> Cc: "Tom Lane" <[EMAIL PROTECTED]>; Sent: Thursday, August 16, 2007 11:36 Subject: Re: [GENERAL] pqlib in c++: PQconnectStart

Re: [GENERAL] pqlib in c++: PQconnectStart PQconnectPoll

2007-08-16 Thread madhtr
Hi Tom :) Is this: libpq-fe.h: /** $PostgreSQL: pgsql/src/interfaces/libpq/libpq-fe.h,v 1.134 2006/10/04 00:30:13 momjian Exp $ **/ the latest version of libpq? - Original Message - From: "Tom Lane" <[EMAIL PROTECTED]> To: "madhtr" <[EMAIL PROTECTED

Re: [GENERAL] pqlib in c++: PQconnectStart PQconnectPoll

2007-08-15 Thread madhtr
- Original Message - From: "madhtr" <[EMAIL PROTECTED]> To: "Tom Lane" <[EMAIL PROTECTED]> Cc: Sent: Wednesday, February 14, 2007 22:33 Subject: Re: [GENERAL] pqlib in c++: PQconnectStart PQconnectPoll Another line of thought, given the reading-betwe

Re: [GENERAL] pqlib in c++: PQconnectStart PQconnectPoll

2007-08-14 Thread madhtr
- Original Message - From: "Tom Lane" <[EMAIL PROTECTED]> To: "madhtr" <[EMAIL PROTECTED]> Cc: Sent: Tuesday, August 14, 2007 18:50 Subject: Re: [GENERAL] pqlib in c++: PQconnectStart PQconnectPoll "madhtr" <[EMAIL PROTECTED]>

Re: [GENERAL] pqlib in c++: PQconnectStart PQconnectPoll

2007-08-14 Thread madhtr
us(lpcn) returns %d\n", PQerrorMessage(lpcn),PQstatus(lpcn) ); PQfinish(lpcn); } else printf("I am assuming we are out of memory ...\n"); return e; }; / - Original Message - From: "Tom Lane" <[EMAIL P

Re: [GENERAL] pqlib in c++: PQconnectStart PQconnectPoll

2007-08-14 Thread madhtr
}; return pr; }; - Original Message - From: "Tom Lane" <[EMAIL PROTECTED]> To: "madhtr" <[EMAIL PROTECTED]> Cc: Sent: Tuesday, August 14, 2007 14:36 Subject: Re: [GENERAL] pqlib in c++: PQconnectStart PQconnectPoll "madhtr" <[EMAIL PROTEC

[GENERAL] pqlib in c++: PQconnectStart PQconnectPoll

2007-08-14 Thread madhtr
when i intentioally try to connect asynchronously to a database that does not exist, i get "server closed the connection unexpectedly" My intention is to create the database if it does not exist ... Is there any way retrive the actual error so i can know when to create the database? thanx:)

[GENERAL] exception question ....

2007-05-20 Thread madhtr
sry, one more question ... I want to trap an exception and return a -1 no matter WHAT it is ... what do i need to replace with? create or replace function clrsplit(int4) returns unknown as $$ BEGIN delete from split where tkid=$1; EXCEPTION WHEN return -1; update tk set dtchksp=null wher

[GENERAL] Hex numbers in psql

2007-05-20 Thread madhtr
hi group :) How do use hex numbers in psql? I.E. instead of: select 16 I want to do select 0x10 like in c++ I tried doing what this website said http://www.faqs.org/docs/ppbook/c12119.htm but it does not work TY :) ---(end of broadcast)--