584
DT=, DT<>, DT>, DT<=, DT<, DT>=
(b) Even if the dates to be compared do not exist practically, this instruction executes the comparison operation for the
objects with the settable dates in accordance with the following condition.
• Date A: 2006/02/30 (This date is settable, though it does not exist.)
• Date B: 2007/03/29
• Date C: 2008/02/31 (This date is settable, though it does not exist.)
Operat
i
on
E
rror
(1) There is no operation error in the DT=, DT<>, DT>, DT<=, DT<, or DT>= instruction.
Program
E
xamp
l
e
(1) The following program compares the data stored in D0 with the data (year, month, and day) stored in D10, and makes
Y33 be conductive status when the data stored in D0 meet the data stored in D10.
[Ladder Mode]
[List Mode]
(2) The following program compares the data stored in D0 with the current date data (year and month), and makes Y33 be
conductive status when the data stored in D0 do not meet the current date data, when M0 is turned on.
[Ladder Mode]
[List Mode]
(3) The following program compares the data stored in D0 with the data (year and day) stored in D10, and makes Y33 be
conductive status when the data value stored in D10 is smaller than the data value stored in D0, when M0 is turned on.
[Ladder Mode]
[List Mode]
(4) The following program compares the data stored in D0 with the current date data (year), and makes Y33 be conductive
status when the value of the current date data is the data value stored in D0 or larger.
[Ladder Mode]
[List Mode]
Comparison
objects
Comparison condition
A<B
B<C
A<C
Day
Month
Month, day
Year
Month, day
Year, month
Year, month, day
No objects
: Conductive : No-conductive
Step
I
nstruct
i
on
De
vi
ce
Step
I
nstruct
i
on
De
vi
ce
Step
I
nstruct
i
on
De
vi
ce
Step
I
nstruct
i
on
De
vi
ce