Skip to main content
1-Visitor
July 23, 2020
Question

im createcontent command throw error "The command line is too long" with html content.

  • July 23, 2020
  • 3 replies
  • 2784 views

Hi,

 

I am working on a python script where I need to migrate data from rst files into PTC.

I am using im createcontent command for this

I am converting rst file into html and then trying to insert the data into ptc using "im createcontent" command from CLI but  is throwing error  "The command line is too long" .

Please assist me with the resolution of this error, or if there is some better approach to do so.

Thanks in Advance.

3 replies

24-Ruby III
July 24, 2020

What PTC's software are you using?

1-Visitor
July 24, 2020

PTC Integrity 10

but I am running it from command prompt

5-Regular Member
August 21, 2020

An example of the CLI syntax that you are using, which is causing the problem, would be needed, in order to know what the issue is.

 

You may want to open a Support case for this.

 

Relevant online help, for the im createcontent command:

http://support.ptc.com/cs/help/integrity_hc/integrity1221_hc/en/#page/IntegrityHelp%2Fim_createcontent.html%23

 

My guess, is that you're probably passing in the richcontentfield value on the command line directly, in the command, and it's probably too long for the CLI.

 

 

 

11-Garnet
September 4, 2020

Hi @NehaAdhikari ,

 

This is not issue with Integrity and this is python limitation. Try some alternatives like ,

- Try executing sub process instead of simple popen. Note the maximum character supported is somewhere 20000

- Try reading the content from file. You have the option "-F" in createcontent command. So store your rich content within it and try passing the same

 

Regards,

Sathish Kumar Kamaraj

October 19, 2020

Hello, Skamaraj
I posted a Reply to ask about the -F option in the answer.
I want to upload the contents of the file as richContent by using the -F option.
There is an error that exceeds the size limit to use as a Cli, so I want to process it by putting Markdown language in a file and reading the file.
Thanks in Advance.