web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / On Submit Form One Loo...
Power Apps
Answered

On Submit Form One LookUp Column not getting updated

(0) ShareShare
ReportReport
Posted on by 115

Hello Everyone. I am submitting a form. In that there is a column called SA which is a lookup column. Everything gets submitted but this column does not gets submitted. It says wrong content type. I have a flow running after it too. In that I get error, plus when I check the the database this column is empty. On submit button I am just submitting the form and navigating back to previous screen.

If any other information is required, I will share that too.

Unknown123_0-1687156673255.png

@WarrenBelz @Ethan_R @timl @developerAJ @Amik 

Categories:
  • Verified answer
    SanmeshG Profile Picture
    1,956 Moderator on at

    Hi @Unknown123 ,

     

    Whenever you are patching a lookup Column you need to ensure that , it has the id property when you select the value.

    Please go to the Lookup Column data card, ensure that you have selected a value for your lookup column. And check what does the Update property show , when you select the DataCardValue in the update property.

    Attaching an image for your reference.

    patchlookupcolumn.png

     

    If the Id doesn't show in your case , then you need to have a lookup formula in your update property , as below.

     

    {
     Id: LookUp(
     Country,
     Title = DataCardValue7.Selected.Value
     ).ID,
     Value: LookUp(
     Country,
     Title = DataCardValue7.Selected.Value
     ).Title
    }

     

    Here Country is a SP list from which I want to lookup a value. and Title is the column name. Change it as per your data sources.

    Hope this helps , if it does , please give it a thumbs up and accept this as a solution.

    Thanks,

    Sanmesh

  • Unknown123 Profile Picture
    115 on at

    @SanmeshG 

     

    Thanks Buddy it worked. 

     

  • amralomari Profile Picture
    169 on at

    Greetings dear SanmeshG

     

    I've checked your answer, since I have the same problem, and I've the update property right (the image below) but I still having the same error?! any idea why?

     

    Thanks in advance 🙂 

    amralomari_0-1714641145825.png

     

  • SanmeshG Profile Picture
    1,956 Moderator on at

    Hi @amralomari ,

     

    What is the error you are getting ?

     

    Can you add a screenshot of the error message?

  • amralomari Profile Picture
    169 on at

    The SP list has a look-up column that fetches another additional column, the issue was that it can't patch the additional column (although I've tried (You can check the code bellow) :S) after removing the additional column I'm getting the value patched (using SubmitForm) without the lookup column XD.
    I think I'm going to start a separate discussion about it.

     

    The tried code: 

    Patch(
     Refraction,
     Defaults(Refraction),
     {
     'Patient Name': {
     '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedLookup",
     Id: LookUp(Customers,ID=PtNameDataCardValue30.Selected.Id,ID),
     Value: PtNameDataCardValue30.Selected.Value
     },
     'Patient ID': {
     '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedLookup",
     Id: LookUp(Customers,ID=PtNameDataCardValue30.Selected.Id,ID),
     Value: PtNameDataCardValue30.Selected.Value
     },
     'OD Sphere': Value(ODSpDataCardValue35.Value),
     OS_Sphere: Value(OSSpDataCardValue36.Value),
     'OD Cylinder': Value(ODCyDataCardValue37.Value),
     OS_Cylinder: Value(OScyDataCardValue38.Value),
     'OD Axis': Value(OdAxDataCardValue39.Value),
     OS_Axis: Value(OSAxDataCardValue40.Value),
     'OD Va': Value(ODVADataCardValue41.Value),
     OS_Va: Value(OSVADataCardValue42.Value),
     'OD Add': Value(odaddDataCardValue43.Value),
     OS_Add: Value(OSaDDDataCardValue44.Value),
     OD_Without: Value(ODWoutDataCardValue45.Value),
     OS_Without: Value(OSWoutDataCardValue46.Value),
     OD_With: Value(ODWthDataCardValue47.Value),
     OS_With: Value(OSwthDataCardValue48.Value),
     OS_Glasses: Value(ODGDataCardValue49.Value),
     OD_Glasses: Value(OSGDataCardValue50.Value)
     }
  • SanmeshG Profile Picture
    1,956 Moderator on at

    I think additional column (that is added from the lookup list ) is read only column and need not be specified while patching. Only the original column on which you create a lookup should be specified in the patch code.

     

    The additional selected column should show the value based on the column in the original lookup column.

     

    Hope this helps! 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 342 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 271

#3
Mohsin Ali Profile Picture

Mohsin Ali 239

Last 30 days Overall leaderboard