How to use InsertOrReplace in sqlite.net PCL?
问题 I am using the PCL version of sqlite.net from here (https://github.com/oysteinkrog/SQLite.Net-PCL). Here is my simple class. public class LogEntry { [PrimaryKey, AutoIncrement] public int Key { get; set;} public DateTime Date { get; set; } } When a new instance of LogEntry is created, the Key is automatically set to 0. I set the Date to something and then call InsertOrReplace. The record does get saved in my database. The Key field gets the autoincrement value which happens to be 0 since it