I am currently writing a Windows Store Application for Windows 8 and I am using SQLite for the persistence on the embedded database in a class library for windows apps. I am trying to join data from two different tables in my embedded database but SQLite keeps throwing a not supported exception from their GenerateCommand method.
I do currently have data in both tables and they both have a questionId in each table to join on. I've tried two different methods which both throw the same error.
The first method:
var q = (from gameTable in db.Table<Model.GameSaved>()
join qTable in db.Table<Questions>() on gameTable.QuestionId equals qTable.QuestionId
select qTable
).First();
The second method:
var q =
(from question in db.Table<Model.GameSaved>()
select question
).Join(db.Table<Questions>(),
game => game.QuestionId,
questionObject => questionObject.QuestionId,
(game,questionObject) => questionObject)
.First();
I'm not exactly sure what I'm missing here but it has to be something simple and obvious.