0
I created this script to clear the bank table and reset id's.
It works, but not in the right way
It runs and authenticates on psql. but instead of running the commands sql it only opens the psql.
If anyone has a way out I’d appreciate it.
@echo off
set PGUSER=####
set PGPASSWORD=#####
echo on
"D:\Programas\PostgreSQL\10\bin\psql.exe" -h localhost -p 5432 -U postgres pauliceia delete from bairros;
"D:\Programas\PostgreSQL\10\bin\psql.exe" -h localhost -p 5432 -U postgres pauliceia alter table bairros AUTO_INCREMENT = 1;
the script q vc says, is a . Bat ? see syntax: https://www.postgresql.org/docs/9.2/static/app-psql.html
– Rovann Linhalis