Page 1 of 1

Comparison date query

Posted: Wed Jan 29, 2014 11:24 am
by quokkaz
Hi,
I have the following query which works fine:
SELECT Families.

Code: Select all

, Families.[Fathers name], Families.[Mothers name], Families.[Change date], Families.[Changed]
FROM Families
WHERE  ( Families.[Change date] < JDATE('1 jan 2003') )
Order by Families.[Change date]

I would like to change the query so I don't have to change the date.  Ideally I would like it to be say ten years ago.  I tried using Dateadd(years,-10,curdate()) and other 'googled' variations without success.

Is this possible?

Re: Comparison date query

Posted: Wed Jan 29, 2014 11:46 am
by Nick Hunter
Hi,

Sorry. This sort of date comparison is not possible. Dates must be converted to julian dates in the format used internally by K&KPro and only literal dates can appear inside a JDATE() function. See Kith and Kin Pro manual - SQL Syntax