Renaming TMX Languages (in Lingo)

This Forum is for general issues about MadCap Lingo
Post Reply
tvecchiarelli
Propeller Head
Posts: 16
Joined: Thu May 08, 2014 10:18 am

Renaming TMX Languages (in Lingo)

Post by tvecchiarelli »

Hi there,

Is it possible to rename the Source/Target Languages for imported TMX files?

Currently we have the following (as an example) in the drop-down menu:

English - French
English (US) - French (France)
english - french

So the program views them as different languages. Not sure if translating a new document using all our existing French translations would work with this set up (my guess is that it wouldn't, or it would take several steps). So basically, I just want one Source/Target language naming convention per language.

Tina
techwriter31
Propellus Maximus
Posts: 551
Joined: Wed Mar 05, 2008 10:50 am

Re: Renaming TMX Languages (in Lingo)

Post by techwriter31 »

You can change the source/target languages.

My guess is that over time, files were imported into the TM database using different XML language tags. For example, some of the files probably included "FR-FR" for French (France) or "FR" for French, etc. You can still use this setup for your translations, however, you'd have to select the Language drop-down in Lingo to switch between the different language tags to see/edit/apply all segments in the entire TM.

Here is one manual way to change the language tags. But it's probably wise to back up your translation memory files before doing this.
1. Choose to edit the translation memory.
2. Once in the translation memory file, select the Language drop-down to select the appropriate language tag.
3. For each segment, manually change the Target Language to the single language tag you'd prefer to use (assuming it's a small enough number of segments that doing this manually isn't too tedious).
4. Save the translation memory file.
5. Going forward, make sure the files imported into the TM use the correct language tags prior to import. If using a translation vendor, make this one of the delivery requirements for the TMs they provide.

There are more automated ways to do this, but they are also a little more risky.
Kellie
tvecchiarelli
Propeller Head
Posts: 16
Joined: Thu May 08, 2014 10:18 am

Re: Renaming TMX Languages (in Lingo)

Post by tvecchiarelli »

Thank you Kellie,

Although I was hoping for an easier solution. ;-)

Yes, I think the differences occurred by different people using different methods to create the TMs.

The smallest "language set" we have in our TM has 550 segments, and this is the one that's named the way we'd like (simply 'English-French'). The others are closer to 1000 segments.

Is it possible to delete the language sets and the associated segments and then re-import them?

The TMs are all stored on a SQL server (if that helps).

Tina
p.s. fyi I am VERY new to Lingo, just started using it (or trying to) about a month ago. :?
techwriter31
Propellus Maximus
Posts: 551
Joined: Wed Mar 05, 2008 10:50 am

Re: Renaming TMX Languages (in Lingo)

Post by techwriter31 »

Here's a potentially more automated way of doing this.

Disclaimer: I haven't tried this process myself, so I cannot guarantee that it will work. You want to proceed with caution, have a backup of your TM, etc. It might not hurt to contact MadCap tech support for their advice too, if you have a maintenance plan.

1. You should be able to use the "Export to TMX" option to export your existing TM. This should simply export a copy of the TM to a TMX file, but will not remove any of the segments stored in the TM.
2. I'd go ahead and check all of the language tag checkboxes in the dialog to export the entire TM database and click OK.
3. Then, you can open the TMX file with a text editor, do a find/replace for the language tags,replacing the tags that you don't want with the tags that you do want.
4. Next, if possible, I'd recommend creating a new TM (either locally or on the server) and importing this TMX file (with the corrected language tags) to the new TM. My thought with this is that you can use this new TM as a test database without potentially damaging the existing TM.
5. You can then connect to the TM and see if the problem is resolved. Once verified, you could use this TM going forward and remove the old TM database (with the outdated tags). I'm paranoid, so I'd probably leave the old database in place for a while, until you've fully verified there are no problems with the new TM.
Note: Presumably, your SQL databases are being backed up - either using a Maintenance Plan in SQL Server or using a backup software tool. You'll want to make sure that the new TM is included in the backup process.
Kellie
tvecchiarelli
Propeller Head
Posts: 16
Joined: Thu May 08, 2014 10:18 am

Re: Renaming TMX Languages (in Lingo)

Post by tvecchiarelli »

Thank you so much Kellie!

I will proceed with caution then let you know if this works. I will check with our IT Dept to see if the Server is backed up, pretty sure it is.

It wouldn't be that much work to start over from scratch, which I will strongly consider if this doesn't work.

Tina
tvecchiarelli
Propeller Head
Posts: 16
Joined: Thu May 08, 2014 10:18 am

Re: Renaming TMX Languages (in Lingo)

Post by tvecchiarelli »

Kellie,

I guess I should have asked what text editor I should be using?

I know I can open the .tmx file in Notepad, but once I am done - won't it just be a text file at this point?

Tina
techwriter31
Propellus Maximus
Posts: 551
Joined: Wed Mar 05, 2008 10:50 am

