[wp-trac] [WordPress Trac] #45936: Insert empty record

WordPress Trac noreply at wordpress.org
Fri Jan 11 10:51:52 UTC 2019


#45936: Insert empty record
-------------------------------+------------------------------
 Reporter:  maximeschoeni      |       Owner:  (none)
     Type:  defect (bug)       |      Status:  new
 Priority:  normal             |   Milestone:  Awaiting Review
Component:  General            |     Version:
 Severity:  normal             |  Resolution:
 Keywords:  reporter-feedback  |     Focuses:
-------------------------------+------------------------------
Changes (by subrataemfluence):

 * keywords:   => reporter-feedback


Comment:

 Your suggestion does fix the issue of inserting empty record.
 But what could be a working situation where you might need to insert an
 empty record? An example would be good.

 Also if a numeric `Primary Key` is present in the table and it is not auto
 incremental, trying to insert multiple empty records will throw duplicate
 primary key error.
 Because it will try to add `0` in the primary key.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/45936#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list