I have a table where the users may enter names in upper and/or lowercase. I could have, for example, NAME1 equal to 'ABEL MARY' and NAME2 equal to 'deBlank John'. The query in the code does the following:
select count(*) from table
where upper(name) >= :NAME1
and upper(name) <= :NAME2
but that is obviously resulting in a restricted data set and it does not covers the lowercase names. Considering that the user may type either NAME1 and/or NAME2 with upper or lowercases, how would it be the best way to cover all the data range in the table?