DaDaBIK
This forum is devoted to the discussion about the software DaDaBIK database front-end
the PHP Database application generator for MySQL, PostgreSQL and SQLite; also available for Wordpress.

Welcome! Log In Create A New Profile

Advanced

2 tables

Posted by Andy 
Andy
2 tables
October 25, 2004 06:02AM
Hi,

I have a big problem: I want to control two tables of one database at the same time.

Situation:

2 tables

In the first table I have got products with one primary key (product_id) and ten other fields.

In the second table I have got offers from different firms related to the products in table one via product_id. The second table has another primary key (offer_id).


Workflow:

1)

I want to add another offer into table 2. I search for the products (in table 1) and when it's found I want to add the new offer (in table 2) without the need to change the table by hand.


2)

I would like to add another offer but my search for the product does not return any results. How can I enter a new product (table 1) together with the offer (table 2)?


Perhaps the solutions are easily done but I cannot see them, I am sorry.

Please, can you help me here?


Thank you very much,

Andy
Debbie S
Re: 2 tables
October 25, 2004 07:23AM
Andy

Have you placed this in a location where it can be viewed? I'm not really understanding the behaviour you're after. On the surface, it sounds like a simple linking table solution which is possible by using select_single field and entering in the table/field information throught the interface configurator.

Sorry I can't be more help.

Debbie
(Latest version of DaDaBIK when this message was posted: 3.1 Beta)
Andy
Re: 2 tables
October 27, 2004 11:27AM
Debbie

No, I'm sorry but it can't be viewed at this time.

But I can try to explain the problem in a more understandable way:

I want to search in the products table for the product I want to add another offer to. When I found the product I want jump from the results page to the offer table and fill in another offer.

Special case:

If there is no product in the products table I want to add a new product and an offer at the same time.

How do I do that with dadabik?

Thanks a lot for your patience.

Debbie S
Re: 2 tables
October 27, 2004 04:49PM
Andy

You can have your main table set up with the fields from the 2nd table included as select_single fields. In those select_single fields, you can then set the "allow other options" to yes to you can populate your 2nd table with data. That's the only idea I've got right now that I know works in DaDaBIK without any modding of the code.

With this set up, all your products are listed along with any current offers.

Debbie
(Latest version of DaDaBIK when this message was posted: 3.1 Beta)
Sorry, only registered users may post in this forum.

Click here to login