Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

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

Recommended Posts

Posted

I swear I used to be able to find items in a related field in a portal. Now, I go into Find mode, put an asterisk in a field, and the result is very frustrating -- it says there are no matching records.

Am I doing something different? I don't think so.

Could it be that certain types of relationships work and others don't?

P.S. This problem occurs in both v5 and v6.

Posted

Is the field in the portal a number field, a date field or a calculation resulting in a number or a date? I was able to perform a find in a portal with a asterisk in a text field, but it did not work on a number or date field.

Posted

It's an ordinary text field in the related file; it doesn't even have an auto-enter. Nor is it a field used to determine the relationship -- although the records in the related file are related to the main file in several different ways.

Posted

Hi Dan,

There should be no difficulty searching within portals, though I find I more often need to search for blank records with = than non-blank records with an * on its own. However I've just tried it again here and it is working in several very differently set up databases on v4, v5 and v5.5. I've also tried it on fields which (in the related file) are unindexed, and that is working too.

As slstrother says, an asterisk search doesn't work on a number or date field (though other portal searches do) but the initial error message returned is one about the field being defined to contain numeric/date values rather than 'no matching records'.

The only case where I got a 'no matching records' result when searching in a portal with an asterisk just now was when I searched in a field that was in fact empty.

It seems that there may be something amiss with your relationships, your data or with the files. If all else fails, maybe you might think about running a recover in case there is a corrupted index?!

Will be of interest to hear what the problem is if you are able to pinpoint it.

Cheers,

Posted

Figured out the rest of the diagnosis:

In the child file, there are four pertinent fields; call 'em "ID", "Category" and "Data" and "RelationshipField".

In the parent file, there is a relationship based on ID -- finds in this portal work just fine.

There are also relationships based on a concatenation of ID and Category, the field in the parent file equaling ID-space-Category, relating to RelationshipField in the child file, so that "ID" and "Category" are parsed out in the child file.

It is in the portals for these relationships that finds don't work -- even though I'm searching on the "Data" field which is simply a text field (text is entered via a portal in the parent file).

OK, that's the whole problem, except that, in order to do what I need, I can't separate the child file into separate files (primarily because I need to show the complete "ID::ID" relationship).

Oy vey.

Any ideas?

Posted

OK, Dan, you have two relationships between parent and child - childID and childIDcategory.

The portal you are searching in is based on the childIDcategory relationship

Just a wild guess, but is it possible that the particular field you are getting a 'no matching records' error on when you search on an asterisk is placed in the childIDcategory portal, but is in fact a "childID::field" field?

That would do it...

Posted

In the moment you enter the find mode this (calculated) relationship won't work anymore until you reactivate it by yourself (via script for ex).

So since find in portal returns parent records whose children records satisfy the criteria imposed it is clear that in case of not valid relationship the resulting set would be empty.

Dj

Posted

But your right key is not calculated (if I remember well) so you'll need to create an aux relationship (if you realy want to use find in portal) by creating "extended" rightkey ???

newRightKey=rightkey & "

Posted

In the moment you enter the find mode this (calculated) relationship won't work anymore

Interesting point, and a good pick-up, Dj!!

I note, however, that this is only true if the calculation is unstored. If the calculation is stored it will still work.

It's not clear from Dan's description of the structure whether ID and Category are both data fields within the parent file, but if they are, then the RelationshipField concatenation calculation should be able to be made a stored calc and then the portal search will work.

If either of the ID and Category fields are sourced from another file then another solution (probably involving a script etc) will be necessary...

Posted

LeftKey, RightKey -- calculations???? What are you talking about?

And what do you mean the relationship won't work? It works! I can add data and it works perfectly. It's just the find that won't work.

Posted

Cobalt, you nailed it!

The calc to determine the Parent end of the relationship was unstored; by storing & indexing it the find works great.

Thanx muchly to all for your help.

This topic is 8124 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.