I am currently writing a Windows Store app for Windows 8, and I am using SQLite to save to the built-in database in the class library for Windows applications. I am trying to combine data from two different tables in an embedded database, but SQLite continues to throw an unsupported exception from its GenerateCommand method.
I currently have data in both tables, and they both have a question in each table to join. I tried two different methods that threw the same error.
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();
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 quite sure what I am missing here, but it should be something simple and obvious.
source
share