cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Bobby_Wallace
Level: Powered On

Referencing Field (Column) Values

Years of progrmming experience - Days with PowerApps...

I would like to access the column values inside Data Table using the Drop Down (selected) as an index. Here's what I came up:

LookUp('[dbo].[Well]', 'WellID' = Dropdown_WellID.Selected.Value).Longitude

The comparison fails because the left side ('WellID') is a number, while the right side Dropdown_WellID.Selected.Value is text. So I tried:

LookUp('[dbo].[Well]', 'WellID' = Value(Dropdown_WellID.Selected.Value)).Longitude

Compiles without error. I set this as the default value of another text input. Start the app and no display.

I put the same code in the following code under the OnChange event for the drop down... still no display.

UPDATE: Change the lookup column from ID to Name because the selected value is the Name: LookUp('[dbo].[Well]', 'WellID' = Value(Dropdown_WellID.Selected.Value)).Longitude

Thanks in advance

1 ACCEPTED SOLUTION

Accepted Solutions
samuelJ
Level 8

Re: Referencing Field (Column) Values

Hi, 

 

I am able to do this.  Under the advance tab, my drop down looks like the below:

cap1.PNG

If yours is the same, you should not have to worry about using value() function.

I have created an text input object and set the the Default property to the below:

LookUp('[dbo].[attendees]', Dropdown1.Selected.peopleId = 'peopleId').legalFirstName

There should not be a need to have something in the onChange property.  Can you confirm you are comparing on the same column?  Below you seem to state it should be comparing on the name column but is using the "WellId" column.


UPDATE: Change the lookup column from ID to Name because the selected value is the Name: LookUp('[dbo].[Well]', 'WellID' = Value(Dropdown_WellID.Selected.Value)).Longitude

Thanks in advance


 

 

 

View solution in original post

2 REPLIES 2
samuelJ
Level 8

Re: Referencing Field (Column) Values

Hi, 

 

I am able to do this.  Under the advance tab, my drop down looks like the below:

cap1.PNG

If yours is the same, you should not have to worry about using value() function.

I have created an text input object and set the the Default property to the below:

LookUp('[dbo].[attendees]', Dropdown1.Selected.peopleId = 'peopleId').legalFirstName

There should not be a need to have something in the onChange property.  Can you confirm you are comparing on the same column?  Below you seem to state it should be comparing on the name column but is using the "WellId" column.


UPDATE: Change the lookup column from ID to Name because the selected value is the Name: LookUp('[dbo].[Well]', 'WellID' = Value(Dropdown_WellID.Selected.Value)).Longitude

Thanks in advance


 

 

 

View solution in original post

Bobby_Wallace
Level: Powered On

Re: Referencing Field (Column) Values

Thank you!

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors (Last 30 Days)
Users online (5,045)