Schema Update — May 2026 (55 Net-New Columns)

Overview

This page documents 55 net-new columns added to the defect_report table. These columns were present in the schema but had not been documented in the data dictionary. Definitions have been added to the Vendor data dictionary in Airtable as of May 2026.

Column List

SQL Column Name Data Type Description
appointment_creation_date timestamp with time zone Date the inbound delivery appointment was created in the scheduling system
source_creation_date timestamp with time zone Date the source record (e.g., PO or shipment) was originally created in the upstream system
vcbs_vc_attribute_gl_header Character Varying General Ledger header attribute from Vendor Central used for financial categorization of the transaction
invoice_number Character Varying Vendor-assigned invoice number associated with the shipment or order
vendor_invoice_id Character Varying Amazon-assigned identifier for the vendor invoice record
shipper_asn_id Character Varying Identifier for the ASN as provided by the shipper
report_date timestamp with time zone Date associated with the reporting period for this defect record
received_date timestamp with time zone Date the shipment was physically received at the fulfillment center
appointment_status Character Varying Current status of the delivery appointment (e.g., scheduled, completed, cancelled, no-show)
product_height Double Precision Height of the product unit
product_length Double Precision Length of the product unit
product_weight Double Precision Weight of the product unit
product_width Double Precision Width of the product unit
defect_root_cause Character Varying Identified root cause category for the defect or compliance issue
appointment_slots_available Integer Number of available appointment slots at the time of scheduling
appointment_trailer_id Character Varying Identifier for the trailer associated with the delivery appointment
asn_creation_date timestamp with time zone Date the Advance Shipment Notice (ASN) was created
asn_expiration_date timestamp with time zone Date on which the ASN expires and is no longer valid for receiving
asn_updated_date_first timestamp with time zone Timestamp of the first update made to the ASN record
asn_updated_date_last timestamp with time zone Timestamp of the most recent update made to the ASN record
booking_request_deadline timestamp with time zone Deadline by which the freight booking request must be submitted
booking_request_id Character Varying Identifier for the freight booking request submitted to Amazon Transportation
business_group Character Varying Business group or segment classification for the vendor or product line
debit_note_id Character Varying Identifier for a debit note issued to the vendor, typically related to a chargeback or shortage
estimated_cargo_delivery_date timestamp with time zone Estimated date the cargo is expected to be delivered to the fulfillment center
fc_country Character Varying Country in which the destination fulfillment center is located
ffp_sioc_compliance Character Varying Indicates whether the product meets Frustration-Free Packaging (FFP) or Ships in Own Container (SIOC) requirements
ffp_sioc_excluded_due_to_dimensions Character Varying Indicates whether the product was excluded from FFP/SIOC compliance evaluation due to dimensional constraints
first_booking_date timestamp with time zone Earliest booking date recorded for this shipment
first_ship_date timestamp with time zone Earliest ship date recorded for this shipment
flag_pallet_ordering_program_vendor Character Varying Flag indicating whether the vendor participates in Amazon's Pallet Ordering Program
frd timestamp with time zone Freight Ready Date — the date the vendor indicated the freight would be ready for carrier pickup
freight_type Character Varying High-level freight mode classification (e.g., LTL, FTL, small parcel)
freight_type_detail Character Varying Additional detail describing the freight type or mode of transport
gtin_goldlist_compliance Character Varying Indicates whether the product's GTIN is compliant with Amazon's GTIN goldlist requirements
inbound_shipment_appointment_id Character Varying Reference identifier for the inbound shipment appointment at the fulfillment center
is_drop Character Varying Flag indicating whether this is a drop shipment (vendor ships directly to customer)
is_kraken Character Varying Flag indicating whether this shipment was processed through Amazon's Kraken inbound system
load_type Character Varying Type of load for the shipment (e.g., floor-loaded, palletized)
original_fc_shipment_destination Character Varying Originally assigned fulfillment center destination before any rerouting
pallet_id_or_box_id Character Varying Identifier for the pallet or individual box associated with this record
past_12_week_denominator Integer Denominator used to calculate the trailing 12-week defect rate (total eligible shipments or units)
past_12_week_numerator Integer Numerator used to calculate the trailing 12-week defect rate (defective shipments or units)
pick_up_date timestamp with time zone Date the carrier picked up the shipment from the vendor's location
ready_to_ship_eligible Character Varying Indicates whether the item is eligible for Amazon's Ready to Ship program
rescheduled_datetime timestamp with time zone Timestamp when the delivery appointment was rescheduled
sample_po_asin_use_similar_scanned_label Character Varying Flag indicating whether a similar scanned label was used for a sample PO/ASIN
scanned_label_list_all Character Varying List of all scanned label identifiers associated with the shipment
scheduled_arrival_date timestamp with time zone Planned arrival date for the shipment at the fulfillment center
shipping_method Character Varying Method of shipment (e.g., small parcel, LTL, FTL, intermodal)
sla_date timestamp with time zone Service Level Agreement date — the deadline by which the shipment must arrive or action must be taken
vamp_event_id Character Varying Identifier for the event in Amazon's Vendor Audit Management Platform (VAMP)
vendor_state Character Varying State or operational status of the vendor account (e.g., active, suspended)
vrid_original_shipmode Character Varying Vendor Routing Instruction ID and the originally assigned ship mode for the shipment
window_time_zone Character Varying Time zone associated with the delivery appointment or scheduling window

