--INSERT INTO SELECT FROM INSERT INTO BoxInfo(BoxNo,ItemNo,ItemNoOld,ItemName,ItemSpec) SELECT A.BoxNo,A.ItemNo,B.ItemNoOld,A.ItemName,A.ItemSpec FROM BoxTrans A,BasItemInfo B WHERE A.ItemNo=B.ItemNo AND A.BoxNo NOT IN (SELECT BoxNo FROM BoxInfo) AND A.BoxNo<>''