Recordset query
lancekmc | Posted 6:21am 5. March 2009 Server Time |
i have a table from which i have created a query to pick out the info i need and with the max date i.e most recent date against the particular record, and am trying to do this from an SQL statement in VBA looks something like this
strCriteria = "SELECT * FROM qryMaxLabDate_Result WHERE qryMaxLabDate_Result.clinic_code= " _
& "'" & [Forms]![frmMainForm]![txtSelectClinic] & "'" & " AND " _
& " qryMaxLabDate_Result.chart_number='" & [Forms]![frmMainForm]![lstSelectPatient] & ""
is that how to refere to fields in the query and how to i get to define the max date to be picked. |