Platon Technologies
neprihlásený Prihlásiť Registrácia
SlovakEnglish
open source software development oslavujeme 10 rokov vývoja otvoreného softvéru! Utorok, 24. november 2026
O nás
Magazín
Otvorený softvér
CVS
Služby
Index  »  Projekty  »  phpMyEdit  »  Fórum  »  updatet: three table lookup question-need help!!

phpMyEdit Configuration     updatet: three table lookup question-need help!!
Odoslať novú tému   Odpovedať na tému    
 
gz     Založený: 30.04.2004   Príspevky: 9  
Príspevok Zaslal: 2004-04-30 12:27
Návrat hore  Odpovedať s citátom     

hello,

my problem:

i've 3 tables

table_Firma
FirmenID
FirmenName
Ort
.
.
table_Person
PersonID
Name
Vorname
Telefon
.
.
table_Kontakt
KontaktID
PersonID
FirmenID
.
.
i've creat a php-page(kontakt.php) based on the
table Kontakt.
is it possible to have a drop-down menu in the Kontakt.php-page wich show me a combination of PersonID and
FirmenID ? but not the id's, i need the real values
(FirmenID->FirmenName, PersonID->Namen)

thx alot
gz


Naposledy upravil gz dňa 2004-05-01 13:24, celkom upravené 1 krát

 
ajh     Založený: 17.12.2003   Príspevky: 236  
Príspevok Zaslal: 2004-04-30 13:32
Návrat hore  Odpovedať s citátom     

Yes - look at the 'values' option in the manual.

 
gz     Založený: 30.04.2004   Príspevky: 9  
Príspevok Zaslal: 2004-04-30 13:43
Návrat hore  Odpovedať s citátom     

ajh Napísal:
Yes - look at the 'values' option in the manual.

thx
i'll see what i can find

 
gz     Založený: 30.04.2004   Príspevky: 9  
Príspevok Zaslal: 2004-04-30 14:02
Návrat hore  Odpovedať s citátom     

ajh Napísal:
Yes - look at the 'values' option in the manual.


sry but i'm new at this all(php,mysql..)

have look in the doku but can't find a solution
:(

my two fields in Kontakt.php:

$opts['fdd']['KontaktID'] = array(
'name' => 'Nachname',
'select' => 'T',
'maxlen' => 11,
'default' => '0',
'required' => true,
'sort' => true
);
$opts['fdd']['KontaktID']['values']['table'] = 'Kontakt';
$opts['fdd']['KontaktID']['values']['column'] = 'KontaktID';
$opts['fdd']['KontaktID']['values']['description'] = 'Name';

$opts['fdd']['FirmenID'] = array(
'name' => 'Firma',
'select' => 'T',
'maxlen' => 20,
'default' => '0',
'sort' => true
);
$opts['fdd']['FirmenID']['values']['table'] = 'Firma';
$opts['fdd']['FirmenID']['values']['column'] = 'FirmenID';
$opts['fdd']['FirmenID']['values']['description'] = 'FirmenName';

how i can combine this two fields in one dropdown-menu?
(the problem i have with ['divs'] is that the second
(['description'][1]) came from a other table)

thx
ps:sry for bad english[/code]

 
gz     Založený: 30.04.2004   Príspevky: 9  
Príspevok Zaslal: 2004-05-01 13:20
Návrat hore  Odpovedať s citátom     

dears,

can any one help me to
solve my problem??

gz

 
michal     Založený: 17.06.2003   Príspevky: 537   Bydlisko: Slovakia
Príspevok Zaslal: 2004-05-03 10:29
Návrat hore  Odpovedať s citátom     

easy answer is, why would you want just one dopr down ?
are persons and firmas connected ? for me, they look like completely separate, so there is no need/possibility for one dropdown...

 
gz     Založený: 30.04.2004   Príspevky: 9  
Príspevok Zaslal: 2004-05-03 11:24
Návrat hore  Odpovedať s citátom     

michal Napísal:
easy answer is, why would you want just one dopr down ?
are persons and firmas connected ?


Hi michal,

sry, my fault

Yes, table_person and table_firma are connected.

Update:
.
table_Person
PersonID
Name
Vorname
Telefon
FirmenID << new
.

hope you can help me

 
michal     Založený: 17.06.2003   Príspevky: 537   Bydlisko: Slovakia
Príspevok Zaslal: 2004-05-04 13:15
Návrat hore  Odpovedať s citátom     

afaik, there is no easy way...
posibilities:
1. make extra column in table_person which would be firma_name (problems when updating and inserting, but some after triggers in table_firma should solve this)

2. there was a discussion in this forum on advaced table joining / joining three tables. a patch was attached, but due to some problems, it was not committed. but you can try this....

3. play with 'filters' and 'description', but that's advanced topic again....

i would stick with 1. (it's just one trigger and extra column)

 
gz     Založený: 30.04.2004   Príspevky: 9  
Príspevok Zaslal: 2004-05-04 13:51
Návrat hore  Odpovedať s citátom     

michal Napísal:
afaik, there is no easy way...
posibilities:
1...
2...
3. ..
i would stick with 1. (it's just one trigger and extra column)


ok,
i will try this

thx for the moment

 
Odoslať novú tému   Odpovedať na tému    

Copyright © 2002-2006 Platon Group
Stránka používa redakčný systém Metafox
Na začiatok · Odkazový formulár · Prihláška
Upozorniť na chybu na PLATON.SK webstránke · Podmienky použitia · Ochrana osobných údajov