BEGIN TRANSACTION;
 INSERT INTO registro_rota_ponto (id, cod_registro_rota, geom, dat_registro_ponto, num_elevacao, velocidade, status) 
                VALUES (nextval('registro_rota_ponto_id_seq'), 48124, 'SRID=4674;POINT (-38.611437622458 -3.6908925231546)', '2026-08-06 15:16:14', -10.799987792969, 0, 'deslocando'); 
 INSERT INTO registro_rota_ponto (id, cod_registro_rota, geom, dat_registro_ponto, num_elevacao, velocidade, status) 
                VALUES (nextval('registro_rota_ponto_id_seq'), 48124, 'SRID=4674;POINT (-38.611498391256 -3.6908055189997)', '2026-08-06 15:16:32', -3.7999877929688, (SELECT ST_DistanceSphere(GeomFromEWKT('SRID=4674;POINT (-38.611437622458 -3.6908925231546)'), GeomFromEWKT('SRID=4674;POINT (-38.611498391256 -3.6908055189997)'))) / (select extract(epoch from '2026-08-06 15:16:32'::timestamp) - extract(epoch from '2026-08-06 15:16:14'::timestamp)),  CASE WHEN ((SELECT ST_DistanceSphere(GeomFromEWKT('SRID=4674;POINT (-38.611437622458 -3.6908925231546)'), GeomFromEWKT('SRID=4674;POINT (-38.611498391256 -3.6908055189997)'))) / (select extract(epoch from '2026-08-06 15:16:32'::timestamp) - extract(epoch from '2026-08-06 15:16:14'::timestamp))) < 1 THEN  'pescando' ELSE 'deslocando' END ); 
 INSERT INTO registro_rota_ponto (id, cod_registro_rota, geom, dat_registro_ponto, num_elevacao, velocidade, status) 
                VALUES (nextval('registro_rota_ponto_id_seq'), 48124, 'SRID=4674;POINT (-38.61152311787 -3.6907410621643)', '2026-08-06 15:16:37', 4.3999938964844, (SELECT ST_DistanceSphere(GeomFromEWKT('SRID=4674;POINT (-38.611498391256 -3.6908055189997)'), GeomFromEWKT('SRID=4674;POINT (-38.61152311787 -3.6907410621643)'))) / (select extract(epoch from '2026-08-06 15:16:37'::timestamp) - extract(epoch from '2026-08-06 15:16:32'::timestamp)),  CASE WHEN ((SELECT ST_DistanceSphere(GeomFromEWKT('SRID=4674;POINT (-38.611498391256 -3.6908055189997)'), GeomFromEWKT('SRID=4674;POINT (-38.61152311787 -3.6907410621643)'))) / (select extract(epoch from '2026-08-06 15:16:37'::timestamp) - extract(epoch from '2026-08-06 15:16:32'::timestamp))) < 1 THEN  'pescando' ELSE 'deslocando' END ); 
COMMIT TRANSACTION;
