Dataford
Interview QuestionsInterview GuidesExperiencesMock InterviewsPricing
Get started
Drop Table Query
00:00
5 left

Drop Table Query

EasySQL · PostgreSQL

Problem

Write a SQL query to drop a table.

Use PostgreSQL syntax to remove the staging_orders table. The submitted SQL must also return a confirmation row so the execution result can be verified.

Output

  1. Return one row with the column dropped_table.
  2. The value must be staging_orders.
  3. The table must be removed before the confirmation is returned.

Schema

staging_orders
ColumnTypeDescription
order_idPKINTEGERUnique staging order identifier
order_referenceVARCHAR(30)External order reference
load_statusVARCHAR(20)Current staging load status
source_systemVARCHAR(30)System that supplied the staging record
Tablesstaging_orders
Interviewer

Your question is Drop Table Query. Start with the requirements and the one table in the Question tab.

Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.

You need to log in / sign up to run or submit.
CodePostgreSQL
You need to log in / sign up to run or submit.Ln 1
Run your query to see results here.