In article <1124336279.001074.145850 (AT) g43g2000cwa (DOT) googlegroups.com>,
squeed2000 (AT) yahoo (DOT) com says...
Quote:
I have a portal that is showing SELF::SELF related records. I want to
create a simple sort off of a calculation that shows the status of the
record as "Active" or "Complete".
For some reason the relationship isn't working. Can you create a
relationship where one of the fields is a calculation ? |
Sure. On the parent side this is no problem. On the child side it must
be stored and indexed to work properly. This is likely your issue, based
on what you say below.
Quote:
If not, how can I have a simple sort in a portal where the records that
are either Active or Complete are shown.
Keep in mind that the status of the records may switch from Active to
Complete. So I can't store the data it has to be an on the fly
calculation. |
Generally if something is complete it doesn't change any more... forever
on-the-fly-calculating that its 'complete' seems silly.
If something is active, and it becomes complete a user generally has to
have done something. IF that's the case then the script that handles the
user doing something can also mark it complete.
This is how many Accounting solutions are done. When the record moves
from open to closed, in response to the accounting running a "post" or
"post batch" type function, the 'status' field of the record(s) is
changed from open to closed.
Alternatively, it could be done as a stored calculation:
an if date(posted="","open","closed") sort of thing, but it has to be
stored and indexed, not unstored, if you want to use it on the child
side of a relationship.