Skip to main content

system.kanoa.attribute.updateAttributeAssetLink

This function is part of the kanoaOPS module

Description

Updates an existing attribute asset link.

Syntax

updateAttributeAssetLink(attrAssetInfo, userId)
  • Parameters
      dictionary attrAssetInfo - {'attributeAssetLinkId': 67, 'attributeId': 3, 'assetId': 5, 'sourceTagPath': 'some tag path', 'scaleFactor': 1.0, 'ignoreZeroValues': True, 'enabled': True}
      int userId - User ID
  • Returns
      int - Number of records modified
      string msg - Message indicating the result
  • Code Examples

    # Example usage
    attrAssetInfo = {
    'attributeAssetLinkId': 67,
    'attributeId': 3,
    'assetId': 5,
    'sourceTagPath': 'some tag path',
    'scaleFactor': 1.0,
    'ignoreZeroValues': True,
    'enabled': True
    }
    userId = 123
    modifiedRecords, msg = system.kanoa.attribute.updateAttributeAssetLink(attrAssetInfo, userId)
    print(modifiedRecords, msg) # Print the number of modified records and message