I have loaded a table into a DBGrid control, and I want
to be able to click on a particular selection from the
fldOrderID column and when that selection is made a second
DBGrid populates with a table containing a tblOrderDetail table with matching fldOrderID that was selected in first grid
Heres what I have tried

I made a button
Private Sub Command1_Click()
datOrderDetail.RecordSource = "SELECT * FROM tblOrderDetail " & _
" WHERE fldOrderID = " & _
dbgOrderMaster.Columns(0).Value
datOrderDetail.Refresh
End Sub

the second DBGrid dbgOrderDetail only show the field headers from the table tblOrderDetail and shows no records
I tried variations of the select like

datOrderDetail.RecordSource = "SELECT * FROM tblOrderDetail " & _
" WHERE fldOrderID = " & _
dbgOrderMaster.Columns("fldOrderID").Value


Same results

What event would I put a working select into to make the
second Grid show info when a selection in the fldOrderID
was made in the first Grid?


The first Grid Is successfully populated with this
datOrderMaster.RecordSource = "Select * from tblOrderMaster where fldCustomerID like " & "'*" & glngCustomerID & "*'"