CakePHP's $hasMany
and $belongsTo
are accessing the database's relationships.
So you have to create them.
Cakephp and Postgres, table relations
-
26-06-2023 - |
Pergunta
The question is simple (and maybe silly):
When I create the tables in Postgres, do I have to also create the relations? I ask this because I have used an orm before and had issues with some relations, specially multiple primary keys, so I had to re-do all the db structure with the orm.
I was thinking about having only tables without relations and using cake's $hasMany, $belongsTo variables to manage the relations. will this work?
Thanks in advance.
Solução
Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow