cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

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
Highlighted
Responsive Resident
Responsive Resident

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
Highlighted
Responsive Resident
Responsive Resident

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

Highlighted
Frequent Visitor

Re: Referencing Field (Column) Values

Thank you!

Helpful resources

Announcements
August 2020 Community Challenge: Can You Solve These?

August 2020 Community Challenge: Can You Solve These?

We're excited to announce our first cross-community 'Can You Solve These?' challenge!

secondImage

Return to Workplace

Reopen responsibly, monitor intelligently, and protect continuously with solutions for a safer work environment.

secondImage

Super Users Coming in August

We are excited for the next Super User season.

secondImage

Community User Group Member Badges

FIll out a quick form to claim your community user group member badge today!

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (8,978)