load database tables

Jan Schenkel janschenkel at yahoo.com
Mon Jun 13 16:10:35 EDT 2005


--- t <trknssr at gmail.com> wrote:
> hi,
> 
> I'm trying to load my database tables into a
> scrolling field, I
> connected to the database but I can't find a command
> to get the
> tables.
> 
> Is there a command that stores the tables in an
> array or a scrolling field.
> 
> thanx,
> -- 
> t
> 

Hi T,

There is an undocumented function 'revdb_tablenames'
that will give you the table names for a given
connection.

Example:
--
  put revdbconnect(...) into tCOnnectionID
  put revdb_tablenames(tConnectionID) into theTables
--

Unfortunately, it doesn't work for all databases, but
if it doesn't, other database users might be able to
give you a hand to construct the SQL needed to extract
the information.

E.g. for MS-Access, the SQL is something like:
--
  SELECT name FROM MSysObjects WHERE type IN (1,6)
  AND name NOT LIKE 'MSys%'
--

Hope this gets you a little closer to the solution,

Jan Schenkel.

Quartam - Tools for Revolution
<http://www.quartam.com>

=====
"As we grow older, we grow both wiser and more foolish at the same time."  (La Rochefoucauld)


		
__________________________________ 
Yahoo! Mail Mobile 
Take Yahoo! Mail with you! Check email on your mobile phone. 
http://mobile.yahoo.com/learn/mail 


More information about the use-livecode mailing list