Topic: Report with two different independend tables

Hi there,

i have a little problem, hoping someone can help me.

I have two different tables (horses and riders). I also have two tablegrids on the main form where on one i can select the rider, and the horse in the other.
Now i would like to fill out a fomular with the reportgenerator which should fill out the dependent fields with the selected rider and horse.
No Problem with just 1 table - but the second table (horses) - no idea yet.

Can anybody give me a hint to solve this problem?

Thank you very much.

Frank

Re: Report with two different independend tables

Hi Frank,
Can you attach your project (delete the .exe file and zip it up the rest).
It helps to understand your problem and avoid any suggestions that might not be relevant;  it also means that others might see different ways of tackling your issue that might prove helpful.
Derek.

3 (edited by Grete 2023-02-28 13:54:57)

Re: Report with two different independend tables

Hi Derek,

yes of course. Thank's a lot for helping me.

smile

When you open the Report, you will see two columns.. One named "Angaben zum Teilnehmer"(Rider) and "Angaben zum Pferd"(Horse). This both columns i want to fill with the to different tables.

Post's attachments

Attachment icon sqlite.zip 1.34 mb, 144 downloads since 2023-02-28 

Re: Report with two different independend tables

Hi Frank,
I find it surprising that there is no relationship between the 'Reiter' and the 'Pferde' tables - I would have thought that the NennungsFormular itself was the de-facto link between the two tables.
It is the absence of this link that is causing you the problem with the report. 
Also, when I looked at the layout of the WBO NennungsFormular, it shows that it is possible to nominate 2 horses for each rider - this makes me believe even more that there needs to be a relationship between 'Reiter' and 'Pferde' in your data schema.
Anyway, on the assumption that there IS NO relationship and that's the way you want it, you can either
1. add an additional dataset (in this case 'Pferde') to the report  or
2. add a new table in your data schema (I've called it 'Nennungsformular - very imaginative!!) and temporarily link ''Reiter' and 'Pferde'.
Both options require a script which depends on your level of familiarity with MVD. 
My preference is 2) as the script is more straightforward.  I also think Option2 gives you the ability to specify a second horse per rider on the Nennungsformular quite easily.
Option 1 is attached in this post and option 2 in the next post (they are too large to zip together).
Ruf' mal aus wenn etwas nicht klar ist.
Derek.

Post's attachments

Attachment icon sqlite fixed1.zip 1.34 mb, 180 downloads since 2023-02-28 

Re: Report with two different independend tables

Hi Frank,
And here's the second attachment.
Regards,
Derek.

Post's attachments

Attachment icon sqlite fixed2.zip 1.34 mb, 192 downloads since 2023-02-28 

Re: Report with two different independend tables

Hi Derek,

That's exactly what i needed.. Thank you soooo much smile

Regards
Frank