INSERT INTO int_wms_gjtc_bill
(djbh,ydjbh,dwbh,rq,thy,cgy,yzid,dj_sort,ydj_sort,spid,sl,js,lss,thyy,ph,rq_sc,yxqz,kczt,lastmodifytime,is_zx,billsn,ydj_sn,dj,hshj,shlv,je,she,hsje,qxshl,ssyjh_dwbh,erpdqrq,ZCQQSBH,ZCQZZBH)
SELECT a.djbh,a.djbh AS ydjbh,a.dwbh,a.rq,'' AS thy,'' AS cgy,'GZXS' AS yzid,b.dj_sort,b.dj_sn AS ydj_sort,b.spid,b.shl AS sl,b.baozhshl AS js,b.lingsshl AS lss,'' AS thyy
,b.pihao AS ph,b.baozhiqi AS rq_sc,b.sxrq AS yxqz,'' AS kczt,CONVERT(CHAR(19),GETDATE(),120) AS lastmodifytime,'N' AS is_zx,0 AS billsn,b.dj_sn AS ydj_sn
,0.00 AS dj,0.00 AS hshj,0.00 AS shlv,0.00 AS je,0.00 AS she,0.00 AS hsje,0 AS qxshl,'' AS ssyjh_dwbh,CONVERT(CHAR(19),GETDATE(),120) AS erpdqrq,'' AS ZCQQSBH,'' AS ZCQZZBH
FROM jzorder_hz AS a
INNER JOIN jzorder_mx AS b ON a.djbh = b.djbh
WHERE a.djbh='JHTZDA00000800'