From a45d46d28541e31bba13c33d30be28439d224da9 Mon Sep 17 00:00:00 2001 From: chenwenkai <1084072318@qq.com> Date: Fri, 10 Jan 2025 10:55:17 +0800 Subject: [PATCH] =?UTF-8?q?temu=E6=88=90=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- TradeManageNew/DataNew.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/TradeManageNew/DataNew.cs b/TradeManageNew/DataNew.cs index 0dbaa67..1977aa0 100644 --- a/TradeManageNew/DataNew.cs +++ b/TradeManageNew/DataNew.cs @@ -30614,10 +30614,10 @@ select @id"; try { string tsql = @" -SELECT a.[ID],a.[GoodsId],c.GoodsCode,[JinJia],[YunFei],[TouCheng],[HuoWuShuiFei],[YuGuJiaGe],[CreateUserId],[CreateTime] - FROM [newerpbak_cwk].[dbo].[TemuChengBen] a +SELECT top 1 a.[ID],a.[GoodsId],c.GoodsCode,[JinJia],[YunFei],[TouCheng],[HuoWuShuiFei],[YuGuJiaGe],[CreateUserId],[CreateTime] + FROM [dbo].[TemuChengBen] a inner join HW_GoodsInfo c on a.GoodsId=c.GoodsId -where a.GoodsId = @GoodsId "; +where a.GoodsId = @GoodsId order by a.CreateTime desc"; Database db = DatabaseFactory.CreateDatabase(); DbCommand cmd = db.GetSqlStringCommand(tsql); db.AddInParameter(cmd, "@GoodsId", DbType.Int32, GoodsId);