Skip to main content
September 19, 2022
Question

Unable to understand how to update data on 2 tables simultaneously

  • September 19, 2022
  • 7 replies
  • 0 views

I am working on EPIC 2 ( Bids & Auction Houses) of the Appian Applied Development Course. In the user story 7 to enter bid decision if the bid is awarded , i need to update vehicle availability on AA_Vehicle table and also update bid information on the bids table.

I have flat end CDT . in the bids CDT, vehicleId  is just a integer field

I tried to create a process variables to update the vehicle availability status. In the process property i created a new process variable called Vehicle and it's of type AA_Vehicle CDT.

In the write to data store entity to vehice table, before this block i had a script task which gives me the vehicle I'd field from the AA_Vehicle .

Please if anyone can send me the screenshot on how to proceed it would be of great help

Thanks in advance

    7 replies

    September 19, 2022

    Could anybody help me in this regard?

    September 19, 2022

    Hi mansav, once you have a vehicle id use a script task to query the data of AA_vehicle using the id and then use update dictionary to update the status.

    September 19, 2022

    Should I use rule!GetVehicleById(pv! vehicle.vehicleId) as a expression on the output of script task ?

    September 19, 2022

    Get the vehicle ID from the bids table then query the data using the script task please don't forget to index the data in query in the output store the data in AA_vehicle and plug a write to datastore after that.