Products Resources Support About Us

Rocket Software

Curl output to mvs dataset

I would like curl write output to mvs dataset.

Following writes to dataset USERID.QAPI but changes recordlength to 80 when dataset exists or creates with lrecl 80 if dataset did not exist before :
curl -m 15 -v -k --trace qapi.trace -o “//‘USERID.QAPI’” --url “${url}” -K-

Following writes to qapi.txt with newline after pos 181 as it should be:
curl -m 15 -v -k --trace qapi.trace -o qapi.txt --url “${url}” -K-

Is there a qay to have curl use the lrecl from existing dataset or define lrecl in the command?


Hi Frans,

We didn’t implement any additional functions to make curl working with datasets. So there is no way to specify lrecl in the current build. I created an internal ticket to see what we can do here. We will review it later, because we are working on requests from customers on maintenance.

Thank you for understanding.

Hi Tatyana,
I was able to apply workaround with piping to cp command. If I pre-allocate and perform transfer binary it works for me so no need to rush. Binary transfer is ok for me as i use curl to download mvs dataset thru apache http server active in other sysplex so ebcdic to ebcdic.