I have a table Animals with field Breed.
Breed is an integer slave id field to master Breeds table.
I use a dropdown to make users choose a breed. (ras=dutch for breed)
Items
'[dbo].[ras]'
Default
LookUp('[dbo].[ras]';ras_id=Parent.Default;naam) //get breed name for existing breed in table
I am not into adding records to this database from the powerapps yet but if I edit a record with no breed selected this happens:
A breed is chosen for me. It might be the first from the table or it might be the last one I used on another record.
Q1 How can be:
I inspect the value of the field in the database (parent.default) in a record with no value for breed
Since it is an integer ID field the value will probably be 0
A label with this value will not show anything. Even if I format "#.00"
A label with Empty(parent.default) will say true
A label with parent.default = 0 will say false
A label with parent.default+1 will say 1
A label with abs(parent.default) < 0.000/*..as many zero's as you like..*/0000001 will say true
Q2 What is the best way to solve the unwanted selection of the dropdown.
In the propriety software that uses the sql database I now added a breed called "-" and have this be the default. Is that really the best I can do?
Hi @HansHeintz
Could you please share more details of your data source?
What data source is it?
What is the column type?
Could you please share the stucture of your data source?
Could you please share more details of your controls in your App and more details of their formula expreesion?
Best Regards.
Yumia
I fail to see the congruence between my message and your reply. Is it automated?
I explicitly mentioned the column type as being an integer id field.
I asked what is the best way to deal with using a dropdown on a relation slave field when the original record has no value for that field yet c.q. the value is 0. I did not ask what is wrong with my code.
I am sorry but I see a lot of "message management" here in stead of real replies.
The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.
This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.
User | Count |
---|---|
187 | |
52 | |
51 | |
34 | |
33 |
User | Count |
---|---|
266 | |
97 | |
84 | |
76 | |
73 |