Deleting all rows using delete from data store entity

Hi,

I am trying to delete all the existing rows from the data entity using delete from data store entity smart service. Can anyone please suggest me what to include in identifiers if we want to delete everything without specifying all the identifiers?

Thanks

Yeswanth.

  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Lead Developer

    Hi Yeswanth,

    As per my understanding, Stored Procedure is the best option to perform this operation on DB. Also, few points to consider here:

    Dis-advantages of Query Database Smart Service

    1. No doubt, Query Database smart service can also do this Job, but it's not recommended by Appian

    2. When you are using Query Database smarts service, you need to write native SQL query/queries and hence any changes in DB Vendor or your requirement, will need you to modify the configuration of this smart service. However you can use environment constant to define the queries but still you need to update the Appian Object, some or the other way. 

     

    Advantage of Procedure

    1. Once this query executes, the scheduling responsibility for completing the job will be taken care by DB Engines instead of Appian

    2. Any Changes in requirement will need us to just modify the SQL script in DB side hence our Appian objects will remain unchanged.

    3. We can execute the procedure on the Interface using a function as well as inside the process using the smart service, means we have an opportunity to perform this operation on Interface as well as Process Level.

    4. Performance wise it's much better.

     

    Hope the above comparison, will give you the idea about why Stored Procedure stands better while compared to Query DB Smart Service.

Reply
  • 0
    Certified Lead Developer

    Hi Yeswanth,

    As per my understanding, Stored Procedure is the best option to perform this operation on DB. Also, few points to consider here:

    Dis-advantages of Query Database Smart Service

    1. No doubt, Query Database smart service can also do this Job, but it's not recommended by Appian

    2. When you are using Query Database smarts service, you need to write native SQL query/queries and hence any changes in DB Vendor or your requirement, will need you to modify the configuration of this smart service. However you can use environment constant to define the queries but still you need to update the Appian Object, some or the other way. 

     

    Advantage of Procedure

    1. Once this query executes, the scheduling responsibility for completing the job will be taken care by DB Engines instead of Appian

    2. Any Changes in requirement will need us to just modify the SQL script in DB side hence our Appian objects will remain unchanged.

    3. We can execute the procedure on the Interface using a function as well as inside the process using the smart service, means we have an opportunity to perform this operation on Interface as well as Process Level.

    4. Performance wise it's much better.

     

    Hope the above comparison, will give you the idea about why Stored Procedure stands better while compared to Query DB Smart Service.

Children
No Data