Looking for suggestions about how should I implement an action at database designer UI

From: Luis Ochoa <ziul1979(at)gmail(dot)com>
To: pgadmin-hackers(at)postgresql(dot)org
Subject: Looking for suggestions about how should I implement an action at database designer UI
Date: 2011-06-14 04:31:00
Message-ID: BANLkTin322D9OT+fRANtREzoKfp0atULYw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

In a relationship between tables, I need to allow use of existing columns as
destination target of my foreign key columns.
Right now, when a user create a relationship between two tables, he should
select kind: from fk or from uk ( and which?) and the fk columns are created
in an automatic way at destination table.

This new feature will require a mapping between this new fk columns and
existing columns, allowing user to choose which fk columns will create an
automatic column at destination table, and which column will use a existing
column as fk.

My question is how to do this process, I suggest two ways:

(1) User create a relationship between (dragging mouse) and when he drop
relationship end instead of creating automatic fk, a new dialog starts a
allow user to choose the mapping between each column in fk at destination
table between two options: choose an existing column, create an automatic
one.

(2) User create a relationship between (dragging mouse) and when he drop
relationship all fk columns are automatically created, if user wants to
mapping a fk from a new automatic column or to an existing column, he
should select an option from right click to allow bring a dialog as
described above to do this mapping.

Dialog in both cases will be like:

[origin fk column 1] select mapping between [ automatic fk col and an
existing column ]
[origin fk column 2] select mapping between [ automatic fk col and an
existing column ]
...

Any suggestions or advices are welcome.

Regards, Luis.

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Guillaume Lelarge 2011-06-14 10:21:12 Branch 1.14?
Previous Message Dave Page 2011-06-13 22:52:06 Re: Cut / Paste issue