Friday, October 24, 2014

query to check the transaction that are currently roll back/executing on Netezza

use
nz_transactions

how to find netezza system state?

use
nzstate

How to find locks on Netezza database?

use nz_show_locks <db name> <tablename>

how to find netezza database version ?

use nz_rev

How to automatically compress the log files and un used files under /nz directoty on NPS

schedule the below script for every week to run it will compress the files and it will not affect the running NPS.
nz_compress_old_files

How to check if the view is valid or not in NPS?


heck each VIEW to make sure it is not obsolete and in need of rebuilding .
nz_check_views  [ database ]  [-replace <flag>]

How to get the information about NPS model,

use the below query
nz_get_model

how to check estimate size of differential backup of database in Netezza?

nz_backup_size_estimate will be used to check the differential backup size

 nz_backup_size_estimate -db <db name>

how to abort user session on Netezza

nz_abort will be used to abort the session on NPS server,if we did not provide  any argument ,then it will abort all session on current user

nz_abort  [-all|<dbname>|<username>]

How to put Netezza database to maintenance mode?

we can put the netezza server /db's to maintenance mode,but admin can able to login to the server /database.it wont disturb the existing connection ,it will not allow the new connection to the database.

nz_maintenance_mode -on/off <db_name>,if db name not mentioned it will make it for entire NPS.