This is a public Media Gallery  publicRSS

Action

    Add a whole bunch of attributes to all objects in WUG
    Action posted 9/1/09 by Zachary Loeber
    1499 Views
    Name:
    Add a whole bunch of attributes to all objects in WUG
    Description:

    I was tasked with aligning a spreadsheet of multiple columns of data with our whatsup monitoring database. I chose to import the data from the spreadsheet into attributes on each device in whatsup. To make sure that all devices have all attributes this is the script I wrote and then scheduled to run nightly as the first part of a complicated SSIS job. This takes a text file with the attributes to add and adds them if they do not already exist. If an device has the attribute "New Device Status" and it is not blank and does not have the value of "Re-initialize" or "Add New" then it adds the attributes in the file to the device.

    Not really an "Action" within wug but is rather meant to be externally run. You will need to run it as an account with permission to connect to the database and make changes. Definately run this at your own risk!!!

    This script does not add any attribute values, that is up to the reader to figure out (or later I'll post my overly complicated ssis job maybe). This effectively adds an attribute list of empty attributes, this can clear out any existing attributes that are in the attribute file if you are not careful.

    Language:
    VB Script
    Code:
    Disclaimer:
    All scripts found on wugSpace are provided as-is with no warranty or guarantee. These scripts are not supported by Ipswitch Technical Support. If you have a problem with this script, please ask any questions in the comments.