dimanche 27 décembre 2015

SQLite Update at end of variable C# (UWP)

The code below can replace the string in the table with a new string, but how could I modify it so that it adds the string on the existing string in the table (rather than setting it to the new one).

public IEnumerable<UserAccount> FavouriteUser()
{
    return conn.Query<UserAccount>("UPDATE [UserAccount] SET [Favourites] = '" + favourite + "' WHERE [Online] = '" + isonline + "'");
}

Also I would like to have an undo button, which would search the column if it contains a string and removes that string specifically, so which statement or keyword would enable me to do this?

Aucun commentaire:

Enregistrer un commentaire