not bug, just not smart enough~

Feb 19, 2009 at 3:44 PM
 ///<summary>test</summary>
    public abstract class test : LinqObjectModel<test>
    {
        public abstract string t { get; set; }

        public abstract string s { get; set; }
        
    }


then

--------------------------------------------

DbEntry.Context.DropAndCreate(typeof(test));
            var s = test.New();
            s.s = "1";
            s.t = "2";
            s.Save();

            var v = test.FindById(1);
            v.s = "3";
            v.Save();

            v.t = "4";
            v.Save();

-----------------------------------------------

Trace,,SQL,CREATE TABLE [test] (
[Id] INTEGER PRIMARY KEY AUTOINCREMENT ,
[t] ntext NOT NULL ,
[s] ntext NOT NULL 
);
<Text><30>(),
Trace,,SQL,Insert Into [test] ([t],[s]) Values (@t_0,@s_1);
SELECT last_insert_rowid();
<Text><30>(@t_0=2:String,@s_1=1:String),
Trace,,SQL,Select [Id],[t],[s] From [test] Where [Id] = @Id_0;
<Text><60>(@Id_0=1:Int64),
Trace,,SQL,Update [test] Set [s]=@s_0  Where [Id] = @Id_1;
<Text><30>(@s_0=3:String,@Id_1=1:Int64),
Trace,,SQL,Update [test] Set [t]=@t_0,[s]=@s_1  Where [Id] = @Id_2;
<Text><30>(@t_0=4:String,@s_1=3:String,@Id_2=1:Int64),

----------------------------------------------------------------------------
here 

 v.t = "4";
 v.Save();

should not update [s]=@s_1
Coordinator
Feb 20, 2009 at 4:01 AM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.