Ravindra BagaleCourses & study guides मराठी Track your progress

Ravi Sir's Cyber Security Cards › Revision Cards

Working with Databases

Working with Databases Basic commands to manage databases: CREATE DATABASE , SHOW DATABASES , USE dbname . In SQL injection, attackers list databases from information_schema . With least privilege, the web app user sees only its own database. Even a successful attack cannot list the others. Forgetti

Working with Databases Basic commands to manage databases: CREATE DATABASE , SHOW DATABASES , USE dbname . In SQL injection, attackers list databases from information_schema . With least privilege, the web app user sees only its own database. Even a successful attack cannot list the others. Forgetti
Working with Databases · Download PNG
Read card text

What this card says

What it is

Basic commands to manage databases: CREATE DATABASE, SHOW DATABASES, USE dbname.

Why it matters for security

In SQL injection, attackers list databases from information_schema.

With least privilege, the web app user sees only its own database. Even a successful attack cannot list the others.

Common mistake

Forgetting USE dbname; and getting “No database selected”. Run it after every login.

Statement typeMeaningExamples
DDL – Data DefinitionStructureCREATE, ALTER, DROP, TRUNCATE, RENAME
DML – Data ManipulationRowsINSERT, UPDATE, DELETE
DQL – Data QueryReadingSELECT
DCL – Data ControlPermissionsGRANT, REVOKE
TCL – Transaction ControlTransactionsSTART TRANSACTION, COMMIT, ROLLBACK

Learn more in the lesson: 10.2 Working with Databases

See all Ravi Sir's Cyber Security Cards