Skip to main content
September 22, 2023
Question

Excel File

  • September 22, 2023
  • 5 replies
  • 0 views

Hi Team,

When using import CSV to Database smart service, is there a way to update the data after uploading the document

Eg:

In my excel file, I have 3 columns

id, name, updatedon

id and name values will be availble in the csv file, after uploading the file and when writing to DB we need to update the updatedon value with the updatedon time.

    5 replies

    September 22, 2023

    Hello Purvaraj, You can try using the additional columns and additional values of the import CSV to Database smart service to achieve the above requirement.

    Have a look into this link for more info: https://community.appian.com/b/appmarket/posts/excel-tools# 

    September 22, 2023

    How do we pass the values to the additional columns and additional values?

    Can you provide an example?

    stefanhelzle0001
    Brainy
    September 22, 2023

    I suggest to use a staging table for the raw import, then run a stored procedure to post-process the data into its final table.

    mathieud0001
    Brainy
    September 22, 2023

    If this table needs to be available via Records, I would suggest simply selecting all the data and updating the fields via the Write Records service.

    Otherwise, I would simply run an Update statement using the Query Database Smart Service: 

    https://docs.appian.com/suite/help/23.3/Query_Database_Smart_Service.html

    harshas2775
    Brainy
    September 22, 2023

    You can define an After insert trigger on the underlying table to update the updatedon value. That way updated on will be populated automatically after each row insertion in the table.