AnsweredAssumed Answered

SQL Between

Question asked by PSI on Jan 22, 2016
Latest reply on Jan 26, 2016 by disabled_morkus

I am having trouble getting BETWEEN to work.

 

Here is an example of the way I am trying it...SalesReportPL is a FileMaker table

Let (
[
~SD = Date ( 1 ; 1 ; Year ( Get ( CurrentDate ))) ;
~ED =Date (  Month ( Get ( CurrentDate )) + 1 ; 0  ; Year ( Get ( CurrentDate )))
];


ExecuteSQL (

"SELECT InvoiceNbr
FROM SalesReportPL
WHERE SaleDate BETWEEN ? and ? " ; "" ; "" ; ~SD  ;  ~ED  ))

 

I get a zero even though there are sale dates between those dates. I've tried hard coding the dates.

 

John

Outcomes