1 reply Latest Post - ‏2013-01-02T23:22:33Z by ecpeters
12 Posts

Pinned topic Issue : Content.saveNew(InputStreams,String[],ContainingFolderID)

‏2012-12-31T09:43:43Z |

While invoking content.saveNew(streams, defaultFileNames, null);

InputStream[] streams = new InputStreamhttp://fileNames.length;
streams[i] = new FileInputStream(fileName); // fileName is the physical file
This is executing fine and I am able to see the documents in a single file.

But ,

When I tried to invoke as

streams[i] = new ByteArrayInputStream(bytesData);
I am seeing two documents in P8 repository. Primary and Secondary.
And If While retrieving the ingested document through second process I am able to see only the primary doc.

Refer attached for screenShot
Updated on 2013-01-02T23:22:33Z at 2013-01-02T23:22:33Z by ecpeters
  • ecpeters
    9 Posts

    Re: Issue : Content.saveNew(InputStreams,String[],ContainingFolderID)

    ‏2013-01-02T23:22:33Z  in response to vashreddy
    Hi VashReddy,

    Could you please give the sequence of code calls / events and what the problem is exactly? I'm unclear how many Content Objects you've got here, and how many Streams.

    When you pass multiple streams to saveNew(), that will generate multiple Content Elements within P8. That appears to be happening here as expected, from what I can tell in the screenshot. Is that the issue you were asking about? is the issue that you cannot retrieve the 2nd element?