cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ursNani
Helper IV
Helper IV

Dropdown need to avoid to show existing records

Hi 

I am pulling data from "project WBS Element" list in dropdown and saving into "Projects forcaster" list .

 

my dropdown need to show only not saved records in forcaster list only.

 

here is the my dropdown item property code : Filter('Project WBS Elements',Status.Value="Active" ).'Active WBS Elements'

 

lets assume i have records in project WBS Element , AAAA , BBBB,CCCC,DDDD,EEEE

my dropdown need to show all of them. if i have forcaster list AAAA item, then dropdown need to show only BBBB,CCCC,DDDD,EEE records only .

 

please give me code . here is the my dropdown item property :  Filter('Project WBS Elements',Status.Value="Active" ).'Active WBS Elements'

 

Thanks 

2 ACCEPTED SOLUTIONS

Accepted Solutions
BCBuizer
Super User
Super User

Hi @ursNani ,

 

A quick, but non-delegable, way to do this is using the in operator:

 

Filter(
	'Project WBS Elements',
	Status.Value="Active",
	Not(ID in 'Projects forcaster'.ID)
).'Active WBS Elements'


Did you like my post? Please give it a thumbs up! Did I resolve your issue? Please click Accept as Solution to close the topic and so other members of the community can find solutions more easily.

View solution in original post

v-qiaqi-msft
Community Support
Community Support

Hi @ursNani,

Do you want to exclude records that exists in "Projects forcaster" list from dropdown items?

Could you please tell me that if both of "project WBS Element" list and "Projects forcaster" list share the same element like AAAA,BBBB?

 

@BCBuizer provides a direction that both of two lists share the same ID, so you could compare ID in them to exclude existing records in "Projects forcaster" list. However, if you just have the same column storing the  AAAA,BBBB,..., please modify your formula as below:

Filter('Project WBS Elements',Status.Value="Active",!(ColumnYouSavingAAAA in 'Projects forcaster'. ColumnYouSavingAAAA)).'Active WBS Elements'

This is just a different format, the key to this issue is the "Column1 in AnotherList.Column2", Column1 and Column2 are different columns sharing the same items, just like the AAAA, BBBB in both "project WBS Element" list and "Projects forcaster" list.

Best Regards,
Qi

View solution in original post

2 REPLIES 2
BCBuizer
Super User
Super User

Hi @ursNani ,

 

A quick, but non-delegable, way to do this is using the in operator:

 

Filter(
	'Project WBS Elements',
	Status.Value="Active",
	Not(ID in 'Projects forcaster'.ID)
).'Active WBS Elements'


Did you like my post? Please give it a thumbs up! Did I resolve your issue? Please click Accept as Solution to close the topic and so other members of the community can find solutions more easily.
v-qiaqi-msft
Community Support
Community Support

Hi @ursNani,

Do you want to exclude records that exists in "Projects forcaster" list from dropdown items?

Could you please tell me that if both of "project WBS Element" list and "Projects forcaster" list share the same element like AAAA,BBBB?

 

@BCBuizer provides a direction that both of two lists share the same ID, so you could compare ID in them to exclude existing records in "Projects forcaster" list. However, if you just have the same column storing the  AAAA,BBBB,..., please modify your formula as below:

Filter('Project WBS Elements',Status.Value="Active",!(ColumnYouSavingAAAA in 'Projects forcaster'. ColumnYouSavingAAAA)).'Active WBS Elements'

This is just a different format, the key to this issue is the "Column1 in AnotherList.Column2", Column1 and Column2 are different columns sharing the same items, just like the AAAA, BBBB in both "project WBS Element" list and "Projects forcaster" list.

Best Regards,
Qi

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (3,226)