Querying Financial Impact by Issue Type Group

For certain chargeback types, Amazon creates two rows for the same event — a Chargeback row (CB) and a Record row (REC). Summing financial_charge across all rows without accounting for this will double-count charges.

CB row = the billing record (carries the invoice number and finalization status)

REC row = the operational record (what Amazon's compliance system generated when the defect was identified)

Which row holds the dollar amount depends on the issue type — that's what determines the query approach for each group below.

Group 1 — Single source, use as-is

Issue types: Everything except Receiving Accuracy and PO on-time accuracy. No dedup needed — take financial_charge directly.

One wrinkle for In Full Delivery: Amazon may assign the same VAMP to two rows on the same PO+ASIN — one CHARGED and one WAIVED. These are not duplicates; they are separate line items. Keep both and sum them, or filter by status depending on the use case.

-- Group 1: All issue types except those requiring dedup
SELECT
    issue_type,
    status,
    COUNT(*)              AS chargeback_count,
    SUM(financial_charge) AS total_charge
FROM defect_report
WHERE _partneruuid = '<uuid>'
  AND issue_type NOT IN ('Receiving Accuracy', 'PO on-time accuracy')
  AND financial_charge > 0
GROUP BY issue_type, status
ORDER BY issue_type, total_charge DESC;

Group 2 — Paired via VAMP, CB carries the charge

Issue types: Receiving Accuracy, PO on-time accuracy

VAMP links a CB row to a REC row (or the CB row is a singleton with no REC counterpart). The financial truth lives on the CB side — financial_charge is non-zero there, and charge_invoice_# and finalization_status are on CB as well. Deduplicate by keeping one row per VAMP, preferring CB.

-- Group 2: Keep only FINALIZED rows (CB rows) — excludes REC rows
SELECT
    issue_type,
    infraction_subtype_code,
    COUNT(*)                AS chargeback_count,
    SUM(financial_charge)   AS total_charge
FROM defect_report
WHERE _partneruuid = '<uuid>'
  AND issue_type IN ('Receiving Accuracy', 'PO on-time accuracy')
  AND finalization_status = 'FINALIZED'
GROUP BY issue_type, infraction_subtype_code
ORDER BY total_charge DESC;
Note: Filtering on finalization_status = 'FINALIZED' cleanly isolates CB rows and excludes REC rows for these issue types, without relying on issue_id ranges.

Group 3 — Paired via VAMP, REC carries the charge

Issue types: shipment (lowercase)

CB rows exist but carry financial_charge = 0 — they are ghost records (FINALIZED, no invoice). The actual dollar amount lives on the REC row. CB-only singletons are also $0 and can be ignored entirely. Always pull from REC.

-- Group 3: REC rows only (excludes FINALIZED CB ghost rows)
SELECT
    issue_type,
    infraction_subtype_code,
    COUNT(*)                AS chargeback_count,
    SUM(financial_charge)   AS total_charge
FROM defect_report
WHERE _partneruuid = '<uuid>'
  AND issue_type = 'shipment'
  AND finalization_status != 'FINALIZED'
GROUP BY issue_type, infraction_subtype_code
ORDER BY total_charge DESC;

Combined query across all groups

Use this when you want a single deduplicated view of total financial impact across all issue types.

SELECT
    issue_type,
    infraction_subtype_code,
    COUNT(*)              AS chargeback_count,
    SUM(financial_charge) AS total_charge
FROM defect_report
WHERE _partneruuid = '<uuid>'
  AND financial_charge > 0
  AND (
    -- Group 1: all other issue types, no dedup needed
    issue_type NOT IN ('Receiving Accuracy', 'PO on-time accuracy', 'shipment')
    -- Group 2: CB rows only
    OR (issue_type IN ('Receiving Accuracy', 'PO on-time accuracy') AND finalization_status = 'FINALIZED')
    -- Group 3: REC rows only
    OR (issue_type = 'shipment' AND finalization_status != 'FINALIZED')
  )
GROUP BY issue_type, infraction_subtype_code
ORDER BY total_charge DESC;
Important: The casing of issue_type is significant. 'Shipment' (capital S, Group 1) and 'shipment' (lowercase, Group 3) are different issue types with different dedup behavior. Run SELECT DISTINCT issue_type FROM defect_report to confirm exact values in your data before using these queries.
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.