Dim cmd As New SQLCommand
cmd.ConnectionName = ss
Dim dt As DataTable
Dim Cols1() As String = {"ID","TrType","InterID","EntryID","DDate","DeptID","EmpID","SupplyID"}
Dim Cols2() As String = {"ID","TrType","InterID","EntryID","DDate","DeptID","EmpID","SupplyID"}
Dim cmb As Winorm.ComboBox
MessageBox.Show("开始sql")
cmd.CommandText ="s elect" & _
"ID" & _
",{STOCK}.TranType" & _
",{STOCKM}.InterID" & _
",EntryID" & _
",{STOCK}.DDate" & _
",{STOCK}.DeptID" & _
",{STOCK}.EmpID" & _
",{STOCK}.SupplyID" & _
"From {STOCKM}" & _
"LEFT JOIN {STOCK} ON {STOCKM}.InterID = {STOCK}.InterID" & _
"WHERE {STOCK}.TranType = 2"
MessageBox.Show("结束SQL")
dt = cmd.ExecuteReader()