Created
March 5, 2016 11:01
-
-
Save k-maru/30e7587f6bde7d4900b6 to your computer and use it in GitHub Desktop.
from and to parameter range sql
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
( | |
1 = CASE WHEN :ValueFrom /*Number*/ IS NULL THEN 1 | |
WHEN ColumnName >= :ValueFrom/*Number*/ THEN 1 | |
ELSE NULL END | |
AND | |
1 = CASE WHEN :ValueTo/*Number*/ IS NULL THEN 1 | |
WHEN ColumnName <= :ValueTo/*Number*/ THEN 1 | |
ELSE NULL END | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment