How to Find Tables Without Primary Keys Via information_schema (Doc ID 2081186.1)

Last updated on MAY 09, 2017

Applies to:

MySQL Server - Version 5.1 and later
Information in this document applies to any platform.

Goal

Find all user-defined tables with no primary key defined.

Solution

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms