Auto Generate Incident Number
Posted: 2014-10-06 13:13
Greetings Guys,
I am trying to find a way to generate an incident number after submission in the hooks file for records keeping purposes.
The incident number needs to be generated on submission due to the real possibility other users may be submitting records at the same time, it should pick the next available number in sequence.
The sequence can be simple with the first 2 digits being the current year ie: 14-00001 and then next one would be 14-00002, as records are inserted. The record number needs to be read only and MUST NOT update if the record is updated, so it should be after insert in my opinion.
Any ideas are appreciated,
Thanks
I am trying to find a way to generate an incident number after submission in the hooks file for records keeping purposes.
The incident number needs to be generated on submission due to the real possibility other users may be submitting records at the same time, it should pick the next available number in sequence.
The sequence can be simple with the first 2 digits being the current year ie: 14-00001 and then next one would be 14-00002, as records are inserted. The record number needs to be read only and MUST NOT update if the record is updated, so it should be after insert in my opinion.
Any ideas are appreciated,
Thanks