Re: [Fwd: Re: [Fwd: Re: [GENERAL] DbVisualizer and PG 7.3?

From: Csaba Nagy <nagy(at)domeus(dot)de>
To: "'pgsql-jdbc(at)postgresql(dot)org'" <pgsql-jdbc(at)postgresql(dot)org>
Subject: Re: [Fwd: Re: [Fwd: Re: [GENERAL] DbVisualizer and PG 7.3?
Date: 2002-12-06 14:27:03
Message-ID: 96D568DD7FAAAD428581F8B3BFD9B0F604DE83@goldmine.ecircle.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

OK, I've asked my collegue why he needs the table=null.
His answer:
If you have a schema with a lot of tables (say n), you can get the relations
between them in 2 ways:
1)
for (i iterate all tables)
for (j iterate all tables)
getCrossReference(i, j, ...)

This means n^2 queries;

2)
for (i itearate all tables)
getCrossReference(i, null, ...)

On Oracle this gets you all the realtions for table i.
This would mean n queries.

Now I'm not sure how standards compliant is the Oracle implementation, but
this behavior makes sense for me...

Cheers,
Csaba.

-----Ursprüngliche Nachricht-----
Von: pgsql-jdbc-owner(at)postgresql(dot)org
[mailto:pgsql-jdbc-owner(at)postgresql(dot)org]Im Auftrag von Csaba Nagy
Gesendet: Freitag, 6. Dezember 2002 10:40
An: 'pgsql-jdbc(at)postgresql(dot)org'
Betreff: Re: [Fwd: Re: [JDBC] [Fwd: Re: [GENERAL] DbVisualizer and PG
7.3?

I'm not the one who is affected, one of my colleagues is developing the DB
visualizer in his spare time, but he's not using Postgres (he's Oracle dba).
I was just thinking he's application could be used with Postgres too, as it
is a Java app based on JDBC.
I will forward him this answer, see what he has to say :-)
For the null catalog issue I have no idea if it makes sense, but I can say
that a table can reference itself, this one makes perfect sense.
E.g.:

CREATE TABLE employees (
empid bigint,
boss bigint references employees(empid)
... (other employee data)
);

Thanks,
Csaba.

-----Ursprungliche Nachricht-----
Von: pgsql-jdbc-owner(at)postgresql(dot)org
[mailto:pgsql-jdbc-owner(at)postgresql(dot)org]Im Auftrag von Justin Clift
Gesendet: Freitag, 6. Dezember 2002 03:40
An: Csaba Nagy
Cc: 'Adam Witney'; Dave Cramer; pgsql-jdbc(at)postgresql(dot)org
Betreff: [Fwd: Re: [JDBC] [Fwd: Re: [GENERAL] DbVisualizer and PG 7.3?]]

Hi Csaba,

Is this helpful?

:-)

Regards and best wishes,

Justin Clift

-------- Original Message --------
Subject: Re: [JDBC] [Fwd: Re: [GENERAL] DbVisualizer and PG 7.3?]
Date: 05 Dec 2002 20:25:40 -0500
From: Dave Cramer <davec(at)fastcrypt(dot)com>
Organization: Cramer Consulting
To: Justin Clift <justin(at)postgresql(dot)org>
CC: pgsql-jdbc(at)postgresql(dot)org <pgsql-jdbc(at)postgresql(dot)org>
References: <3DEFD237(dot)7030804(at)postgresql(dot)org>

Justin,

This is from the spec.

primaryCatalog - a catalog name; "" retrieves those without a
catalog; null means drop catalog name from the selection
criteria
primarySchema - a schema name; "" retrieves those without a
schema
primaryTable - the table name that exports the key
foreignCatalog - a catalog name; "" retrieves those without a
catalog; null means drop catalog name from the selection
criteria
foreignSchema - a schema name; "" retrieves those without a
schema
foreignTable - the table name that imports the key

No where do I see primary table can be null, or foreign table
can be null and what cross reference would there be if
primary=foreign?

Dave

On Thu, 2002-12-05 at 17:24, Justin Clift wrote:
> Hi everyone,
>
> Has this been forwarded here yet? Csaba is reporting what looks to be a
> bug in the JDBC driver.
>
>:-(
>
> Regards and best wishes,
>
> Justin Clift
>
> -------- Original Message --------
> Subject: Re: [GENERAL] DbVisualizer and PG 7.3?
> Date: Thu, 5 Dec 2002 14:26:38 +0100
> From: Csaba Nagy <nagy(at)domeus(dot)de>
> To: 'Adam Witney' <awitney(at)sghms(dot)ac(dot)uk>, 'Francois Suter'
<dba(at)paragraf(dot)ch>
> CC: 'pgsql-general' <pgsql-general(at)postgresql(dot)org>
>
> If you want to try out something new (and possibly buggy), take a look at
> this:
> http://dprutean.tripod.com/
> You can arrange your layout and save it and more, all of this through
a web
> interface, and the data is saved in plain XML... quite amazing.
> I've got it working with Oracle, but I couldn't do schema import from
> Postgres, it hangs for some reason.
>
> The author says it's a Postgres JDBC bug, looks like the
> java.sql.DatabaseMetaData#getCrossReference(String primaryCatalog, String
> primarySchema, String primaryTable, String foreignCatalog, String
> foreignSchema, String foreignTable) method hangs in any of the following
> situations:
> a) primaryTable is null;
> b) foreignTable is null;
> c) primaryTable == foreignTable;
> The author sais these inputs are valid according to the JDBC spec.
>
> Cheers,
> Csaba.
>
> le si foreignTable acceeasi valoare ( ca si cum ai vrea sa vezi daca o
> tabela se autoreferentiaza ).
> -----Ursprungliche Nachricht-----
> Von: pgsql-general-owner(at)postgresql(dot)org
> [mailto:pgsql-general-owner(at)postgresql(dot)org]Im Auftrag von Adam Witney
> Gesendet: Donnerstag, 5. Dezember 2002 11:40
> An: Francois Suter
> Cc: pgsql-general
> Betreff: Re: [GENERAL] DbVisualizer and PG 7.3?
>
>
> On 5/12/02 10:35 am, "Francois Suter" <dba(at)paragraf(dot)ch> wrote:
>
> >> One problem I had with this was that if you arrange your tables
around
> the
> >> screen then you couldn't save that 'view' of the tables and so
when you
> >> opened up the program again all the tables were back organised in one
> line
> >> or in one column. Otherwise it looked a really nice tool.
> >
> > True. That's an annoying limitation. And it doesn't seem like the
paying
> > version addresses that. Maybe we can suggest it for their TODO list if
> it's
> > not already there :-)
>
> Yes, I spoke to them about it and they said it was planned for a future
> version, but they did not know which future version!!
>
>
> --
> This message has been scanned for viruses and
> dangerous content by MailScanner, and is
> believed to be clean.
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
--
Dave Cramer <davec(at)fastcrypt(dot)com>
Cramer Consulting

--
"My grandfather once told me that there are two kinds of people: those
who work and those who take the credit. He told me to try to be in the
first group; there was less competition there."
- Indira Gandhi

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Browse pgsql-jdbc by date

  From Date Subject
Next Message Mike Beachy 2002-12-06 15:24:13 PooledConnectionImpl problem
Previous Message Csaba Nagy 2002-12-06 09:40:26 Re: [Fwd: Re: [Fwd: Re: [GENERAL] DbVisualizer and PG 7.3?