We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

Inserting relational table data

In my db I have

Articles(id, title, content)

Which have

Articles_Has_Categories(articleId, categoryId)

Categories(id, name)

So when I do $article->save(), I want the Articles_Has_Categies add a row for new article with his categories. Is that possble with Phalcon ? Thank you guys for the help, I asked alot of questions in this forum and got helped quickly :), really nice community.

What about retrieving related records? I assumed that would be done implicitly but that is not my experience so far.