Search code examples
cocoasqlitefmdb

How to merge two FMResultSet's based on a common column?


I have two separate SQLite db files and am using FMDB to access them (cocoa wrapper for sqlite).

I retrieve two results - one from each DB, which is in two FMResultSet.

How do I use FMDB to merge and sort the two FMResultSets based on a single common column of the two resulting sets?


Solution

  • FMDB will not handle this for you since it is just a sqlite-Wrapper, and not manipulating, merging or sorting any data. A possibility would be to create a temporary database where you insert your FMResultSets.