0

i have two dates:

@dateini @dateend

and i want to filter by two dates.

ID | NAME | DATE INI   | DATE FIN
1  | A    | 1/03/2019  | 31/03/2019   
2  | B    | 1/03/2019  | 3/05/2019

If i put 1/03/2019 - 31/03/2019 or 9/03/2019 - 31/03/2019

ID | NAME | DATE INI   | DATE FIN
1  | A    | 1/03/2019  | 31/03/2019

((@dateini <= Date2 and Date1 <= @dateini) AND (@dateend>= Date1 and Date2 >= @dateend))

thats my query but I want to know how to show it when it only includes the first date 31/03/2019 - 15/05/2019

ID | NAME | DATE INI   | DATE FIN
1  | A    | 1/03/2019  | 31/03/2019

Thx

0 Answers0