We have an audit column on a table that stores the current date/time of the last update to that row. Should I be able to use that column as the concurrency column defined in the datasource?

Cheers

asked 03 Mar '15, 10:31

apacheuk's gravatar image

apacheuk
1391223
accept rate: 0%


Hi,

We have tested locally that Formspider supports date columns for concurrency. However, its precision is in seconds. Therefore, if your calls are happening in the same second, concurrency will not work. Apart from that we haven't seen any issue. You can follow the following tutorial about concurrency columns in Formspider:

http://theformspider.com/learningcenter/tutorial-25-concurrency-control-mechanism/

Regards

link

answered 04 Mar '15, 10:23

Serdar's gravatar image

Serdar ♦♦
100k4
accept rate: 14%

Hi,

Yes I think so. Is there a problem?

Kind Regards,

Yalim

link

answered 03 Mar '15, 10:34

Yalim's gravatar image

Yalim ♦♦
2.8k5
accept rate: 21%

ok.... can't seem to get the concurrency to work.

Have set our date_modified field as the concurrency column in the datasource.

and have the followin code that is called when the save buton is hit.

PROCEDURE maintenance_interval_SAVE AS BEGIN api_datasource.doCommit('MAINTENANCE_INTERVAL1'); api_alert.show('CommitComplete'); exception when api_exception.e_concurrencyViolation then api_application.showPopupMessage('show some message here!'); END maintenance_interval_SAVE;

I run up two session (hit the green arrow in the IDE twice) and change the same data in both sessions (its a grid based on a view) hit save in the first session then hit save in the second session don't get any errors and the data just saves. I would have expected the exception to be raised when I hit the save button in the second session.

Simon

link

answered 03 Mar '15, 10:44

apacheuk's gravatar image

apacheuk
1391223
accept rate: 0%

works as expected if I delete the row in the first session, then attempt to update it in the second. Just not if I update in both sessions

link

answered 03 Mar '15, 11:00

apacheuk's gravatar image

apacheuk
1391223
accept rate: 0%

still struggling with this...

Does api_datasource.docommit raise e_concurrencyViolation if it detects the data has changed?

link

answered 04 Mar '15, 08:27

apacheuk's gravatar image

apacheuk
1391223
accept rate: 0%

Figured out what the issue was...

Another developer had disabled the auditing triggers whilst he was doing some other work :) Should have checked a little closer

Sorry for the confusion

link

answered 04 Mar '15, 09:32

apacheuk's gravatar image

apacheuk
1391223
accept rate: 0%

It's not a problem.

(04 Mar '15, 10:24) Serdar ♦♦
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×4

Asked: 03 Mar '15, 10:31

Seen: 1,088 times

Last updated: 04 Mar '15, 10:24


© Copyright Gerger 2017