WordPress.org

Make WordPress Core

Opened 13 months ago

Last modified 13 months ago

#44973 new defect (bug)

Issues with $wpdb->get_col_info

Reported by: drocks13 Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 4.9.8
Component: Database Keywords: needs-testing
Focuses: Cc:
PR Number:

Description

When attempting to get certain column information using $wpdb->get_col_info I get the following error notice:

Notice: Undefined property: stdClass::$primary_key in ..../wp-includes/wp-db.php on line 3211

Similar for 'not_null' and several of the other options. Name, type, etc. work just fine. It looks like not all the properties are set for all the options listed in the docs - https://codex.wordpress.org/Class_Reference/wpdb#Getting_Column_Information

Change History (2)

#1 @drocks13
13 months ago

  • Component changed from General to Query

#2 @SergeyBiryukov
13 months ago

  • Component changed from Query to Database
Note: See TracTickets for help on using tickets.