Jump to content

Finding in a Calc field based on a relationship


palidor

This topic is 6444 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies

Hi,

I am having a weird find issue. Basically I have a calculation field based on a relationship with the following calculation:

If( IsValid(Import_Wk3::COM_FK) ;

"Y";

"N")

I am trying to determine if a record has a related record in another table. the field is displaying correctly however when I perform a find, all of the records are returned.

Any ideas are appreciated.

-James

Link to comment
Share on other sites

A find in the main table, looking for records which have related records works fine. While true IsValid() can produce expected results (it only tests that the data is valid for the field type), it would still work only if partly. To test for related, the IsEmpty() test works better. But are you saying the calc displays N but still finds all main records when you search for Y?

Two things I might suggest: 1) What version of 8 are you using? 8.0v1 had finding issues (would produce all records on unstored calcs) or 2) If you are using a Find Request, the wrong field may be searched so you might check that. Can you manually perform the find and have it work? If not, I would suspect your version; particularly if mixing 8.0v1 with vs. 7.

Another test ... place your related key directly on the main layout and perform manual find with *. Only main records which have a related record will be displayed.

Link to comment
Share on other sites

  • Newbies

Thanks for the tips.

It is just strange that the field displays properly but does not search properly. My work around has been to run the same calculation as a replace into a text field, then search the text field.

I am running Server 8 v2. I will have to upgrade at my next maintenance window.

But you know what, my client version is Advanced 8 V1, I bet the find is run client side huh?

Link to comment
Share on other sites

It is just strange that the field displays properly but does not search properly

Am I getting thru here?? It's a Edward Said'ish way of arguing here. If you search a number field with a char is it type mismatch, which might or might not give your the results you're after.

In short what type are the result of you calc as type, if it's number is it wrong! The tool might forgivingly allow you lack of strictness in the approach, at some points, but don't expect it to happen universally ...it's quite a permutation to cover all the ways users might abuse the tool.

Let it be obvious that artifical intelligence still is pretty unapproachable and the perfect software tool never ever will be made.

--sd

Link to comment
Share on other sites

  • Newbies

Hi Soren,

Sorry, I was not responding directly to your post. I tried the calc as both a text, the way posted, and a boolean Number, without the If statement. Both calculations would display as desired but would return all records on any search of the field.

More details: The calc was unstored, had to be since it refereced a related field. And I tested with "evaluate with empty fields" on and off.

But it does look like a search bug with 8v1 Advanced. Updating to 8v3 Advanced solved the issue. That's what I get for ignoring basic troubleshooting procedure.

Thanks again,

-James

Link to comment
Share on other sites

This topic is 6444 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.