Updates one or more repository records identified by the ID in the first column of each result row from the designated query. If the ID is null, a new record will be created using the specified data (that may or may not be derived from the query results).
Inputs:
- sqlQuery - SQL Query identifying the records to be updated. The first column must be the InternalRecordId of each record to be updated or null if a new record is to be created. additional columns may be returned and referenced in the name/value pairs by surrounding the column names with double-pipe characters (e.g., ||myResultColumn||). NOTE: To use percent signs in the actual SQL query (e.g., wildcard in LIKE statement), precede each with a backslash character. For example: WHERE myColumn LIKE '\\%something\\%'. If referencing a work item property and the value may contain single quotes, surround the property reference with curly braces to ensure any single quotes are escaped. For example: WHERE myColumn LIKE '{%myProperty%}'. The curly braces must be inside the single quotes AND the property value cannot have any curly braces itself.
- repositoryName - Name of repository in in which the records are to be updated/created.
- enableTrigger - Activate trigger on target repository if true
- validateRecord - Validate the record after the update if true (default)
- attrNameX - Name of attribute to be updated.",
- attrValueX - Value for attribute to be updated. This can reference work item property names (surrounded by '%'), query result column names (surrounded by '||'), literal values, or any combination.
Outputs
- ID - Delimited list of IDs of records that were created or updated ('0' means error)
- updateStatus - Results of update operation (SUCCESS or FAIL)
- updateMessage - Detailed error message if updateStatus is FAIL
- sqlNumRows - Number of rows returned by the SQL query
- updateNumRows - Number of repository records updated
- createNumRows - Number of repository records created