> On Feb 8, 2011, at 9:07 PM, Rami Abughazaleh wrote:
> 
>> I would like to request that "PRAGMA foreign_key_list(tableName)" display
>> the name of the foreign key constraint.

Thirded!

Or, much better yet, move away from pragmas altogether for introspection, 
instead using internal tables/views like the current SQLite_Master. Then we can 
filter the results, such as:

select Name, From_Table, To_Column from SQLite_Foreign_Key_List where To_Table 
= 'My Table' and To_Column = 'My_Column';

Currently, I have to run pragma foreign_key_list() for each of my tables, copy 
the result of each into a master table, then query that table. It's slow and 
requires a lot of application code and back and forth with multiple pragmas to 
do what SQLite is already doing internally.

Thanks,
Tom
BareFeetWare

 --
Comparison of SQLite GUI tools:
http://www.barefeetware.com/sqlite/compare/?ml

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to