Public Sub GET_DERN_VERS(NO_POLICE As String)
Dim RECSET As New ADODB.Recordset
RECSET.Open "select abs(ev.mt_brut_cie) as Dernier_versement from db_evenement ev, dp_classe_evt classe" & _
"where ev.no_police = '" & NO_POLICE & "' and classe.b_ea =1 and classe.b_rachat = 1 and ev.is_classe_evt=classe.is_classe_evt" & _
"having distinct(count(ev.d_effet))<> 1 and max(datepart(ev.d_effet))=datepart(ev.d_effet)", cnn_Pegase, adOpenDynamic, adLockBatchOptimistic