how to get related if column names are not named conventionally

Notice: This thread is very old.
petr.pavel
Member | 535
+
0
-

The best solution is to use InnoDB and define a foreign key on users_addresses.

Alternatively, you can define your own Conventional Reflection. I don't think there's any documentation page and I can't help you on this because I use NotORM, not Nette Database.

Documentation on configuration mentions how to make NDB use your reflection (here and below here in ‘full example’) but I couldn't find any explanation how to actually build one. I guess you'll have to study the source code.

Because NDB originates from NotORM, the original NotORM page on Structures (NotORM Structure = NDB Reflection) may be of help. Or here, close to the end of the page.