This topic is locked
[SOLVED]

How to create a search function in a "detail table" ?

8/27/2021 8:01:54 AM
PHPRunner General questions
I
I author

I have created a master-detail relationship. The master table is the table of the associations. The detail table is the table of the members. But I would like to create a search function in the detail table, so that I can look up each member by name, for example. Is this possible ? How can I do that? Thanks.

fhumanes 8/28/2021

Hello there:

As far as I know, you can only do the search in the fields in the "Master" table, but you could upload the "Detail" record information to the "Master" table using:

select
`vide_rel_pelicula_tema`.`vide_pelicula_idvide_pelicula` AS `vide_pelicula_idvide_pelicula`,
cast(group_concat(`vide_rel_pelicula_tema`.`vide_cata_tema_idvide_cata_tema`
order by `vide_rel_pelicula_tema`.`vide_cata_tema_idvide_cata_tema`
ASC separator ',') as char charset utf8) AS `vide_cata_tema_idvide_cata_tema`
from `vide_rel_pelicula_tema`
group by `vide_rel_pelicula_tema`.`vide_pelicula_idvide_pelicula`

The field resulting, should only enter the general search.

Greetings,
Fernando.

I
I author 8/28/2021

Thanks for your information !