tmusico
Member
I ran a SQL query aginst my F4311 table. I noticed that some of the data in the GL Period Number field (PDPN) seems to be incorrect.
shouldn't the PDPN field be related to the GL Date field (PDDGL) ?
for example:
PDDGL - gl date = 102146
PDPN - gl period = 8 (this should have been 5)
using this SQL Query.
(note we are using Date Pattern 'S' in the F0008)
select
(case
when pddgl <= cdd01J then 1
when pddgl <= cdd02J then 2
when pddgl <= cdd03J then 3
when pddgl <= cdd04J then 4
when pddgl <= cdd05J then 5
when pddgl <= cdd06J then 6
when pddgl <= cdd07J then 7
when pddgl <= cdd08J then 8
when pddgl <= cdd09J then 9
when pddgl <= cdd10J then 10
when pddgl <= cdd11J then 11
when pddgl <= cdd12J then 12
end) calced_PN, pdpn, cdfy calced_FY, pdfy, pddgl
from (select * from f0008 where cddtpn = 'S') as pnQ
join f4311
on pddgl >= cddfyj and pddgl <= cdd12j
shouldn't the PDPN field be related to the GL Date field (PDDGL) ?
for example:
PDDGL - gl date = 102146
PDPN - gl period = 8 (this should have been 5)
using this SQL Query.
(note we are using Date Pattern 'S' in the F0008)
select
(case
when pddgl <= cdd01J then 1
when pddgl <= cdd02J then 2
when pddgl <= cdd03J then 3
when pddgl <= cdd04J then 4
when pddgl <= cdd05J then 5
when pddgl <= cdd06J then 6
when pddgl <= cdd07J then 7
when pddgl <= cdd08J then 8
when pddgl <= cdd09J then 9
when pddgl <= cdd10J then 10
when pddgl <= cdd11J then 11
when pddgl <= cdd12J then 12
end) calced_PN, pdpn, cdfy calced_FY, pdfy, pddgl
from (select * from f0008 where cddtpn = 'S') as pnQ
join f4311
on pddgl >= cddfyj and pddgl <= cdd12j