Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Newbie SQL Question

Re: Newbie SQL Question

From: Laurenz Albe <invite_at_spam.to.invalid>
Date: 26 Jul 2007 08:17:13 GMT
Message-ID: <1185437832.72458@proxy.dienste.wien.at>


Ana C. Dent <anacedent_at_hotmail.com> wrote:
>> Let's say there is a table called "table_map", which has two columns,
>> "tablename" and "sql_mapping". If I say:
>> " select tablename from table_map where sql_mapping is not null.", I
>> will get a list of tables that exist in the same database.
>>
>> Besides, if I say: "select count(*) from <table name>", I will get the
>> rows in one table.
>>
>> So my Question is is there a way I can combine both SQLs into one,
>> that returns me the counts of each table, and the table_names from the
>> "table_map".

>
> sure, go ahead & do it.

Big words, little evidence.
I doubt that you can do this in one SQL query.

Besides I think that this is a bad idea at all. If any of the tables are large, this will take long and do a lot of I/O.

Yours,
Laurenz Albe Received on Thu Jul 26 2007 - 03:17:13 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US