Cutting a Data DLL down to size

After moving to PostgreSQL several years ago, I stopped defining table relationships in the DCT. Nevertheless, with a 250+ table DCT, many relationships were long ago entered and do remain.

Considering a desire to always adhere to lazy developer practices, I’m wondering if an extension template might be able to override the AddRelation/AddRelationLink code generation in a data Dll such that only a small number of table declarations end up being included (ie only those tables directly used).

Would be interested to hear from anyone who has considered this or something similar?

I still have relationships defined in the dct. Sometimes Only in the dct not in the db. But mostly both. I do use the action server selection instead of just Action on the relationship. That stop clarion from doing the deletes or updates.

I’m pretty certain you have to have all the tables declared in your data DLL. That is what exports them out to be used by the other DLLs/EXEs.
You could probably write a template to embed code just before all the AddRelation code is generated to bypass that code.

I hope I have all tables switched to the server, but a good reminder that I should verify.
Nevertheless, I do believe relation code is generated independent of this setting.