Обсуждение: a few small bugs

Поиск
Список
Период
Сортировка

a few small bugs

От
Ivan
Дата:
Hello,

I use pgAdmin III Version 1.3.0 (May 20 2005)
on Windows XP Pro SP2.

All following small bugs is not very serious but I often use
copy/paste from SQL definition pane so it's important for me.

1. Object SQL definition pane for primary keys, uniques, columns:

---------------------------------------------------------------------------
-- Constraint: "PK_Documents_Id"

-- ALTER TABLE "Documents" DROP CONSTRAINT "PK_Documents_Id"

ALTER TABLE "Documents" ADD CONSTRAINT "PK_Documents_Id" PRIMARY KEY("Id");
---------------------------------------------------------------------------
-- Constraint: "UNQ_Documents_Name"

-- ALTER TABLE "Documents" DROP CONSTRAINT "UNQ_Documents_Name"

ALTER TABLE "Documents" ADD CONSTRAINT "UNQ_Documents_Name" UNIQUE("Name");
---------------------------------------------------------------------------
-- Column: "Id"

-- ALTER TABLE "Documents" DROP COLUMN "Id"

ALTER TABLE "Documents" ADD COLUMN "Id" int4;
ALTER TABLE "Documents" ALTER COLUMN "Id" SET STORAGE PLAIN;
ALTER TABLE "Documents" ALTER COLUMN "Id" SET NOT NULL;
ALTER TABLE "Documents" ALTER COLUMN "Id" SET DEFAULT nextval('public."Documents_Id_seq"'::text);
---------------------------------------------------------------------------

- missed ';' after ALTER TABLE statement but it's allright for other
constraints (foreign keys, checks) and other objects.

2. Object SQL definition pane for domains
---------------------------------------------------------------------------
-- Domain: "TestDomain"

-- DROP DOMAIN "TestDomain";

CREATE DOMAIN "TestDomain" AS int4  CONSTRAINT TestDomain_Check CHECK CHECK ("Check_IGZ"(VALUE));
ALTER DOMAIN "TestDomain" OWNER TO postgres;
---------------------------------------------------------------------------

- missed quotes (") in constraint name.

3. Object SQL definition pane for functions
---------------------------------------------------------------------------
-- Function: "Check_IGZ"(int4)

-- DROP FUNCTION "Check_IGZ"(int4);

CREATE OR REPLACE FUNCTION "Check_IGZ"(int4) RETURNS bool AS
$BODY$ select $1 > 0;
$BODY$ LANGUAGE 'sql' VOLATILE SECURITY DEFINER;
ALTER FUNCTION "Check_IGZ"(int4) OWNER TO postgres;
---------------------------------------------------------------------------

real sql for this function is
CREATE OR REPLACE FUNCTION "Check_IGZ"("in_Value" int4) RETURNS bool AS
$BODY$ select $1 > 0;
$BODY$
LANGUAGE 'sql' VOLATILE SECURITY DEFINER;

- missed parameter name. Though parameter name is not important for
sql procedure language I prefer to specify it - maybe later I'll copy
this definition and create a plpgsql function and I will use these
parameter names in it.

4. When double clicking on objects such functions, tables, types it's
convenient to get current object's properties dialog rather then right
clicking on object and choosing Properties menu item - it saves time.



So please fix all these bugs If it's not very hard.
Thank you for support.

-- 
Best regards,Ivan                          mailto:Ivan-Sun1@mail.ru



Re: a few small bugs

От
"Dave Page"
Дата:

> -----Original Message-----
> From: pgadmin-support-owner@postgresql.org
> [mailto:pgadmin-support-owner@postgresql.org] On Behalf Of Ivan
> Sent: 28 May 2005 18:26
> To: pgadmin-support@postgresql.org
> Subject: [pgadmin-support] a few small bugs
>
> Hello,
>
> I use pgAdmin III Version 1.3.0 (May 20 2005)
> on Windows XP Pro SP2.
>
> All following small bugs is not very serious but I often use
> copy/paste from SQL definition pane so it's important for me.
>
> 1. Object SQL definition pane for primary keys, uniques, columns:
>
> - missed ';' after ALTER TABLE statement but it's allright for other
> constraints (foreign keys, checks) and other objects.

Fixed in trunk and for 1.2.3.

> 2. Object SQL definition pane for domains
>
> - missed quotes (") in constraint name.

Fixed in trunk and for 1.2.3.
> 3. Object SQL definition pane for functions
>
> - missed parameter name. Though parameter name is not important for
> sql procedure language I prefer to specify it - maybe later I'll copy
> this definition and create a plpgsql function and I will use these
> parameter names in it.

Added to todo list.

> 4. When double clicking on objects such functions, tables, types it's
> convenient to get current object's properties dialog rather then right
> clicking on object and choosing Properties menu item - it saves time.

This has always been an option - see File -> Options -> Preferences tab
-> "Show object properties on double click in treeview?"

Thanks for the bug report!

Regards, Dave.