Skip to main content
dharmendrag
June 21, 2021
Solved

Document to Base64 conversion using

  • June 21, 2021
  • 5 replies
  • 3 views

Hi All,

In one of my POC I am having requiremnt of converting a document(jpg,pdf) into base64 and storing the base64 in Database.

I am using Base64 to Database Services to store the document, but instead of base64 string it is storing Appian ID itself.

Below are the screenshots of smart service node and database design.

Any comments on this would be appreciated.

Thanks

Table Structure (also I tried Varbinary, blob data type for base64)

Best answer by gayathris111098

Can you try renaming the ACP to 'documentId'? 

and update sql  INSERT INTO book VALUES (:documentId,:title); 

This ACP must be named documentId for the node to complete the conversion.

5 replies

danny.verb
June 21, 2021

Why do you need to store base64 in the database? Using Documents and storing the document ID instead is much better for performance and management.

dharmendrag
June 22, 2021

I agree on your point. I am just trying to explore the smartservice.

gayathris111098
June 21, 2021

Can you try renaming the ACP to 'documentId'? 

and update sql  INSERT INTO book VALUES (:documentId,:title); 

This ACP must be named documentId for the node to complete the conversion.

dharmendrag
June 22, 2021

Thank you. It is working by renaming the ACP to documentId