Help get this topic noticed by sharing it on Twitter, Facebook, or email.

Uploading Attachments - invalid cross reference id

Hi there, some issues uploading attachments.
I've replicated attachments down from another org, and transformed the ID fields to those found in the target environment.

Getting an "invalid cross reference id" error thrown on all attachments when pushing. All the ID's map correctly to those in target. Any ideas on what's going wrong?

Load table:
[dbo].[Attachment_Load_Test](
[Id] [nchar](18) NULL,
[Error] [nvarchar](255) NULL,
[Body] [varbinary](max) NOT NULL,
[ContentType] [nvarchar](120) NULL,
[CreatedById] [nchar](18) NULL,
[CreatedDate] [datetime] NOT NULL,
[IsPrivate] [varchar](5) NOT NULL,
[LastModifiedById] [nchar](18) NULL,
[LastModifiedDate] [datetime] NOT NULL,
[Name] [nvarchar](255) NOT NULL,
[OwnerId] [nchar](18) NOT NULL,
[ParentId] [nchar](18) NULL
)

Id NULL
Error invalid cross reference id
Body 0x255...trimmed
ContentType application/pdf
CreatedById 0051O00000CwxHtQAJ (user exists and active)
CreatedDate 2015-04-24 07:19:18.000
IsPrivate false
LastModifiedById 00530000004CnwNAAS (user exists and active)
LastModifiedDate 2015-04-24 07:19:18.000
Name TheAttachment.pdf
OwnerId 00530000004CnwNAAS (owner of oppty in ParentID)
ParentId 0064F000002Soh9QAC (oppty ID)

And here's my command:
EXEC SF_BulkOps 'Insert:batchsize(1)','SALESFORCE','Attachment_Load_Test'

Any advice is welcome!

Thanks!
1 person has
this question
+1
Reply