Fading Coder

One Final Commit for the Last Sprint

SQL Injection CTF Challenge: Extracting Flag from Vulnerable Parameter

Challenge Overview Source: BUUCTF Platform Objective: Retrieve the flag value. Approach The challenge presents a web page with minimal visible content. The URL contains a query parameter ?id=1, indicating this is a standard SQL injection vulnerability. Determining Injection Type First, test whether...

MySQL Basic Operations: Insert and Query Data

1. INSERT Statement (Creating Data) The INSERT statement is used to add new records to a table. Basic Syntax CREATE TABLE employees ( id INT, name VARCHAR(50) ); INSERT INTO employees VALUES (1, 'John'); INSERT INTO employees VALUES (2, 'Alice'); In SQL, both single quotes and double quotes can be u...

Mastering MySQL Fundamentals: A Comprehensive Guide to Core Concepts and Best Practices

Structured Query Language (SQL) is a standardized programming language designed for managing relational databases. It enables users to define, query, manipulate, and control data within database management systems. The term SQL can be pronounced either letter by letter (/ˌɛsˌkjuːˈɛl/) or as a single...

SQL Schema Management and Query Operations

Table Integrity Constraints Enforce data validity through constraint definitions: Unique Constraints Prevent duplicate values in specific columns: ALTER TABLE personnel ADD CONSTRAINT uk_email UNIQUE (email_address); Check Constraints Validate data against boolean expressions: ALTER TABLE personnel...

Dynamic Query Construction Using MyBatis-Plus Wrapper Classes

MyBatis-Plus provides a robust abstraction layer over standard MyBatis operations through its Wrapper API, enabling programmatic SQL generation without XML configuration. The architecture centers around the Wrapper abstract class, which serves as the foundasion for all condition constructors. Class...

Mastering MySQL Table Operations: Insertion, Retrieval, Modification, and Deletion

Data Insertion (INSERT) Adding records to a database table utilizes the INSERT statement. It allows explicit column targeting or full-row insertion. Multiple rows can be added in a single transaction for improved efficiency. INSERT INTO staff_directory (employee_id, department_code, full_name, offic...

Analyzing Ride-Hailing Driver Metrics with SQL Window Functions

Data Schema ride_requests table: user_id: Passenger identifier location: City name request_ts: Timestamp of ride request request_end_ts: Timestamp when request period ends booking_id: Unique order identifier (null until accepted) ride_orders table: booking_id: Unique order identifier user_id: Passen...

Calculating Video Completion Rate Using SQL: A Practical Approach

The objective is to compute the completion rate for each video that had play activity in 2021, rounded to three decimal places, and order the results in descending order. The completion rate is defined as the proportion of plays where the viewing duration was greater than or equal to the video's len...

MySQL Data Query Language and Multi-Table Design

Data Query Language (DQL) DQL (Data Query Language) is used to retrieve records from database tables. The primary keyword for queries is SELECT. Query operations are fundamental in database systems, often used more frequently than insert, update, or delete operations. Data displayed on websites and...

Comprehensive Overview of MySQL Transactions and ACID Properties

ACID Principles of Database Transactions A transaction represents a cohesive unit of database operations that must execute entirely or not at all. This unit adheres to four fundamental principles, commonly abbreviated as ACID. Atomicity: All operations within the work unit are treated as a single in...