Friday, September 20, 2024

PostgreSQL command tools

 

Database size

select pg_size_pretty( pg_database_size('dbname') );


Tables order by size

select
  table_name,
  pg_size_pretty(pg_total_relation_size(quote_ident(table_name))),
  pg_total_relation_size(quote_ident(table_name))
from information_schema.tables
where table_schema = 'public'
order by 3 desc;



References:

https://stackoverflow.com/questions/21738408/postgresql-list-and-order-tables-by-size

 


Thursday, September 19, 2024

Video edition issues

 Merge Video and Audio

ffmpeg -i video.mp4 -i audio.mp3 -c:v copy -c:a aac output.mp4

Friday, August 16, 2024

Sunarp consulta partida

 

Obtener numero de partida

https://www.sunarp.gob.pe/bus-personas-juridicas.asp


Consulta partida

https://conoce-aqui.sunarp.gob.pe/conoce-aqui/inicio

Inspect/canvas/copy/Image DATA-URL (to get the page image)

Facturador Sunat SEE SFS (Linux)

    /usr/lib/jvm/java-8-openjdk-amd64/bin/java -jar ./facturadorApp-2.1.jar server prod.yaml References: [1] Make temp certificate for test...