Login表
czyName,czyBmDkInfo表
LastJxDate ,YeMonwy,BeginDate,Lrczy,ShenHeCkInfo表
LastJxDate ,YeMonwy,BeginDate,Lrczy,ShenHehkjhMan表
b.h_dh ,h_LxMoney,b.h_Money,b.h_hkQk,h_date
czyName,czyBmDkInfo表
LastJxDate ,YeMonwy,BeginDate,Lrczy,ShenHeCkInfo表
LastJxDate ,YeMonwy,BeginDate,Lrczy,ShenHehkjhMan表
b.h_dh ,h_LxMoney,b.h_Money,b.h_hkQk,h_date
解决方案 »
- 求SQL得改写
- 这么多'''''''怎么理解?
- 存储过程如何保存DATASET里面的表(datatable)
- 如何用sql语句手动在sqlserver2008中插入时间类型的具体时间,比如要插入:2008-09-24 6:10:00
- 求解SQL语句中where的条件写法
- 在一个SQL里面怎么求该学生在班级各科成绩的排名
- 救命呀,求SQL差值语句,在线等!!!
- 关于SQL链接的错误,急在线等,连接本地SQL,,使用域名解析, ,,错误说是“无效的连接”
- 关于sql server的问题
- 我使用SQL Server 2000 时遇到的一个问题?
- 求教几行关于SQL的代码,很简单,我是初学者有点不太懂!
- 求存储过程!!
czyName,czyBmDkInfo表
Pzh, LastJxDate ,YeMonwy,BeginDate,Lrczy,ShenHeCkInfo表
Pzh, LastJxDate ,YeMonwy,BeginDate,Lrczy,ShenHehkjhMan表
h_dh ,h_LxMoney,h_Money,b.h_hkQk,h_date
WITH ENCRYPTION
AS
Declare @Date Datetime,@cou1 int,@cou2 intSet @Date=Convert(Varchar(10),GetDate(),120)select @Cou1=Count(*) from CkInfo a inner join Login b on a.Lrczy=b.CzyName where b.czyBm=@Bm and ShenHe=1 and
day(@Date)<>LastJxDate and YeMoney>0 and
(BeginDate+4<GetDate() and day(BeginDate)=day(@Date))select @Cou2=Count(A.id) from DkInfo a,hkjhMan b inner join Login c on a.Lrczy=c.CzyName Where c.czyBm=@Bm and
a.pzh=b.h_dh and a.YeMoney>0 and a.ShenHe=1 and (b.h_LxMoney>0 or b.h_Money>0) and b.h_hkQk='未还款'
and b.h_date between @Date and Convert(Varchar(10),GetDate()+3,120)Select @cou1 As JtLxc,@cou2 As StLxc
WITH ENCRYPTION
AS
Declare @Date Datetime,@cou1 int,@cou2 intSet @Date=Convert(Varchar(10),GetDate(),120)select @Cou1=Count(*) from CkInfo a inner join Login b on a.Lrczy=b.CzyName where b.czyBm=@Bm and ShenHe=1 and
day(@Date)<>LastJxDate and YeMoney>0 and
(BeginDate+4<GetDate() and day(BeginDate)=day(@Date))select @Cou2=Count(A.id) from DkInfo a,hkjhMan b,Login c
Where a.Lrczy=c.CzyName and c.czyBm=@Bm and
a.pzh=b.h_dh and a.YeMoney>0 and a.ShenHe=1 and (b.h_LxMoney>0 or b.h_Money>0) and b.h_hkQk='未还款'
and b.h_date between @Date and Convert(Varchar(10),GetDate()+3,120)Select @cou1 As JtLxc,@cou2 As StLxc
CREATE PROCEDURE Cx_indexJl @TxTs int,@Bm Nvarchar(20) WITH ENCRYPTION
ASDeclare @cou1 int
select @Cou1=Count(*) from CkInfo a inner join Login b on a.Lrczy=b.CzyName where b.czyBm=@Bm and ShenHe=1
Select @cou1 As JtLxc简化成这样了,还是有报错:列名 'czyBm' 无效。