Re: information about the tables in the database

2002-10-10 Thread Chris Stoughton

I do this with

select db;
show tables;

then parse through the result.




Niclas Hedhman wrote:

On Wednesday 09 October 2002 21:43, Inbal Ovadia wrote:
  

Hi all,
There is a way to know if I have table x in my db?
Let's say some catalog tables that hold information about the db like
tables name etc.
and i can do query like select tables from catalogName and get all the
tables in the db



Talking about programmatically?
What client are you using?
Since the JDBC driver can pick up all the database, table and column 
information, it should be available reasonably easy in other clients as well.

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

  





-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




information about the tables in the database

2002-10-09 Thread Inbal Ovadia

Hi all,
There is a way to know if I have table x in my db?
Let's say some catalog tables that hold information about the db like tables
name etc.
and i can do query like select tables from catalogName and get all the
tables in the db

thanks :)
Inbal

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: information about the tables in the database

2002-10-09 Thread Brian Reichert

On Wed, Oct 09, 2002 at 03:43:15PM +0200, Inbal Ovadia wrote:
 Hi all,
 There is a way to know if I have table x in my db?
 Let's say some catalog tables that hold information about the db like tables
 name etc.
 and i can do query like select tables from catalogName and get all the
 tables in the db

'show tables'

 
 thanks :)
 Inbal
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail [EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
 

-- 
Brian 'you Bastard' Reichert[EMAIL PROTECTED]
37 Crystal Ave. #303Daytime number: (603) 434-6842
Derry NH 03038-1713 USA Intel architecture: the left-hand path

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: information about the tables in the database

2002-10-09 Thread Iikka Meriläinen

On Wed, 9 Oct 2002, Inbal Ovadia wrote:

 Hi all,
 There is a way to know if I have table x in my db?
 Let's say some catalog tables that hold information about the db like tables
 name etc.
 and i can do query like select tables from catalogName and get all the
 tables in the db

Hi,

I guess that's not possible.

SHOW TABLES shows your tables in the database, but unfortunately you can't
do something like SELECT * FROM (SHOW TABLES) WHERE Tables_in_xx =
'blahblah'

Of course you can create a table that contains metadata for your tables, but
you would have to update it manually. Or you could have an external program
scanning your data directories for added/removed table files.

Regards,
Iikka

**
* Iikka Meriläinen   *
* E-mail: [EMAIL PROTECTED] *
* Vaala, Finland *
**


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: information about the tables in the database

2002-10-09 Thread nellA hciR

show tables;

On Wednesday, Oct 9, 2002, at 05:43 America/Anchorage, Inbal Ovadia 
wrote:

 Hi all,
 There is a way to know if I have table x in my db?
 Let's say some catalog tables that hold information about the db like 
 tables
 name etc.
 and i can do query like select tables from catalogName and get all 
 the
 tables in the db


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: information about the tables in the database

2002-10-09 Thread Iikka Meriläinen

On Wed, 9 Oct 2002, Brian Reichert wrote:

 On Wed, Oct 09, 2002 at 03:43:15PM +0200, Inbal Ovadia wrote:
  Hi all,
  There is a way to know if I have table x in my db?
  Let's say some catalog tables that hold information about the db like tables
  name etc.
  and i can do query like select tables from catalogName and get all the
  tables in the db

 'show tables'

But can you do a SELECT on the result set from that statement? Please let me
know if it's possible.

Iikka

**
* Iikka Meriläinen   *
* E-mail: [EMAIL PROTECTED] *
* Vaala, Finland *
**


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: information about the tables in the database

2002-10-09 Thread Jeremy Tinley

show tables;
show tables from catalogName;
show tables from catalogName like 'order%';

-J

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] On Behalf
Of Iikka Meriläinen
Sent: Wednesday, October 09, 2002 10:09 AM
To: Inbal Ovadia
Cc: '[EMAIL PROTECTED]'
Subject: Re: information about the tables in the database

On Wed, 9 Oct 2002, Inbal Ovadia wrote:

 Hi all,
 There is a way to know if I have table x in my db?
 Let's say some catalog tables that hold information about the db like
tables
 name etc.
 and i can do query like select tables from catalogName and get all
the
 tables in the db

Hi,

I guess that's not possible.

SHOW TABLES shows your tables in the database, but unfortunately you
can't
do something like SELECT * FROM (SHOW TABLES) WHERE Tables_in_xx =
'blahblah'

Of course you can create a table that contains metadata for your tables,
but
you would have to update it manually. Or you could have an external
program
scanning your data directories for added/removed table files.

Regards,
Iikka

**
* Iikka Meriläinen   *
* E-mail: [EMAIL PROTECTED] *
* Vaala, Finland *
**


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail
[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php



-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: information about the tables in the database

2002-10-09 Thread gerald_clark

Sure you can.

show tables like 's%' from mydatabase;

Iikka Meriläinen wrote:

On Wed, 9 Oct 2002, Inbal Ovadia wrote:

  

Hi all,
There is a way to know if I have table x in my db?
Let's say some catalog tables that hold information about the db like tables
name etc.
and i can do query like select tables from catalogName and get all the
tables in the db



Hi,

I guess that's not possible.

SHOW TABLES shows your tables in the database, but unfortunately you can't
do something like SELECT * FROM (SHOW TABLES) WHERE Tables_in_xx =
'blahblah'

Of course you can create a table that contains metadata for your tables, but
you would have to update it manually. Or you could have an external program
scanning your data directories for added/removed table files.

Regards,
Iikka

**
* Iikka Meriläinen   *
* E-mail: [EMAIL PROTECTED] *
* Vaala, Finland *
**


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail 
[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php


  




-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: information about the tables in the database

2002-10-09 Thread Niclas Hedhman

On Wednesday 09 October 2002 21:43, Inbal Ovadia wrote:
 Hi all,
 There is a way to know if I have table x in my db?
 Let's say some catalog tables that hold information about the db like
 tables name etc.
 and i can do query like select tables from catalogName and get all the
 tables in the db

Talking about programmatically?
What client are you using?
Since the JDBC driver can pick up all the database, table and column 
information, it should be available reasonably easy in other clients as well.

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php