PGoCareerGoCareer prep tools
LoginSign up
  • Java
  • Python
  • AI
  • React
  • Angular
  • PHP
  • Node.js
  • SQL
  • DSA
  • HTML
  • CSS
  • JS
  • Spring
  • ML
  • MongoDB

SQL · Theory

Show Tables

← All stacks

Theory

15/439

Show Tables

SHOW TABLES; lists tables in the current database. USE college; first. SHOW TABLES LIKE 'stu%'; filters names.

information_schema.TABLES is the SQL way if you need to join metadata. For a viva, SHOW TABLES is enough.

Trap — SHOW TABLES in the wrong database — empty list, panic, recreate tables that already exist elsewhere.

On the example next to this theory: Show Tables: create two demo rows, then SELECT qty >= 2 ordered. Say which labels come back.

Exam tip

USE college; SHOW TABLES;

Show Tables — sample query

-- Show Tables
CREATE TABLE demo (
  id INTEGER PRIMARY KEY,
  label TEXT NOT NULL,
  qty INTEGER DEFAULT 0
);
INSERT INTO demo (id, label, qty) VALUES
  (1, 'alpha', 2),
  (2, 'beta', 5);
SELECT label, qty FROM demo WHERE qty >= 2 ORDER BY qty DESC;

Show Tables: create two demo rows, then SELECT qty >= 2 ordered. Say which labels come back.

Short notes

  • DefSHOW TABLES; lists tables in the USE’d database.
  • RuleUSE college; first.
  • TrapLooking in the wrong schema.

Questions

1

How do you list tables?

15 / 439

P

GoCareerGo

Utilities · Preparation Hub · Resume · CV · Tools — one workspace.

Workspace

DashboardProfilePreparation HubResume builderCV builderCareer planning

PDF Tools

Merge PDFSplit PDFCompress PDFImage to PDFAll toolsJobs

Image & QR

Compress ImageResize ImageQR ScannerQR GeneratorBlogIT interview prep

Company

FAQFeedbackContactPrivacyTermsSitemap

© 2026 GoCareerGo. Keep moving forward.