transceiver-db/sql/040-switch-facts-seed.sql
Rene Fichtmueller 21f5250353 feat: switch facts — migration 040 seeds power/weight/certifications + dashboard shows them
- Migration 040: seeds rack_units, typical_power_w, max_power_w, weight_kg, certifications
  for 23 initial switches (Cisco Nexus/Catalyst, Arista, Juniper, NVIDIA, Edgecore/Celestica/Asterfusion)
- Dashboard: Specifications section now shows Typical Power, Weight, Certifications (colored pills)
2026-04-20 22:56:53 +02:00

124 lines
5.1 KiB
SQL

-- TIP: Migration 040 — Switch Physical Facts Seed
-- Populates rack_units, typical_power_w, max_power_w, weight_kg, certifications
-- for the 24 initial seeded switches.
-- ─── Cisco Nexus 9300 / 9500 / 9200 ────────────────────────────────────────
UPDATE switches SET
rack_units = 1, typical_power_w = 340, max_power_w = 400, weight_kg = 16.8,
certifications = ARRAY['CE','FCC','RoHS','NEBS L3','UL']
WHERE model = 'N9K-C9364C';
UPDATE switches SET
rack_units = 1, typical_power_w = 550, max_power_w = 650, weight_kg = 18.2,
certifications = ARRAY['CE','FCC','RoHS','NEBS L3','UL']
WHERE model = 'N9K-C93600CD-GX';
UPDATE switches SET
rack_units = 1, typical_power_w = 410, max_power_w = 500, weight_kg = 16.5,
certifications = ARRAY['CE','FCC','RoHS','NEBS L3','UL']
WHERE model = 'N9K-C9316D-GX';
UPDATE switches SET
rack_units = 1, typical_power_w = 650, max_power_w = 800, weight_kg = 17.2,
certifications = ARRAY['CE','FCC','RoHS','NEBS L3','UL']
WHERE model = 'N9K-C9332D-H2R';
UPDATE switches SET
rack_units = 7, typical_power_w = 850, max_power_w = 1400, weight_kg = 41.0,
certifications = ARRAY['CE','FCC','RoHS','NEBS L3','UL']
WHERE model = 'N9K-C9508';
UPDATE switches SET
rack_units = 1, typical_power_w = 480, max_power_w = 600, weight_kg = 18.0,
certifications = ARRAY['CE','FCC','RoHS','NEBS L3','UL']
WHERE model = 'N9K-C9364D-GX2A';
UPDATE switches SET
rack_units = 1, typical_power_w = 310, max_power_w = 380, weight_kg = 7.9,
certifications = ARRAY['CE','FCC','RoHS','UL']
WHERE model = 'N9K-C9232C';
-- ─── Arista 7000 series ─────────────────────────────────────────────────────
UPDATE switches SET
rack_units = 1, typical_power_w = 480, max_power_w = 600, weight_kg = 20.1,
certifications = ARRAY['CE','FCC','RoHS','UL']
WHERE model = '7060CX2-32S';
UPDATE switches SET
rack_units = 1, typical_power_w = 510, max_power_w = 640, weight_kg = 21.5,
certifications = ARRAY['CE','FCC','RoHS','UL']
WHERE model = '7060DX4-32';
UPDATE switches SET
rack_units = 1, typical_power_w = 720, max_power_w = 900, weight_kg = 22.8,
certifications = ARRAY['CE','FCC','RoHS','UL']
WHERE model = '7800R3-36P-LINE';
UPDATE switches SET
rack_units = 1, typical_power_w = 650, max_power_w = 800, weight_kg = 23.0,
certifications = ARRAY['CE','FCC','RoHS','UL']
WHERE model = '7060X6-64PE';
UPDATE switches SET
rack_units = 1, typical_power_w = 450, max_power_w = 560, weight_kg = 19.5,
certifications = ARRAY['CE','FCC','RoHS','UL']
WHERE model = '7050CX3-32S';
-- ─── Juniper QFX / EX ───────────────────────────────────────────────────────
UPDATE switches SET
rack_units = 1, typical_power_w = 380, max_power_w = 480, weight_kg = 12.7,
certifications = ARRAY['CE','FCC','RoHS','NEBS','UL']
WHERE model = 'QFX5130-32CD';
UPDATE switches SET
rack_units = 1, typical_power_w = 420, max_power_w = 520, weight_kg = 13.5,
certifications = ARRAY['CE','FCC','RoHS','NEBS','UL']
WHERE model = 'QFX5200-32C';
UPDATE switches SET
rack_units = 1, typical_power_w = 280, max_power_w = 350, weight_kg = 10.2,
certifications = ARRAY['CE','FCC','RoHS','NEBS','UL']
WHERE model = 'EX4650-48Y';
-- ─── NVIDIA Spectrum ────────────────────────────────────────────────────────
UPDATE switches SET
rack_units = 1, typical_power_w = 530, max_power_w = 660, weight_kg = 17.3,
certifications = ARRAY['CE','FCC','RoHS','UL']
WHERE model = 'SN5600';
UPDATE switches SET
rack_units = 1, typical_power_w = 600, max_power_w = 750, weight_kg = 18.6,
certifications = ARRAY['CE','FCC','RoHS','UL']
WHERE model = 'SN4700';
UPDATE switches SET
rack_units = 1, typical_power_w = 290, max_power_w = 360, weight_kg = 14.0,
certifications = ARRAY['CE','FCC','RoHS','UL']
WHERE model = 'SN2010M';
-- ─── Edgecore / Celestica / Asterfusion ─────────────────────────────────────
UPDATE switches SET
rack_units = 1, typical_power_w = 420, max_power_w = 520, weight_kg = 14.8,
certifications = ARRAY['CE','FCC','RoHS']
WHERE model = 'AS7726-32X';
UPDATE switches SET
rack_units = 1, typical_power_w = 500, max_power_w = 620, weight_kg = 15.5,
certifications = ARRAY['CE','FCC','RoHS']
WHERE model = 'AS9516-32D';
UPDATE switches SET
rack_units = 1, typical_power_w = 450, max_power_w = 560, weight_kg = 15.0,
certifications = ARRAY['CE','FCC','RoHS']
WHERE model = 'DCS810';
UPDATE switches SET
rack_units = 1, typical_power_w = 490, max_power_w = 600, weight_kg = 14.9,
certifications = ARRAY['CE','FCC','RoHS']
WHERE model = 'CX308P-48YN';
UPDATE switches SET
rack_units = 1, typical_power_w = 520, max_power_w = 640, weight_kg = 16.2,
certifications = ARRAY['CE','FCC','RoHS']
WHERE model = 'CX564P';