Here is my Data Tables
tbl_PURCHASE
branch_ID
PO_ID
Supplier_ID
Order_Date
Item_No
Item_Price
Item_Quantity
Modified_Date
Modified_By
tbl_SUPPLIER
Supplier_ID
Supplier_Name
when i click to search the PO_ID then
Fill in Four Text fields with
branch_ID , PO_ID, Supplier_ID, Supplier_Name
and then
in the DataGrid display
Order_Date, Item_No, Item_Price, Item_Quantity
i think i have to set the table ... but i dun know how to set it !!!
But it is not work at ALL ...
i had tired the INNER JOIN ... but i'm sure that i totally dun know how to user INNER JOIN !!
PLEASE HELP ME !!!!!!!!!!!!!
tbl_PURCHASE
branch_ID
PO_ID
Supplier_ID
Order_Date
Item_No
Item_Price
Item_Quantity
Modified_Date
Modified_By
tbl_SUPPLIER
Supplier_ID
Supplier_Name
when i click to search the PO_ID then
Fill in Four Text fields with
branch_ID , PO_ID, Supplier_ID, Supplier_Name
and then
in the DataGrid display
Order_Date, Item_No, Item_Price, Item_Quantity
i think i have to set the table ... but i dun know how to set it !!!
VB.NET:
Private Sub GetUserDetails()
objDS.Clear()
objDS = objUser.Search_tblUser("Select p.Order_Date, p.Item_No, p.Item_Price, p.Item_Quantity, s.Supplier_Name from tbl_PURCHASE p, tbl_SUPPLIER s where p.SUPPLIER_ID = s.SUPPLIER_ID and p.PO_ID = '" & txtPOID.Text & "'")
Try
dgPOrderItems.DataSource = objDS.Tables(0)
If objDS.Tables(0).Rows.Count > 0 Then
With objDS.Tables(0)
txtPOBranchID.Text = objFormat.FormatString(.Rows(0).Item("Branch_ID"))
txtPOID.Text = objFormat.FormatString(.Rows(0).Item("PO_ID"))
txtPOSupplierID.Text = objFormat.FormatString(.Rows(0).Item("Supplier_ID"))
txtPOsuppliername.Text = objFormat.FormatString(.Rows(0).Item("s.Supplier_Name"))
End With
End If
Catch ex As Exception
End Try
End Sub
But it is not work at ALL ...
i had tired the INNER JOIN ... but i'm sure that i totally dun know how to user INNER JOIN !!
PLEASE HELP ME !!!!!!!!!!!!!