Topic: Code Place
Subtopic: DB2 for LUW
The script Drive_RunstatScript.cmd will control the execution of the ps1 members, the parameter labelled "ameddev" is my database name, so replace that with your database name. Also this script is the member scheduled in MS Windows Scheduler.
The script RunstatScriptbld.ps1 will generate the Runstat statements that in turn will be executed by the script RunstatScript.ps1 , also in RunstatScriptbld.ps1 , replace the DB2 hostname, userid, password with your system information.
The script RunstatScript.ps1 is the member that will execute the generated Runstat scripts.
The member labelled Drive_RunstatScript_(cmd).txt needs to be renamed to a member type of cmd, member labelled RunstatScript_(ps1).txt needs to be renamed to a member type of ps1, member labelled RunstatScriptBld_(ps1).txt needs to be renamed to a member type of ps1.
I hope more members will contribute their PowerShell scripts, there is very little information on the web and in documents/manuals for creating PowerShell scripts for DB2 running on Windows. I have a few more working scripts, and I will try and contribute more when a get a chance.
Click Here to Download
NOTE: These are only open to members of IDUG. If you are not a member, please CLICK HERE for more information.