开发者

Extract columns from two different database in sqlite3

Is it possible to extract columns from two different database in sqlite3?

My problem is, I have two tables in two different database and I want to retrieve columns from tables from these two database.

To make it more clear, here is my pseudocode.

"SELECT Table_FromFirstDatabase.product 
 FROM MyFirstDatabase.Table_FromFirstDatabase
 WHERE   product NOT IN ('SELECT  Table_FromSecondDatabase.product 
                        FROM MySecondDatabase.Table_FromSecondDatabase');"

Is it possible to do something li开发者_StackOverflow社区ke this in sqlite3 ??

Thank you....


You can do that:

ATTACH statements in SQLite.

Note that you could probably use SELECT t1.product FROM db1.tbl1 AS t1 EXCEPT (other select statement) instead of WHERE NOT IN


No. It's probably better for you to pull the data in a local list/array anyways.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