hello guys
here is a little trick of postgresql copy data to other similar table with "insert".
if you have 2 similar table and you want to backup it with a single click from your application you can try this :
for example if u have table employee and employee_backup and you want to copy all of
employee data to employee_backup you can do this query
"insert into employee_backup (select * from employee)".
it works not just for table but also for view.
Tags: