gnue-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

relations between tables


From: Theanoula
Subject: relations between tables
Date: Sun, 03 Mar 2013 20:48:36 +0200
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.16) Gecko/20120922 Icedove/3.0.11

Hello!

I'd like to ask you something that I have been trying to figure out. I have 3 tables that I connect with each other. Here is the relationship:

<datasource name="dts_customer" connection="gnue" table="transactor" />

<datasource name="dts_cars" connection="gnue" table="cars"
 master="dts_customer" masterlink="id" detaillink="customer_id" />

<datasource name="dts_contract" connection="gnue" table="contract"
 master="dts_cars" masterlink="id" detaillink="car_id" />


I have created the primary and foreign keys in the database.
When I search(in the form) in dts_customer.name I get all the info I need. The same happens when I search in dts_cars.car_number(I get everything) but when I search in dts_contract.contract_no I don't get the right info.

In mysql Log I see that it always uses the query "Select * from transactor where id=(Select...)"

Do I do something wrong or is it the relationship? Is such a relationship possible? A to B, B to C eventually A to C and reverse

Thanks in advance. I'd really appreciate an answer.

Regards
Thea


reply via email to

[Prev in Thread] Current Thread [Next in Thread]