Nested tables in TeeGrid

TeeGrid VCL / FMX for Embarcadero RAD Studio, Delphi, C++ Builder and Lazarus Free Pascal.
Post Reply
pawko
Newbie
Newbie
Posts: 5
Joined: Mon Jul 28, 2025 12:00 am

Nested tables in TeeGrid

Post by pawko » Mon Aug 11, 2025 7:33 am

Hello,
I looked at code in database demos - Master Detail Expander. It is working very good, but it is only master-detail relation.
I tried to expand it for third level, but I couldn't do it.

So I don't know, how to implement next level of details (subdetails) - as shown in the picture:
Image

I would be very grateful if someone can write me ('step by step' or by showing of code/link to an example) how to obtain master-detail-subdetail effect in a TeeGrid. (How deep can we nest data?)

Tkank you in advance for any help, tips, hints...

Greetings for all,
Pawel
PS. I use Delphi (11/12) and Lazarus (2.2.6 and higher), so if this funcionality is not available for some IDE, please write me also.
(sorry for my english)

Marc
Site Admin
Site Admin
Posts: 1339
Joined: Thu Oct 16, 2003 4:00 am
Location: Girona
Contact:

Re: Nested tables in TeeGrid

Post by Marc » Tue Aug 12, 2025 10:09 am

Hello Pawel,

That should be possible, we don't have an example of it but will look to see if we can create one.

Regards,
Marc Meumann
Steema Support

pawko
Newbie
Newbie
Posts: 5
Joined: Mon Jul 28, 2025 12:00 am

Re: Nested tables in TeeGrid

Post by pawko » Tue Aug 12, 2025 11:02 am

Hello Marc,

Thank you for response and your will to help.
I will be waiting patiently.

Regards,
Pawel

David Berneda
Site Admin
Site Admin
Posts: 84
Joined: Wed Nov 12, 2003 5:00 am
Location: Girona, Catalonia
Contact:

Re: Nested tables in TeeGrid

Post by David Berneda » Thu Aug 14, 2025 6:25 pm

Hi Pawel

We've updated the FireDAC Master-Detail demo to support another sub-level grid (Customers -> Orders -> Order Details) and a readme file with some explanations:

https://github.com/Steema/TeeGrid-VCL-F ... il_FireDAC

Using FireDAC there is no easy way to make this totally automatic, so you need to provide the code that returns the appropiate detail rows from the database.

There is another example of sub-sub-sub grid levels using TeeGrid and the free opensource TeeBI library (this is a read-only in-memory database), which does the sub-detail more automatic:

https://github.com/Steema/TeeGrid-VCL-F ... /VCL/TeeBI

regards !
david

pawko
Newbie
Newbie
Posts: 5
Joined: Mon Jul 28, 2025 12:00 am

Re: Nested tables in TeeGrid

Post by pawko » Fri Aug 15, 2025 11:10 am

Hi David,

Thank you very much for help and sent links to examples.
Now I can start to analyze the code of this examples and go further in my work, I hope :).

Best wishes for You and the whole Steema Team.

Regards,
Pawel

Post Reply