diff --git a/Src/Asp.Net/DmTest/Demo/Demo7_Ado.cs b/Src/Asp.Net/DmTest/Demo/Demo7_Ado.cs index 84278dd58..34af1a80f 100644 --- a/Src/Asp.Net/DmTest/Demo/Demo7_Ado.cs +++ b/Src/Asp.Net/DmTest/Demo/Demo7_Ado.cs @@ -49,7 +49,7 @@ namespace OrmTest //There are many methods to under db.ado var list= db.Ado.SqlQuery("select * from \"ORDER\" "); var intValue=db.Ado.SqlQuerySingle("select 1"); - db.Ado.ExecuteCommand("delete from \"ORDER\" where id>1000"); + db.Ado.ExecuteCommand("delete from \"ORDER\" where id>@order",new { order=1}); //db.Ado.xxx Console.WriteLine("#### Ado End ####"); } diff --git a/Src/Asp.Net/OracleTest/Demo/Demo7_Ado.cs b/Src/Asp.Net/OracleTest/Demo/Demo7_Ado.cs index f9a074f2c..bade61831 100644 --- a/Src/Asp.Net/OracleTest/Demo/Demo7_Ado.cs +++ b/Src/Asp.Net/OracleTest/Demo/Demo7_Ado.cs @@ -50,7 +50,7 @@ namespace OrmTest //There are many methods to under db.ado var list= db.Ado.SqlQuery("select * from \"ORDER\""); var intValue=db.Ado.SqlQuerySingle("select 1 from dual"); - db.Ado.ExecuteCommand("delete \"ORDER\" where id>1000"); + db.Ado.ExecuteCommand("delete \"ORDER\" where id>@type",new { type=1}); //db.Ado.xxx Console.WriteLine("#### Ado End ####"); }