json files, regex
Thread poster: Claudia Infantes Villafranca
Claudia Infantes Villafranca
Claudia Infantes Villafranca  Identity Verified
Spain
Local time: 04:10
English to Spanish
+ ...
Dec 7, 2016

Hi all,

I am working with a json file, after achieving a nice setting up in Studio to have extracted only the text among quotes, I have encountered a problem with some segments which are after [ and before ]. I am trying everything possible to have the text between [ and ] extracted but so far impossible.

Does any of you know which Regex or any other means I could use to make Studio extract the following type of text from a json file?

"summary.0.text.1"
... See more
Hi all,

I am working with a json file, after achieving a nice setting up in Studio to have extracted only the text among quotes, I have encountered a problem with some segments which are after [ and before ]. I am trying everything possible to have the text between [ and ] extracted but so far impossible.

Does any of you know which Regex or any other means I could use to make Studio extract the following type of text from a json file?

"summary.0.text.1": "Sie haben keine Stärke ausgewählt. Das kann ein Zeichen dafür sein, dass Sie sich zu wenig zutrauen und lieber auf Ihre eigenen Schwächen schauen.",
"summary.0.text.2": "Tatsächlich entspricht das, was man sich zutraut, nicht dem, was real den persönlichen Fähigkeiten und Kompetenzen entspricht. Oft merkt man erst in Extremsituationen oder im Gespräch mit Freunden und Verwandten, wozu man eigentlich fähig ist.",
"summary.0.tipp.heading": "Unsere Tipps:",
"summary.0.tipp": [
"Führen Sie den Test noch einmal durch und versuchen Sie sich vorzustellen, welche innere Stärke Sie in einer Extremsituation nutzen würden.",
"Auch ein Gespräch mit Freunden und Verwandten kann helfen, Ihren inneren Stärken auf die Spur zu kommen."
]
,


In bold appears the text Studio is unable to open so far ...

Any help would be greatly appreciated
Collapse


 
Shai Navé
Shai Navé  Identity Verified
Israel
Local time: 05:10
English to Hebrew
+ ...
Json file definition Dec 7, 2016

The easiest way to go about this is probably installing the Json file type definition from the App Store.

 
Claudia Infantes Villafranca
Claudia Infantes Villafranca  Identity Verified
Spain
Local time: 04:10
English to Spanish
+ ...
TOPIC STARTER
json files, regex - json file definition Dec 7, 2016

Hi Shai,

many thanks for your reply! However, I have tried that program and there is a problem when converting the file into a target file, since it does not work properly and therefore, it does not convert the file back into json...

I guess once they get that issue resolved It would be a great program.

Has any of you got the same problem with this program?

Does anyone know any other way to get those segments extracted by Studio?

... See more
Hi Shai,

many thanks for your reply! However, I have tried that program and there is a problem when converting the file into a target file, since it does not work properly and therefore, it does not convert the file back into json...

I guess once they get that issue resolved It would be a great program.

Has any of you got the same problem with this program?

Does anyone know any other way to get those segments extracted by Studio?

Many thanks in advance!
Collapse


 
Shai Navé
Shai Navé  Identity Verified
Israel
Local time: 05:10
English to Hebrew
+ ...
Have look at Paul's article Dec 8, 2016

I'd consider contacting the developer of the plugin or posting on community.sdl.com because it should work.

You can try to create a new regext filetype. Paul's article walks you through the process.

The regex that you need based on the example you provided is:
Opening pattern: .+\[[\n]"
Closing pattern: "[\n]\],

This will extract onl
... See more
I'd consider contacting the developer of the plugin or posting on community.sdl.com because it should work.

You can try to create a new regext filetype. Paul's article walks you through the process.

The regex that you need based on the example you provided is:
Opening pattern: .+\[[\n]"
Closing pattern: "[\n]\],

This will extract only the text in bold, without the quotes.

A more conservative approach if posting here added some linebreaks that do not appear in the JSON file is:
Opening pattern: .+\[
Closing pattern: \],

This will extract the text in bold in your example, only without the square brackets.
Collapse


 


To report site rules violations or get help, contact a site moderator:


You can also contact site staff by submitting a support request »

json files, regex







Wordfast Pro
Translation Memory Software for Any Platform

Exclusive discount for ProZ.com users! Save over 13% when purchasing Wordfast Pro through ProZ.com. Wordfast is the world's #1 provider of platform-independent Translation Memory software. Consistently ranked the most user-friendly and highest value

Buy now! »
Trados Studio 2022 Freelance
The leading translation software used by over 270,000 translators.

Designed with your feedback in mind, Trados Studio 2022 delivers an unrivalled, powerful desktop and cloud solution, empowering you to work in the most efficient and cost-effective way.

More info »