Tronics... thanks for your posts and your analysis.
Yes, I agree that we should do a better job with the metacontrol codegen templates for QListBox in that it should try and only save the PK Column's data value as the listboxitem's value instead of the entire object. Plus, it makes sense to use QueryArrayCached for the qlistbox creates in the metacontrols.
However, for the other performance issues that you mention, I would like to suggest an alternative approach.
Your Geschaefte table alone is 140 columns -- which is a very, VERY wide column. That, combined with the likely case that you have many many rows, will undoubtedly cause slow downs with any ORM-type of framework (Qcodo, as you mention Doctrine, etc.)
The value of Qcodo and its approach to application development is that it has a primary concern/focus of helping to keep a clean, consistent architecture throughout your code and thus should minimize maintenance issues in the long term life of your application. But what is implicit in that premise is that the data model stay agile, clean and consistent as well.
Having tables that are very large with millions or billions of rows is unavoidable, especially for very large applications. Things like Qcodo's encouragement of proper use of indexes and codegenerating loadarray shortcuts on those indexes helps the developer to ensure that their database is as optimal as possible.
However, having tables that are very wide (e.g. 140 columns) does impede on the “agile data model” premise quite a bit. But the good news is that this approach is avoidable... in fact, I will always manage to refactor a data model if I start to see tables getting beyond 15 or 20 columns.
I believe that with a properly factored, “agile” data model and the right use of indexes (which Qcodo definitely encourages), a lot of the performance issues you are seeing can be avoided and/or minimized. Plus, you get the added benefit of continuing to allow for a clean, consistent, agile codebase that can be easily augmented and maintained.
On the flip side, when you get to tables that have millions of rows and 40+ columns, then you almost HAVE to start using custom PHP in order to have a system optimal-enough to be usable. But, when that happens, you lose out on the consistency and the ease-of-maintenance aspects of the framework.
Hope that makes sense... please post with any additional thoughts or comments.