I have an edit form bound to a mysql database. I can edit records fine, but I can't create new records unless I display the id field and enter something. id is the key field in the table and is set to auto-increment. I set the required flag for the field to false and it still doesn't work unless I enter a number in the id field on the form.
Ideally, I wouldn't even show the id field on the form and it would just be created and auto-incremented when the record gets inserted. What am I doing wrong?
Hi @kman42 ,
If you cannot create new record, did you encounter any error message while submitting a new record via edit form?
You could add the id field to the edit form, then set its Visible property to false and then have a try.
Check if below thread has any information that might help:
I'm still trying to create a workaround for this issue. I'm trying to set the default value for the id card to the parent value if the form is in edit mode and to the max value of the database field +1 if it is in new mode.
This results in:
The function Max has some invalid arguments. Invalid argument type (Table). Expecting a Number value instead.
id is an integer.
Learn how to create your own user groups today!
Check out the new Power Platform Community Connections gallery!
Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.