LinuxMCE Forums
May 26, 2013, 08:12:30 am GMT-1 *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Rule #1 - Be Patient - Rule #2 - Don't ask when, if you don't contribute - Rule #3 - You have coding skills - LinuxMCE's small brother is available: http://www.agocontrol.com
 
   Home   Help Search Chat Login Register  
Pages: [1]
  Print  
Author Topic: Problem with HADesigner and DB  (Read 410 times)
massabuntu
Veteran
***
Posts: 97



View Profile
« on: June 26, 2009, 09:34:14 am »

Hi all,
i'm having some problem with HADesigner, i added another text_ls table in pluto_main database wich contains italian translation, when i added it there was already the origninal text_ls table, and it was added as text_LS_AltVersions by mysql(i think).
So i renamed the "old" one as Text_LS_BAK and the new one Text_LS.
 Now when i start HADesinger it returns a error like "Text_LS_AltVersion" is missing but i did'nt understand where   it pick the "AltVersion" since i started Hadesigner after the rename thing.

Obviously i did'nt make a DB Backup, am i screwed??

Thanks, Martino.
Logged
chriss
Veteran
***
Posts: 140


View Profile
« Reply #1 on: June 26, 2009, 09:55:18 am »

Hi Martino

Obviously i did'nt make a DB Backup, am i screwed??

you could try to make an sqlCVS update and see if the correct table contents are pulled from the server.

My fresh install contained both mentioned tables Text_LS and Text_LS_AltVersions, however I don't know the purpose of the second one. Anyway, don't mess with tables by simply renaming/deleting them or the contents.

To insert a new translation you have to do the following two steps
1) add a new row with a new language to pluto_main.Language and remember the id (PK_Language) of the language. DO NOT OVERWRITE ANY EXISTING ROWS!
2) To translate the UI you have to add a new row to pluto_main.Text_LS for every row you would like to translate from pluto_main.Text, i.e., pick a row, translate it to italian and write your translation to the field Description in Text_LS. FK_Text has to be the same value as Text.PK_Text of the translated item and Text_LS.FK_Language has to be the same as Language.PK_Language. Note that you don't have to translate every field - if there is no match in Text_LS the UI falls back to the english text (fine for on-screen keyboard and stuff)

You need to understand what's happening here. We have a table the defines all available languages (pluto_main.Language). We also have a table with several texts for the UI (pluto_main.Text). Finally there is a table defining language specific texts/translation (pluto_main.Text_LS) in an overlay form. This last table is connected via foreign keys to pluto_main.Text (pluto_main.Text_LS.FK_Text -> pluto_main.Text.PK_Text) and pluto_main.Language (pluto_main.Text_LS.FK_Language -> pluto_main.Language.PK_Language). If you do not have these connections it won't work.

br,
/chriss
Logged
massabuntu
Veteran
***
Posts: 97



View Profile
« Reply #2 on: June 26, 2009, 10:20:52 am »

I try an sqlCVS update and let see what we get...
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!