Giao diện
content_report / report
Trang sinh tự động
Sinh từ ad83b0aea — chạy 820 migration lên PostgreSQL 17 rồi đọc pg_catalog. Mô tả bảng và cột lấy từ COMMENT ON. Không sửa tay: lần chạy docgen sau sẽ ghi đè.
2 bảng. Quay lại content_report.
report_export_jobs
P4-21. One report export request: frozen filters and window, status machine, private file reference. No figures.
public.report_export_jobs · 32 cột · 18 check · 0 unique · 4 index · 1 policy · 8 trigger · RLS bật
| Cột | Kiểu | Khoá | Mô tả | |
|---|---|---|---|---|
id | uuid | NOT NULL | PK | |
requester_account_id | uuid | NOT NULL | FK → accounts | |
report_code | text | NOT NULL | ||
filters | jsonb | NOT NULL | ||
from_at | timestamptz | NOT NULL | ||
to_at | timestamptz | NOT NULL | ||
filter_hash | text | NOT NULL | ||
money | boolean | NOT NULL | ||
pii_mode | text | NOT NULL | ||
ttl_seconds | integer | NOT NULL | ||
status | text | NOT NULL | ||
attempt | integer | NOT NULL | ||
failure_code | text | |||
correlation_id | correlation_ref | NOT NULL | ||
run_id | uuid | |||
requested_at | timestamptz | NOT NULL | ||
started_at | timestamptz | |||
finished_at | timestamptz | |||
data_cutoff | timestamptz | |||
row_count | integer | |||
source_status | text | |||
sources | jsonb | |||
policies | jsonb | |||
file_name | text | |||
size_bytes | integer | |||
sha256 | text | |||
bucket | text | |||
storage_path | text | |||
expires_at | timestamptz | |||
purged_at | timestamptz | |||
version | integer | NOT NULL | ||
updated_at | timestamptz | NOT NULL |
Khoá chính: id
Trỏ ra (1):
requester_account_id→accounts·ON DELETE RESTRICT
Được trỏ tới (1): report_export_snapshots
report_export_snapshots
P4-21 immutable masked read-time snapshot shared by every attempt.
public.report_export_snapshots · 3 cột · 1 check · 0 unique · 1 index · 0 policy · 2 trigger · RLS bật
| Cột | Kiểu | Khoá | Mô tả | |
|---|---|---|---|---|
job_id | uuid | NOT NULL | PK FK → report_export_jobs | |
payload | jsonb | NOT NULL | ||
created_at | timestamptz | NOT NULL |
Khoá chính: job_id
Trỏ ra (1):
job_id→report_export_jobs·ON DELETE RESTRICT
Được trỏ tới: không có