X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 3B9D93A42DC for ; Wed, 19 Jan 2005 15:50:35 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 03692-10 for ; Wed, 19 Jan 2005 15:50:16 +0000 (GMT) Received: from mx-00.sil.at (mx-00.sil.at [62.116.68.196]) by svr1.postgresql.org (Postfix) with ESMTP id 71A1F3A42FD for ; Wed, 19 Jan 2005 15:50:10 +0000 (GMT) Received: (qmail-ldap/ctrl 86428 invoked from network); 19 Jan 2005 15:50:02 -0000 Received: from unknown (HELO jupiter.sonorys.at) ([213.235.243.42]) (envelope-sender ) by mx-00.sil.at (qmail-ldap-1.03) with SMTP for ; 19 Jan 2005 15:50:02 -0000 Received: from neptun.sonorys.at (neptun.sonorys.at [172.24.1.17]) by jupiter.sonorys.at (8.11.7+Sun/8.11.7) with ESMTP id j0JFoGs18327 for ; Wed, 19 Jan 2005 16:50:16 +0100 (MET) Received: by neptun.sonorys.at with Internet Mail Service (5.5.2653.19) id ; Wed, 19 Jan 2005 16:50:05 +0100 Message-ID: From: =?ISO-8859-1?Q?K=D6PFERL_Robert?= To: pgsql-sql@postgresql.org Subject: Re: Conversion ideas (Views/procedures) Date: Wed, 19 Jan 2005 16:50:05 +0100 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: by amavisd-new at hub.org X-Archive-Number: 200501/148 X-Sequence-Number: 19936 As so often, I would suggest regular languages to accomplish most of = the work that comes up. Use for example ours all friend 'sed' to edit a big sql-dump. you can for example simply replace isnull(X) by X is null. RegEx will possibly not reach for all posibilities but the're very good = for the first big steps towards your goal. > -----Original Message----- > From: Joel Fradkin [mailto:jfradkin@wazagua.com] > Sent: Mittwoch, 19. J=E4nner 2005 16:23 > To: pgsql-sql@postgresql.org > Subject: [SQL] Conversion ideas (Views/procedures) >=20 >=20 > I am new to Postgres and am converting our MSSQL database to = Postgres. >=20 > I just did my first function. > My question is does it make sense to create functions for=20 > some of the common > functionality available to the MSSQL world (left, isnull,=20 > etc) so I do not > need visit every view, and stored procedure to remove them? > If it does is there a body of work anywhere? > If not what is the best approach just remove all non existent=20 > (re-engineer) > functions from my views and procedures. I understand some of=20 > the items are > available, but a bit different either the name of the=20 > function or its use. I > did see a how to that alerted me to the datefiff being=20 > date_diff and to > watch out for the yy needing to be 'year' etc. he mentioned to use > coalesce() instead of isnull also. Any other common ones I=20 > should be aware > of? >=20 >=20 > Joel Fradkin > =A0 > Wazagua, LLC > 2520 Trailmate Dr > Sarasota, Florida 34243 > Tel.=A0 941-753-7111 ext 305 > =A0 > jfradkin@wazagua.com > www.wazagua.com > Powered by Wazagua > Providing you with the latest Web-based technology & advanced tools. > =A9 2004. WAZAGUA, LLC. All rights reserved. WAZAGUA, LLC > =A0This email message is for the use of the intended=20 > recipient(s) and may > contain confidential and privileged information.=A0 Any=20 > unauthorized review, > use, disclosure or distribution is prohibited.=A0 If you are=20 > not the intended > recipient, please contact the sender by reply email and=20 > delete and destroy > all copies of the original message, including attachments. > =A0 >=20 > =A0 >=20 >=20 >=20 > ---------------------------(end of=20 > broadcast)--------------------------- > TIP 4: Don't 'kill -9' the postmaster >=20