# Basic SQL/CakePHP

**URL:** <https://discourse.cakephp.org/t/basic-sql-cakephp/4732>\
**Category:** Need Help\
**Created:** [August 16, 2018, 9:19pm UTC](https://discourse.cakephp.org/t/basic-sql-cakephp/4732 "2018-08-16T21:19:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![r\_alarcon](https://avatars.discourse-cdn.com/v4/letter/r/7ea924/32.png) [@r\_alarcon](https://discourse.cakephp.org/u/r_alarcon)\
**Post date:** [August 16, 2018, 9:19pm UTC](https://discourse.cakephp.org/t/basic-sql-cakephp/4732/1 "2018-08-16T21:19:10Z")

</div>

I created a Cakephp project, build on a Mysql database whic contains One to Many, Many to many associations among others.

The thing is; I want a page with a formulary on wich one can introduce data related to various tables (so far, I only have the tables with their associations as they are show in the automatic templates CakePHP generates, which oftens reffers to data on other tables by their ID, and not by other useful features, like the “name” field)

The question is; How this “summay table” must be build? through a “costume query” joining tables? or by “engineering” the database tables including more relations that needed?

Help please!

---

<div class="post-metadata">

**Author:** ![rrd](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.cakephp.org/rrd/32/113_2.png) [@rrd](https://discourse.cakephp.org/u/rrd)\
**Post date:** [August 17, 2018, 7:53am UTC](https://discourse.cakephp.org/t/basic-sql-cakephp/4732/2 "2018-08-17T07:53:35Z")

</div>

Your question is unclear for me.

If the tables are associated than you can access them through the association.

If you ant something like a dashboard where you can do administration stuff for more tables, than view cells might help.

[https://book.cakephp.org/3.0/en/views/cells.html](https://book.cakephp.org/3.0/en/views/cells.html)

---

<div class="post-metadata">

**Author:** ![r\_alarcon](https://avatars.discourse-cdn.com/v4/letter/r/7ea924/32.png) [@r\_alarcon](https://discourse.cakephp.org/u/r_alarcon)\
**Post date:** [August 17, 2018, 2:18pm UTC](https://discourse.cakephp.org/t/basic-sql-cakephp/4732/3 "2018-08-17T14:18:57Z")

</div>

Yup, that’s the thing, a Dashboard type of table where you can enter the data corresponding to different tables. Thanks, I’ll give it a shot!!
