On 12 Feb 2017, at 11:10am, Constantine Yannakopoulos <[email protected]> 
wrote:

> On Sun, Feb 12, 2017 at 12:53 PM, Simon Slavin <[email protected]> wrote:
>> You might have missed
>> 
>> <https://www.sqlite.org/pragma.html#pragma_table_info>
>> 
>> which, despite its name, also works with views.
> 
> No, this returns the columns of a single table. Suggested pragma
> table_list/view_list would return all tables/views in a database.
> 
> I know I can get that from sqlite_master, but having to prefix it with
> the database name as part of the query syntax:
> 
>  select * from attached_db.sqlite_master;
> 
> makes it impossible to join with pragma database_list:
> 
>  select * from pragma_database_list as dblist, dblist.name.sqlite_master;

Okay, I see what you mean.  I don’t know of a way to do this in one command if 
you may have attached databases.

Simon.
_______________________________________________
sqlite-users mailing list
[email protected]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to