Board index » delphi » Selection in sum of ranges - SQL

Selection in sum of ranges - SQL

How can I do a selection in SQL for a sum of ranges, like in example:

SELECT *
FROM table
WHERE  (field BETWEEN a AND b) OR (field BETWEEN c OR d)

When I try like this I have an error message.

If it has any meaning - I use paradox tables

--
Z pozdrowieniami

Piotr Stok3osa
gos...@polbox.com

 

Re:Selection in sum of ranges - SQL


Quote
>SELECT *
>FROM table
>WHERE  (field BETWEEN a AND b) OR (field BETWEEN c OR d)

                                                                       take the
"or" out of here ^  
Replace with "and"

********************************
Michael Glatz
glatzfa...@aol.com
mgl...@briefcase.com

Other Threads