28,404
社区成员
发帖
与我相关
我的任务
分享
Dim StrSql,StrWhere,s_type_id
s_type_id =传入值
StrWhere =""
StrSql="SELECT EMP_CODE, EMP_NAME,time_beg,time_end,chk_days,chk_hour,type_id,remark
FROM dbo.mt_vacation,dbo.mt_personms
WHERE dbo.mt_vacation.empindex=dbo.mt_personms.empindex and EMP_CODE = 'MMColParam'"
If not s_type_id="" Then
StrWhere=" and type_id="&s_type_id&""
End IF
StrSql =StrSql+StrWhere