Skip to content
all things sql website logo

All Things SQL

All Things Related To SQL, Databases & Cloud Based Solutions

  • Home
  • What is SQL?
  • Contact
  • About
  • Privacy Policy / Disclaimer

primary key vs foreign key

All Things SQL 

Comparing Primary Keys VS Foreign Keys

comparing foreign and primary keys, comparing primary and foreign keys, foreign vs primary key sql, primary and foreign key differences sql, primary key vs foreign key, primary vs foreign key sql, primary vs foreign key sql difference between primary and foreign key, sql foreign vs primary keys, sql primary and foreign key differences, sql primary foreign key comparison, sql primary vs foreign key

Relational databases that we use to write our SQL database queries contain tables. These tables will almost undoubtedly contain keys.

Read more

Start Learning SQL

  • SELECT – Start Here
  • DISTINCT and COUNT – The Basics
  • WHERE – Using Filters
  • AND Versus OR Operators
  • Parentheses – Order of Operations
  • JOIN – Inner Join and Aliases
  • WHERE – Joining Tables
  • JOIN – Left, Right, and Full Outer
  • GROUP BY – Count, Sum, and More
  • HAVING – Filtering Aggregates
  • ORDER BY – Sorting Results
  • UNION ALL – Combining Datasets
  • MINUS – Subtracting Datasets

Advanced SQL

  • CAST & CONVERT – Modifying Data Types
  • CONCAT – Combining Multiple Columns
  • INSERT – Using SELECT Statement
  • CASE Statement – Replacing If-Else
  • LEAD() Function – Getting Next Values
  • LAG() Function – Getting Previous Values

DML & DDL Examples

  • DDL vs DML – A Comparison
  • CREATE TABLE – Examples
  • ALTER TABLE – Add, Drop, & Modify Columns
  • TRUNCATE vs DELETE – Erasing Tables
  • DROP – Tables, Views, Etc. – Deleting Objects

Common SQL Problems

  • Finding Duplicates
  • Getting Today’s Date

Data Warehousing

  • Fact Tables vs Dimension Tables
  • Slowly Changing Dimensions
  • OLAP vs OLTP Databases
Copyright © 2023 All Things SQL. All rights reserved.
Theme: ColorMag by ThemeGrill. Powered by WordPress.