Hi,
I have a formula in my detail report called LateComplete. I use this formula to insert a summary in my Group header. Report is based on two tables - LOG table and COMMENTS table. Each record can have no comments, one or more comments associated with it. What is happening right now is that if a record has 2 comments associated with it, that record is counted twice. This is my original formula
To fix this problem I modified the formula by using COMMENT_SEQUENCE. Each time A COMMENT is added for a record in a table it is assigned sequence 1 and so on. As I have a left outer join on comments table, if there are no comments for a record it displays null under comments for that record.
Now it does not count the record twice but it is skipping all those records where comment is null. How should I make it count the records that have no comments associated with it.
Thanks,
Ekta
I have a formula in my detail report called LateComplete. I use this formula to insert a summary in my Group header. Report is based on two tables - LOG table and COMMENTS table. Each record can have no comments, one or more comments associated with it. What is happening right now is that if a record has 2 comments associated with it, that record is counted twice. This is my original formula
Code:
If ({LOG.COMPLETION_STATUS}) = "X" AND Date({LOG.END_DATE_TIME}) > {LOG.LATEST_DATE} AND
({LOG.MAINT_ACTION_CODE}) = "P"
then
({LOG.NO_TASKS})
To fix this problem I modified the formula by using COMMENT_SEQUENCE. Each time A COMMENT is added for a record in a table it is assigned sequence 1 and so on. As I have a left outer join on comments table, if there are no comments for a record it displays null under comments for that record.
Code:
If ({LOG.COMPLETION_STATUS}) = "X" AND Date({LOG.END_DATE_TIME}) > {LOG.LATEST_DATE} AND
({LOG.MAINT_ACTION_CODE}) = "P"
[b]AND (isNull({COMMENTS.COMMENT_SEQUENCE}) OR {COMMENTS.COMMENT_SEQUENCE} = 1)[/b]
then
({LOG.NO_TASKS})
Now it does not count the record twice but it is skipping all those records where comment is null. How should I make it count the records that have no comments associated with it.
Thanks,
Ekta