1.11M Members

Help me

 
0
 

SELECT * FROM users WHERE birth_date between '%-02-02' AND '%-05-06'

 
0
 

not working

 
0
 

Assuming MySQL, see the docs here. BETWEEN requires a minimum and maximum value, and does not support a wildcard like LIKE does.

 
0
 

Same goes for MSSQL. If you include the character string '%', MSSQL will generate an error.

You
This article has been dead for over six months: Start a new discussion instead
Post:
Start New Discussion
View similar articles that have also been tagged: