i know this question was asked before but i have this very weird beginner problem:
i want to update a list of actors by an id in which film they played (only one film)
DataClasses1DataContext db = new DataClasses1DataContext();
var old = from a in db.Actors
where a.id == 1
select a;
db.Log = Console.Out;
foreach (Actor act in old)
{
act.charname = "test";
act.lastname = "new name";
act.money = 1324;
}
db.SubmitChanges();
when i make a select query in my program after i executed this codesnippet the data is changed but when i look in the integrated sql express (server explorer) of my visual studio 2010 nothing happend and when i restart my programm the old vars are there not "test" and "new name" etc..
i dont know what i'm doing wrong i have a dbml file with this table, my table has a primary key and when i debug /breakpoint it on submitchanges() the variables in db changed also
is there something i missed? like a connectionstring or something like that?
thanks for your help!