lonesomejubilee Posted January 6, 2005 Posted January 6, 2005 Hi, I have a question about portals. I have a portal that looks up an employee's information from one table based on an employeeID. But what if that ID does not exist? Is there anyway to make it return a message instead of just being blank? Vandy
Lee Smith Posted January 6, 2005 Posted January 6, 2005 This may be the long way around, AND the way I would do it in V6, but create a new calculation in your file and use your current Relationship and this calculation Case(IsValid(YourRelationship::YourFieldHer)=0, "There is no relationship for this file", "") HTH Lee
-Queue- Posted January 10, 2005 Posted January 10, 2005 Better to use IsEmpty since IsValid has more meanings than simply 'related records do not exist.' It seems that Lee is using it to test whether the related file can currently be found, which is proper usage. But the question appears to ask for whether a related record exists. Case( IsEmpty(YourRelationship::ID); "There is no related ID."; YourRelationship::YourField )
Lee Smith Posted January 11, 2005 Posted January 11, 2005 Hi JT, welcome back. You are correct that was what I was doing. However, I agree that the IsEmpty is a better function to use here. Thanks for correcting me. Lee
Recommended Posts
This topic is 7413 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