I have an invoice table with the fields number, date and a table details with the fields numerofactura have their foreign key and the whole thing. I WANT TO OBTAIN ALL THE DETAILS OF THE INVOICES IN A RANGE OF DATES AND I AM SENDING YOU THIS QUERY:
SELECT factura.Numero FROM factura INNER JOIN detalles
ON factura.Numero=detalles.NumeroFactura
AND factura.Fecha BETWEEN '2018-08-17' AND '2018-08-18'
BUT IT RETURNS ME NULL. DOES SOMEBODY KNOW HOW TO SOUL?