dleads
asked on
Convert like statement from Access QBD to SQL
Could someone please advise the syntax used in sql for this command that was in QBD in Access?
Like '[2-3]*[!0]*'
Thanks in advance!
Like '[2-3]*[!0]*'
Thanks in advance!
(( yourfield Like '2*' or yourfield Like '3*' ) and yourfield not like '*0*')
Sql use % instead of *
looks like I misread the migration products... :)
I agree with capricorn, for sql 2005, the condition looks like this:
Like '[2-3]%[!0]%'
I agree with capricorn, for sql 2005, the condition looks like this:
Like '[2-3]%[!0]%'
ASKER
I think we're close...
I'm trying to place this in the filter of a view (in the design view).
When I put this exact statement in
Like '[2-3]%[!0]%'
I get an error "Data type error in expresseion.'
I'm trying to place this in the filter of a view (in the design view).
When I put this exact statement in
Like '[2-3]%[!0]%'
I get an error "Data type error in expresseion.'
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
The problem was the numeric field - and the like statement was perfect from both of you.
Therefore I'm awarding angellll a little more on the points.
Thank you both.
Therefore I'm awarding angellll a little more on the points.
Thank you both.