问题
I am trying to get data from columns containing a particular string in their name. I have found the answer for MySql MySQL: Select Column names containing a string but I need to do the same query for SQLite. Any suggest?
回答1:
Since SQLite 3.16, you can use PRAGMAs in queries:
SELECT name
FROM pragma_table_info('MyTable')
WHERE name LIKE ...
来源:https://stackoverflow.com/questions/50043164/sqlite-select-data-where-the-column-name-contains-a-string