sql = "select SOHOLDHD.DocuID,SOHOLDHD.DocuNo, SOHOLDHD.DocuDate ,SOHOLDHD.TableNo ,SOHOLDHD.EmpID , SOHOLDHD.GuestQty, SOHOLDHD.Ordertype, SOHOLDHD.Status, SOHOLDHD.ToTalAmnt, SOHOLDHD.Brchid, SOHOLDHD.Remark, SOHOLDHD.Vate, SOHOLDHD.BeforVate, SOHOLDDT.Goodid,EMGood.GoodNameT, SOHOLDDT.ListNo, SOHOLDDT.GoodQty,SOHOLDDT.GoodQty1, SOHOLDDT.Remark, SOHOLDDT.Status, SOHOLDDT.GoodPrice, SOHOLDDT.GoodAmnt, SOHOLDDT.GoodAmnt1,SOHOLDDT.Flag,SOHOLDDT.GoodPrice1 from SOHOLDHD left outer join SOHOLDDT on SOHOLDDT.DocuID = SOHOLDHD.DocuID left outer join EMGood on EMGood.goodid = SOHOLDDT.goodid WHERE SOHOLDHD.TableNo = 'a11'"
Dim dts As DataTable = cmd_datatable()
For i = 0 To cmd_datatable.rows.count - 1
Dim add(2) As String
add(0) = dts.Rows(i)("DocuID") "ไม่เอาหนัง"
add(1) = dts.Rows(i)("GoodNameT")
Dim itm As New ListViewItem(add)
Listview2.Items.Add(itm)