Update constant smart service Invalid Cast: Cannot cast from type 'Document' to type 'Content Constant'

I am getting the error:

Details:  Invalid Cast: Cannot cast from type 'Document' to type 'Content Constant' (Data Inputs)

When trying to replace the constant contents, which is a constant that is a list of Documents. How do I fix?

It doesn't work for replace version yes nor no. 

  Discussion posts and replies are publicly visible

Parents Reply
  • I'm a bit confused - this sounds the opposite of the screenshot David provided, but I tried the selecting from my constants in the env as you suggested and it worked. This process model needs to update 1-3 constants depending on a condition though, and I am testing the updating 2 constants - it throws the same error even though I updated the second one the same way. How can we update multiple constants in the same process model?

Children
  • 0
    Certified Lead Developer
    in reply to ginao0001

    The best I can suggest is that you might need to configure an Update Constant node unique to each Constant which you need to update - and use in-process logic (gateways, etc) to decide which one(s) to execute at a given time.  For the error you're still getting, you probably need to make sure the type of data you're passing into the node for the new constant value exactly matches the constant's type (which would include both data type as well as list/single).