const postgres = require('postgres');
const sql = postgres(process.env.DATABASE_URL || 'postgresql://jumpa_admin:JumpaS3cur3%21%40%23@localhost:5432/jumpadb');

async function main() {
  try {
    await sql`UPDATE tenants SET media_engine_strategy = 'XCU_DIRECTOR' WHERE media_engine_strategy = 'xcom_ultra_ENGINE'`;
    console.log('Database updated successfully: xcom_ultra_ENGINE -> XCU_DIRECTOR');
  } catch (error) {
    console.error('Failed to patch database:', error);
  } finally {
    await sql.end();
  }
}
main();
