求助,查询判断列都是FALSE结果
Dim Conn As New ADODB.Connection
Set Conn=CurrentProject.Connection
Dim Rst As New ADODB.Recordset
Dim strCriteria As String
Rst.Open "订单 ",Conn,adOpenKeyset,abLockOptimistic
strCriteria= "[机号]= ' " & ME![Combo0] & " ' "
If RST( "订单配置 ")= True Then
me.BOM子窗体.Locked=Ttue
Exit IF
ELSE
me.BOM子窗体.Locked=Ttue
EXIT IF
END IF
订单配置字段是判断列,当订单配置是真或是假时,怎么IF RST( "订单配置 ")= True THEN 判断都是FALSE
另,查询时怎样把字符的前或后空格去掉
求助各位高手帮我看看,在此谢谢各位了
------解决方案----------------------1、
Dim Conn As New ADODB.Connection
Set Conn = CurrentProject.Connection
Dim Rst As New ADODB.Recordset
Dim strCriteria As String
Rst.Open "select * from 订单 where [机号]= ' " & Me![Combo0] & " ' ", Conn, adOpenKeyset, abLockOptimistic
If Rst( "订单配置 ") = True Then
Me.BOM子窗体.Locked = Ttue
Exit Sub
Else
Me.BOM子窗体.Locked = Ttue
Exit Sub
End If
--2、
--去掉前后的空格
select trim( " abc ")
--去掉左边的空格
select ltrim( " abc ")
--去掉右边的空格
select rtrim( " abc ")
------解决方案----------------------Access2003
update NMS set Name=replace([name], ' ', ' ')
------解决方案--------------------Access2003
update tt set f1=replace(f1, ' ', ' ')