Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

243
Vistas
postgres - Move record from one table to another(same schema) after 24 hours of insertion

I have a table X and another table Y with same schema. When a record is inserted in X, after 24 hours, it should be moved to Y automatically. How can I achieve this in postgres?

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

Postgres does not have such automation, you have to use external tools. Eg, make a cronjob to run the script which will do that, smth like: pslq -d dbname -c "begin; with d as (delete from x where ts < now() - '1 day'::interval returning *) insert into yselect * from d;; end;"

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda