Include comments on procedures in the reverse engineered SQL.
authordpage <dpage@a7884b65-44f6-0310-8a51-81a127f17b15>
Tue, 4 Aug 2009 11:09:32 +0000 (11:09 +0000)
committerdpage <dpage@a7884b65-44f6-0310-8a51-81a127f17b15>
Tue, 4 Aug 2009 11:09:32 +0000 (11:09 +0000)
git-svn-id: svn://svn.pgadmin.org/trunk/pgadmin3@8003 a7884b65-44f6-0310-8a51-81a127f17b15

CHANGELOG
pgadmin/schema/pgFunction.cpp

index d4390c2b99f4ac90aac44599be7ac98a4cfff1c7..795b7f63cf75898fdd289f85d8e96c6e561f8eca 100644 (file)
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -36,6 +36,8 @@ Changes
 
 Date       Dev Ver     Change details
 ---------- --- ------  --------------
+2009-08-04 DP  1.10.1  Include comments on procedures in the reverse engineered
+                       SQL.
 2009-08-03 GL  1.12.0  Better l10n support on the Grant Wizard, per a
                        patch from Marek Cernocky.
 2009-08-03 GL  1.12.0  Better l10n support on the generated reports, per a
index e285341b1e92bc67001d153fb406cd7c167c200c..9eac9ea66a83e48558e30fc5c38be1b154215c56 100644 (file)
@@ -259,6 +259,12 @@ wxString pgProcedure::GetSql(ctlTree *browser)
             + GetSource()
             + wxT("\n\n")
             + GetGrant(wxT("X"), wxT("PROCEDURE ") + qtSig);
+
+        if (!GetComment().IsNull())
+        {
+            sql += wxT("COMMENT ON PROCEDURE ") + GetQuotedFullIdentifier()
+                + wxT(" IS ") + qtDbString(GetComment()) + wxT(";\n");
+        }
     }
 
     return sql;