Steven Cappiello Posted October 23, 2004 Posted October 23, 2004 I have table that has a self-join.. The relationship is working fine.. I can show the related values I'm interested in in a portal... but I'd rather not. I'd rather just show a message to my user saying "there are related records for this record" using a merge field or something like that. Is there a way I can achieve that ? seems like it should be pretty simple.. ?? thanks
MarkWilson Posted October 23, 2004 Posted October 23, 2004 Case( Count( SelfJoin::KeyField ) > 1 ; "There are related records for this record." )
-Queue- Posted October 23, 2004 Posted October 23, 2004 not IsEmpty(relationship::key) will be faster than a Count.
MoonShadow Posted October 23, 2004 Posted October 23, 2004 Hi JT, I agree it would be faster; however, since this is a self-join, won't it always display as valid because it will find itself? I would assume a count is necessary to specify more than one!? I question it because I've been tripped on this one before.
Steven Cappiello Posted October 23, 2004 Author Posted October 23, 2004 Thanks ! actually, my relationship has 2 elements.. the self-join and a Not equal to itself component, so the not(isempty) route is better.. it works great ! jeez.. relationships used to really scare me but I think i'm starting to "get it" thanks for the help
Recommended Posts
This topic is 7670 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now