How to upload a file and store it in the Database?

Hi there,

I'm using One Identity Manager v. 8.2 with Web Designer Web Portal. I'm trying to upload a file to web portal and store it in the database.

I have created a table in the DB with this purpose, I have created a DB object collection in the Web Designer Module and I have set the Object type of the collection to the new table I've made. Then I added two properties, one for the file content and one for the file name:

Then I created an upload node, I've set the upload target to Collection and the Collection to the one I made:


Anyway, when I try to compile, I receive the following error:

There is no cursor defined on the collection ExcelData

How could I resolve?

Parents
  • Hi,

    I had exactly the same problem recently. I solved it with the following methodology:
    I created a Single-Row Collection named InputDatas and added a FileName (String) and a Bytes (String) property.

    I parameterized the Upload File node as follows:
    Upload Target: Collection
    Collection: InputDatas
    Property: Bytes
    Collection for file name: InputDatas
    Property for file name: FileName
    I added a Save node under Server Action, where I saved my InputDatas table and added a Code Snippet where I wrote the decoding and processing of the already readable text (this is necessary because the uploaded file is stored in Base64 encoding)

Reply
  • Hi,

    I had exactly the same problem recently. I solved it with the following methodology:
    I created a Single-Row Collection named InputDatas and added a FileName (String) and a Bytes (String) property.

    I parameterized the Upload File node as follows:
    Upload Target: Collection
    Collection: InputDatas
    Property: Bytes
    Collection for file name: InputDatas
    Property for file name: FileName
    I added a Save node under Server Action, where I saved my InputDatas table and added a Code Snippet where I wrote the decoding and processing of the already readable text (this is necessary because the uploaded file is stored in Base64 encoding)

Children
No Data