命令窗口执行:
For Each nm As String In DataTables("销售记录").GetUniqueValues("","员工")
Dim drs As List(of DataRow) = DataTables("销售记录").Select("员工 = '" & nm & "'")
If drs.count > =3 Then
For i As Integer = 0 To drs.count - 3
If drs(i)("销售收入") >= drs(i)("定额") AndAlso drs(i+1)("销售收入") >= drs(i+1)("定额") AndAlso drs(i+2)("销售收入") >= drs(i+2)("定额") Then
output.show(nm & ":" & drs(i)("所属时期") & "-" & drs(i+2)("所属时期"))
End If
Next
End If
Next