Answer the question
In order to leave comments, you need to log in
How to properly bind data in Yii1?
Hello! I'm scratching my head about table relationships in Yii. Let's say we have three tables and data in these tables:
Lookup - (id, type, code, title) - currency data is stored in the table, just their code and title
1, price_currency, 10, rur
2, price_currency, 20, usd
2, price_currency, 30, eur
1, предмет №1, 1000, 10
2, предмет №2, 2000, 20
3, предмет №3, 1000, 30
rur, rur, 1
usd, rur, 50
eur, rur, 60
Answer the question
In order to leave comments, you need to log in
item 4 : www.yiiframework.com/doc/guide/1.1/ru/database.arr
www.yiiframework.com/doc/guide/1.1/ru/database.arr...
And in general, why do you want to use as foreign key to link to Lookup - code, and d CrossCourse stuffed title from Lookup?
Some of this is redundant.
Or I misunderstood something
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question