Formula for the button
Good evening everyone and Merry Christmas
I need professional help. I'm having trouble describing the problem, so I'm attaching the database so you can examine it in more detail.
There is an investors tab in the PROJECT table. The task is that the data entered there should be transferred to the investors table, to the corresponding fields and table, so that it would be possible to view who invested how much and in which project
Thank you all in advance
Merry Christmas
9 replies
-
Looking at your DB the Investors tab in the PROJECT table is empty except for a reference field. You will have to be more specific about what you are looking for.
Can you upload another DB with the fields you want to copy?
How are you planning of selecting investors? Can you create new investors or only pick from Investors table?
-
Looking back at your past post you have asked similar posts. I would ask that you try to write the code first and post it. No better way to learn then to do it.
I understand that the end goal seems huge and daunting. May I suggest that you take it one step at a time. Maybe just start with how you will select an investor(s) and create the records and proper linkage. Then add the next step and so on.
We can help you along the way, but I think you should write the rough drafts.
-
If you look at your data model, it looks like this

There is nothing joining your Investors to your Projects. Because a Project can have more than one Investor, and an Investor can invest in more than one Project you need an additional table, called a join table, that creates this Many-to-Many relationship.

Once you have this in place it might become more obvious how to do what you want.
Extra hint... I don't think you will need a button!
Regards John
-
Good morning
I can't find a formula for the filter for view to show only those records that relate to this project. -
It looks like you want to use Invesment in Project as your join table. To make that work the Invesment in Project table has to be the many (M) side of the relationship.
If you look at the field oldPROJECTS2, you will see that Invesment in Project is the 1 side:

In Ninox, you want to be in the table that is on the many side to create the link. If you only see the ability to select one record then you are on the many side. If you see a table where you can add a record or create a new record then you are on the 1 side. Now each record in Invesment in Project is linked to 1 record in Investors and 1 record in PROJECTS.
Since we created the new reference field in Invesment in Project, we also now have a new relationship field in the PROJECTS table, also called Invesment in Project (you can rename it to whatever you like). If you click on the Chili record, and go to the Investors tab, you will now see the one investor. I renamed the View to oldView as you no longer need it anymore.
Content aside
- yesterdayLast active
- 9Replies
- 45Views
-
3
Following
