BASE - Form Filter on Subform

Hello! Using LibreOffice Base form based filters, is it possible to search a subform in order to find the matching related records? For example, a db with two related tables: Contacts and PhoneNrs, with PhoneNrs being in the subform. I would like to use the included, on the bottom of the page form based filter, to quickly find all matching contacts having a certain area code. I can easily do this with a query, but my question is doing this with the included form filter. I was unsuccessful doing this with both HSQL embedded and using PostgreSQL. All suggestions and comments welcome! Thanks!!

Yes you can but I’m going to guess it’s not what you actually want.

Since the subform is tied to the form, it only displays records based upon the record pointed to by the form record chosen. Therefore, if form is pointing to Contact “A” your filter will reveal only those PhoneNrs records in specified area code for company “A”. It a guess that you are looking for ANY PhoneNrs with a specific area code. This would require filtering on a display of all records in PhoneNrs>

Here is a sample of filtering on a subform:

Filter to be Applied

image description

Result when filter applied:

image description

In this sample there are more records in “RPG” than the one displayed and other records contain “another” which are in different “GameCategory”'s.

Edit:

You can simply add another form to the existing one using “PhoneNrs”. Using my same example here is simple design (sorry threw together quickly):

Then using the Filter:

Produces this result:

It all depends on how you set up your “Forms” and just what you want to see.

If this answers your question please click on the :heavy_check_mark: (upper left area of answer).

Then to use a form based filter to find a phone number or number pattern matching a contact I would have to create a new form based on phone numbers with my contacts as a subform. Is this correct? It does work, however I then have two forms to work with. Otherwise the other option is to use a form that is based on a query instead of a table, correct? Thanks @Ratslinger !

Please see edited area of answer.