sql="select..."if name<>"" then sql=sql & " where user='" & name & "'" end if
dim strsql as string dim tmp_name as stringif trim(name)="" then tmp_name="" else tmp_name=" and [user]='"& trim(name) &"'" end ifstrsql=" select * from tablename where 1=1 " & tmp_name
sql=sql & " where user='" & name & "'"
end if
dim tmp_name as stringif trim(name)="" then
tmp_name=""
else
tmp_name=" and [user]='"& trim(name) &"'"
end ifstrsql=" select * from tablename where 1=1 " & tmp_name