The solution to the multi-digit problem when inserting SQL: handle it in the program. If there is an insert operation to the table in the program, after the insert operation is completed, query the number of records in the table. If it exceeds the number you set, delete the previous data using the delete operation.
Insert is to insert a new piece of data, which will create a new record. Update is to update an existing piece of data, and it will not create a new record.