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

Issue Loading PDF into FeedItem table

Hi,

I'm trying to load a PDF file into the FeedItem table with the below code, I've managed to get this working fine with the Apex DataUploader but I can't get it working with DBAmp, an item is created but when I view this on salesforce the PDF file is corrupt.

Has anyone had any luck uploading a PDF file into the FeedItem table with DBAmp?

-------------------------------------------------

USE [salesforce backups]

CREATE TABLE [dbo].[FeedItem_Insert]
(
[Id] [nchar](18) NULL ,
[Error] [nvarchar](255) NULL ,
[ContentType] [nvarchar](120) NULL ,
[Title] [nvarchar](255) NOT NULL ,
[ParentId] [nchar](18) NOT NULL ,
[Body] [nvarchar](255) NULL ,
[ContentData] [nvarchar](255) NOT NULL ,
[ContentFileName] [nvarchar](255) NOT NULL
)
GO

INSERT INTO [FeedItem_Insert]
( [Id] ,
[Error] ,
[ContentType] ,
[ParentId] ,
[Body] ,
[ContentData] ,
[ContentFileName] ,
[Title]
)
VALUES ( '' ,
'' ,
'PDF' ,
'005b0000000ieftAAA' ,
'Test PDF File' ,
'E:\PDFUpload.pdf' ,
'PDFUpload.pdf' ,
'PDFUpload'
)
GO

EXEC SF_BulkOps 'Insert', 'SALESFORCE', 'FeedItem_Insert'

-------------------------------------------------

Thanks

Matt
1 person has
this problem
+1
Reply