_vLookupID not populating with Power Automate create item flow

Home Forums vLooup for SharePoint _vLookupID not populating with Power Automate create item flow

Viewing 4 reply threads
  • Author
    Posts
    • #35097
      Jay Baldwin
      Participant

        Hello Alexander – I’m hoping you can help me resolve an issue with a missing _vLookupID when a new item is created by Power Automate.

        My scenario is work requests are submitted to list A. After requests are approved, Power Automate creates a new item in the work request management list B. List B uses vLookup for notes, contacts, etc. However, the _vLookupID field is not populated when the record is created this way. If a record in list B is created using the out of the box New button, _vLookupID field populates.

        Is there a something that can be configured to populate the _vLookupID field? Thank you!

        Jay

      • #35102
        SteveE
        Participant

          Power Automate doesn’t load the new form in the way that clicking the “New” button does. You’d need to configure Power Automate to populate the fields the same way you have the vLookup fields being populated. It has to be done in Power Automate if you are using that to create the item.

        • #35107
          Alexander Bautz
          Keymaster

            Hi,
            In the DFFS form the vLookup column is populated with a string combining the current user id and the current date like this:

            _spPageContextInfo.userId+":"+new Date().valueOf()

            You cannot get the same method in a FLOW, but you all you need is an value that is uniquie within the list so using an expression like this should work:

            rand(1000000000,2000000000)

            You are not 100% certain to get an unique value using this method, but it should be fairly certain. If the theoretical chance of getting the same value on two items bother you you can prepend the current item id from the item you are triggering the flow on – something like this:

            concat(triggerBody()?['ID'],':',rand(1000000000,2000000000))

            Alexander

          • #35109
            Jay Baldwin
            Participant

              SteveE – Thank you. Could you elaborate on how to configure Power Automate to populate the vLookupID field?

              And just for clarification, Power Automate is creating the parent item. Any item in the child lists (notes, contacts, etc.) is created using the DFFS add new item button.

            • #35111
              Jay Baldwin
              Participant

                Alexander – our posts crossed. Thank you for your help!

            Viewing 4 reply threads
            • You must be logged in to reply to this topic.