Re: Renaming TMX Languages (in Lingo)

Post by techwriter31 »

I *think* Notepad should be fine, as long as you just save the file after making the changes (without changing the file type).
Kellie
tvecchiarelli
Propeller Head
Posts: 16
Joined: Thu May 08, 2014 10:18 am

Re: Renaming TMX Languages (in Lingo)

Post by tvecchiarelli »

Thanks Kellie,

It worked ! At least with the local TM.

I will try to import to the Server today - and see what happens. Just waiting to hear back from our IT Dept. about a couple of questions I had.

I will let you know. :)

Tina
techwriter31
Propellus Maximus
Posts: 551
Joined: Wed Mar 05, 2008 10:50 am

Re: Renaming TMX Languages (in Lingo)

Post by techwriter31 »

Great! :)
Kellie
tvecchiarelli
Propeller Head
Posts: 16
Joined: Thu May 08, 2014 10:18 am

Re: Renaming TMX Languages (in Lingo)

Post by tvecchiarelli »

Kellie,

I couldn't wait for IT to get back to me, so I just imported the edited TMX file, but it only made a copy, it didn't remove what was already saved to the Server.

So ... I am thinking of deleting the existing db in the server, create a new one - then import my new & improved TMX file.

That should work - right? :wink:

Tina
tvecchiarelli
Propeller Head
Posts: 16
Joined: Thu May 08, 2014 10:18 am

Re: Renaming TMX Languages (in Lingo)

Post by tvecchiarelli »

Hi Kellie,

It sort of worked. Well it did work but not with the results I expected ...

I ended up just deleting the segments on the TM Server for every language combination (at least I thought I deleted them).

Then I imported the new and improved TMX file. So now I only have the language naming conventions I want, but all segments appear to be duplicated, for many there are 4 identical entries. Not sure why that happened -there is no duplication in the local TM I created, so why would I have multiple entries for the same segment when I import the same TMX file to the server (this is mainly a rhetorical question)? :?

...and there is probably no quick & easy way to remove duplicate entries. I guess as long as it's not an issue when I need to "translate" a document, it would be okay to leave it as is...

Tina
techwriter31
Propellus Maximus
Posts: 551
Joined: Wed Mar 05, 2008 10:50 am

Re: Renaming TMX Languages (in Lingo)

Post by techwriter31 »

Hi Tina,
I couldn't wait for IT to get back to me, so I just imported the edited TMX file, but it only made a copy, it didn't remove what was already saved to the Server.
I'm not sure what you mean by "it made a copy" here. Did you import this file to the existing TM or create a new one and then import the updated TMX file?
So ... I am thinking of deleting the existing db in the server, create a new one - then import my new & improved TMX file.
If you're talking about deleting the existing TM, I wouldn't do that. As I mentioned, I'm paranoid so I'd recommend creating a new TM database and leave the old database in place for a while, until you've fully verified there are no problems with the new TM.
It sort of worked. Well it did work but not with the results I expected ...

I ended up just deleting the segments on the TM Server for every language combination (at least I thought I deleted them).

Then I imported the new and improved TMX file. So now I only have the language naming conventions I want, but all segments appear to be duplicated, for many there are 4 identical entries. Not sure why that happened -there is no duplication in the local TM I created, so why would I have multiple entries for the same segment when I import the same TMX file to the server (this is mainly a rhetorical question)? :?

...and there is probably no quick & easy way to remove duplicate entries. I guess as long as it's not an issue when I need to "translate" a document, it would be okay to leave it as is...
It's hard for me to say. My guess is that the original segments were not deleted, and are now showing up as duplicates.
Kellie
techwriter31
Propellus Maximus
Posts: 551
Joined: Wed Mar 05, 2008 10:50 am

Re: Renaming TMX Languages (in Lingo)

Post by techwriter31 »

Oh, I think I see what might have happened. If you did try to delete all of the segments prior to importing the updated TMX, you would have to make sure to delete them from every "page" in Lingo. By default, if you highlight all segments on the first page and click save, you only see a blank page with no segments, so it appears all segments have been deleted. You then have to click next page and delete all of those segments, and then repeat for all pages.
Kellie
tvecchiarelli
Propeller Head
Posts: 16
Joined: Thu May 08, 2014 10:18 am

Re: Renaming TMX Languages (in Lingo)

Post by tvecchiarelli »

Sorry, by "IT" I meant our internal IT (Information Technology) Support Department.

By "copied" I meant that after I imported the local TMX file it did not delete the language names already there. So I just deleted ALL the segments for every language combination (I am more of a risk-taker). :wink: I left the db, just deleted all the segments. Yes - I did make sure to delete the segments from every page (I noticed that after I had about 4 more pages).

I just left the duplicate segments, and just tried to pre-translate a file and it works fine. So seems like it just ignores the duplicate segments.

...and I can live with that!! I'll be more aware for future imports.

Thank you for your help Kellie -

Tina
Post Reply