SQLiteQueryBuilder.query() vs SQLiteDatabase.query()

后端 未结 2 1476
独厮守ぢ
独厮守ぢ 2020-12-29 23:56

What\'s the difference between these two approaches? For me it seems that the only benefit of SQLiteDatabase is its ability to work with different databases. Am I right?

2条回答
  •  慢半拍i
    慢半拍i (楼主)
    2020-12-30 00:21

    SQLiteQueryBuilder is useful if you want to do joins on multiple tables. It has several convenience methods for that, if you view the source-code on GrepCode: SQLiteQueryBuilder

    Otherwise, I cannot think of a solid reason to use SQLiteQueryBuilder over other approaches for querying the database.

提交回复
热议问题