Auto increment a field
I created a small module using the module builder. I have a numeric ID field. If I go into SQL and set that field as an auto increment field then try to add or edit a record in my module, will that work or will I get an error?
Thanks
Barb
Hi,
Making such a modification to the database is a not a supported scenario and will most likely cause a problem, even if it is not one that is immediately apparent.
What I would suggest instead is to use the IDataEvent and some custom logic that checks whether the ID should be set to the next in order. If so finds the currently last one and sets it to next one.
Regards,
Velizar Bishurov
Telerik