Tell HN: Laravel's default truncate method uses cascade for Postgres databases

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

Our great sponsors
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • SaaSHub - Software Alternatives and Reviews
  • Laravel

    The Laravel Framework.

  • Hope this saves a future team from unexpected behavior resulting in (potential) production data loss.

    When using Postgres, Laravel's default method for truncate uses the cascade option, which will ignore foreign key constraints and potentially wipe large amounts of data with no confirmation or warning.

    It was originally introduced in 2018: https://github.com/laravel/framework/pull/26389/files

    Here are two threads on it if you are curious: https://github.com/laravel/framework/issues/29506

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts