老师好:下列代码用在SQL数据库中无效,在ACC中有效,不知道怎么改?多谢!
If e.DataCol.Name = "内部订单号" OrElse e.DataCol.name = "计划加工工序" Then
Dim ls As List(of String) = DataTables("生产进度扫描表").GetValues("加工工序", "内部订单号 = '" & e.DataRow("内部订单号") & "'")
Dim str As String = ""
Dim str1 As String = ""
For Each s As String In e.DataRow("计划加工工序").split(",")
If ls.Contains(s) Then
str &= s & ","
ls.Remove(s)
Else
str1 &= s & ","
End If
Next
Dim str2 As String = String.join(",", ls.ToArray)
str &= str2
e.DataRow("已加工工序") = str.trim(",")
If e.DataRow("已加工工序") = Nothing Then
'e.DataRow("加工工序_实际增加的工序") = Nothing
e.DataRow("未加工工序") = Nothing
Else
'e.DataRow("加工工序_实际增加的工序") = str2.trim(",")
e.DataRow("未加工工序") = str1.trim(",")
End If
End If
Select Case e.DataCol.Name
Case "计划加工工序"
Dim ls11 As List(of String) = DataTables("生产进度扫描表").GetValues("工序数量描述", "内部订单号 = '" & e.DataRow("内部订单号") & "'")
Dim str11 As String = ""
Dim str111 As String = ""
Dim str211 As String = String.join(",", ls11.ToArray)
str11 &= str211
e.DataRow("进度描述") = str11.trim(",")
End Select