I'm facing a similar problem with output structure.
Sometimes the error occours with Memory error, sometimes with "RFC_INVALID_PARAMETER- An invalid table handle was passed to the API call.
The output structure is as Export parameter instead table parameter.