![]() |
![]() ![]() |
![]() |
![]()
Post
#1
|
|
![]() Grupa: Moderatorzy Postów: 4 465 Pomógł: 137 Dołączył: 26.03.2004 Skąd: Gorzów Wlkp. ![]() |
Witam,
Jeśli tabela główna nie zawiera żadnego pola oprócz ID lub istnieje jakieś, ale nie zostanie uzupełnione treścią, to tabela i18n tej tabeli zostanie wypełniona danymi, ale rekord w głównej tabel nie zostanie utworzony i referencja do głównej tabeli nie zostanie zachowana. Czy ktoś wie, co należy zrobić, aby można było utworzyć tabelę główną tylko z polem ID ? Testowy model: Kod propel: posts: _attributes: { phpName: Post, isI18N: true, i18nTable: posts_i18n } idMethod: native id: { type: integer, required: true, primaryKey: true, autoIncrement: true } test: type: LONGVARCHAR posts_i18n: _attributes: { phpName: PostI18n } id: { type: integer, required: true, primaryKey: true, foreignTable: posts, foreignReference: id } culture: { isCulture: true, type: varchar, size: 7, required: true, primaryKey: true } description: { type: LONGVARCHAR } i kod
Pozdrawiam. -------------------- To think for yourself you must question authority and
learn how to put yourself in a state of vulnerable, open-mindedness; chaotic, confused, vulnerability, to inform yourself. Think for yourself. Question authority. |
|
|
![]()
Post
#2
|
|
Grupa: Zarejestrowani Postów: 154 Pomógł: 1 Dołączył: 24.04.2006 Ostrzeżenie: (0%) ![]() ![]() |
To co napiszę nie jest odpowiedzią na twoje pytanie, tylko obejsciem problemu, ja zrobilem tak że dodalem dodatkowe pole w tabeli glownej typu varchar(2) i wstawiam wartosc ' ' czyli jedna spacje przy zapisie rekordu
Ten post edytował stachuf11 16.04.2008, 20:56:14 |
|
|
![]() ![]() |
![]() |
Wersja Lo-Fi | Aktualny czas: 20.07.2025 - 06:16 |