Remove quote while writing binary file from JSON

Describe the problem/error/question

Hello,
I am trying to write a new binary file after converting a JSON string object into a binary one. Unfortunately, the quotes delimitating the string in the JSON object are also converted in the binary object and I don’t want that. How can I remove them ? Is it a parameter in the Convert to/from binary node ? Or in the write binary file ?

What is the error message (if any)?

Please share your workflow

(Select the nodes on your canvas and use the keyboard shortcuts CMD+C/CTRL+C and CMD+V/CTRL+V to copy and paste the workflow.)

Share the output returned by the last node

[

{

“hl7Message”: “MSH|^~&|XXX||XXX||20231122163012142||ORU^R01|1d464a6a-e45b-4cc8-a1d6-e6c6ebf2b730|P|2.5|||AL|AL PID|||123456789||^||||||^^^^|| PV1||I|00078|||||^^^^^^^^^||530||||||||||||||||||||||||||||||||||||||| ORC|1||^^20231118110158000 OBR|1|||^00069^Compte-rendu examen^^XXX|||||||||||||||||| OBX|1|ST|Valide^1d464a6a-e45b-4cc8-a1d6-e6c6ebf2b730|true|E:XXX\1d464a6a-e45b-4cc8-a1d6-e6c6ebf2b730.pdf||||||”

},

{

“hl7Message”: “MSH|^~&|XXX||XXX||20231122163012149||ORU^R01|d13eff87-4b1d-470b-a768-e3003617adf7|P|2.5|||AL|AL PID|||129992||^||||||^^^^|| PV1||I|00078|||||^^^^^^^^^||530||||||||||||||||||||||||||||||||||||||| ORC|1||^^20231114110213000 OBR|1|||^00069^Compte-rendu examen^^XXX|||||||||||||||||| OBX|1|ST|Valide^d13eff87-4b1d-470b-a768-e3003617adf7|true|E:XXX\d13eff87-4b1d-470b-a768-e3003617adf7.pdf||||||”

},

{

“hl7Message”: “MSH|^~&|XXXX||XXXX||20231122163012154||ORU^R01|909a5c75-adc7-4c79-8082-91f75d1a3b4b|P|2.5|||AL|AL PID|||1299923||^||||||^^^^|| PV1||I|00078|||||^^^^^^^^^||530||||||||||||||||||||||||||||||||||||||| ORC|1||^^20231107110225000 OBR|1|||^00069^Compte-rendu examen^^XXXX|||||||||||||||||| OBX|1|ST|Valide^909a5c75-adc7-4c79-8082-91f75d1a3b4b|true|E:XXX\909a5c75-adc7-4c79-8082-91f75d1a3b4b.pdf||||||”

}

]

Information on your n8n setup

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app): Docker
  • Operating system:

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

Hi @Trolland, welcome to the community!

Are you looking to just write the string from your hl7Message field into a file, without anything else (especially no quotes)? If so, you’re probably looking for the “Use Raw Data” option.

Here’s a quick example workflow:

The result would not include any quotes around the string.

Hope this helps! If that’s not it, perhaps you can confirm how you want your result file to look like?