Updating Appointment after update of underlying row

Posted by: SHanau on 10 February 2022, 2:26 am EST

    • Post Options:
    • Link

    Posted 10 February 2022, 2:26 am EST

    Hi,

    My MySQL database table of appointsments comprises of more than just those fields used by C1Schedule. Frequently those additional fields are updated from outside of C1Schedule as we are working in a multi-user environment. Sometimes an error occurs within C1Schedule stating that the underlying datarow has been updated and therefore can’t be updated by C1Schedule at the moment.

    Is there a way to update a single appointment’s reference to the underlying data in order to avoid such incidences ? Thanks in advance,

    Stephan

  • Posted 10 February 2022, 10:12 pm EST

    Hi Stephan,

    We could not replicate the issue at our end. Could you please provide the version of the C1Schedule you are using and a gif showing the issue so that we can investigate further?

    Regards

    Avnish

  • Posted 29 March 2022, 11:42 pm EST

    Hi Avnish,

    Thanks a lot for your speedy response. In the meantime I’ve investigated the above mentioned behaviour and have found a way to deal with this phenomenon. But I’ve got another question nevertheless:

    Given a scenario where multiple users use the C1Schedule to add and edit appointments constantly throughout the day. Is there a way to determine whether Workplace A has altered the underlying database row of an appointment in order to re-fetch the appointment’s data in case Workplace B tries to edit the same appointment?

    Thanks in advance.

  • Posted 30 March 2022, 11:40 pm EST

    Hi Stephan,

    To maintain the concurrency between the Appointments fetched in the C1Schedule and the Appointments stored in the Database, you can add an extra column in your MySQL table which will maintain a row version whenever the appointment gets updated through any Workplace. You will need to create a service layer between the C1Schedule application and the Database which will handle the update of the row version whenever the row is updated through any Workplace. Then, whenever an appointment is updated in the C1Schedule, you can fetch that row from the database to check if the current row version is similar to the fetched version and cancel/commit the updates accordingly.

    Kind Regards,

    Kartik

  • Posted 1 April 2022, 10:41 pm EST

    Hi Kartik,

    Thanks very much for your support.

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels