Forum Discussion
nive1110
3 years agoRegular Visitor
Generate unique code in power Apps for different projects with descending order in sharepoint list
| Project | Sub Project details | Location | Unique Role ID(Project +sub proj +location +(Number )) | |
| E-Elec | ABC | Onsite | E-ElecABCOnsite-1 | |
| E-Elec | ABC | Offshore | E-ElecABCOffshore-1 | |
| E-Elec | ABC | Offshore | E-ElecABCOffshore-2 | |
| E-Elec | SOC | Onsite | E-ElecSOCOnsite-1 | |
| E-Elec | SOC | Offshore | E-ElecSOCOffshore-1 | |
| E-Elec | SOC | Offshore | E-ElecSOCOffshore-2 | |
| E-Elec | Rate | Onsite | E-ElecRate Onsite-1 | |
| E-Elec | Rate | Offshore | E-ElecRate Offshore-1 | |
| E-Elec | Rate | Offshore | E-ElecRate Offshore-2 | |
| Rule 14 | Onsite | Rule 14Onsite-1 | ||
| Rule 14 | Onsite | Rule 14Onsite-2 | ||
| Rule 14 | Offshore | Rule 14Offshore-1 | ||
| Rule 14 | Offshore | Rule 14Offshore-2 | ||
| Rule 14 | Offshore | Rule 14Offshore-3 | ||
| Rule 14 | Offshore | Rule 14Offshore-4 | ||
| Rule 14 | Offshore | Rule 14Offshore-5 | ||
| Rule 14 | Offshore | Rule 14Offshore-6 | ||
3 Replies
- AnonymousNot applicable
Hi nive1110
How to generate the unique code for the projects? Is it based on some logic or something? I can help you in Power Apps.Can you just please elaborate a little more of your question?
- nive1110Regular Visitor
Hi Anonymous Need to generate uniique id using project, sub project and location with incremental order .
how to generate unique role IDs for the different combinations of Project, Sub Project details, and Location:
For example
Project Sub Project details Location Unique Role ID Formula Used in "Unique Role ID" E-Elec CC Onsite E-ElecCCOnsite-1 A2&B2&C2&"-1" E-Elec CC Offshore E-ElecCCOffshore-1 A3&B3&C3&"-1" E-Elec CC Offshore E-ElecCCOffshore-2 A4&B4&C4&"-2" E-Elec ABC Onsite E-ElecABCOnsite-1 A5&B5&C5&"-1" E-Elec ABC Offshore E-ElecABCOffshore-1 A6&B6&C6&"-1" E-Elec ABC Offshore E-ElecABCOffshore-2 A7&B7&C7&"-2" E-Elec Mail Onsite E-ElecMailOnsite-1 A8&B8&C8&"-1" E-Elec Mail Offshore E-ElecMailOffshore-1 A9&B9&C9&"-1" E-Elec Mail Offshore E-ElecMailOffshore-2 A10&B10&C10&"-2" Rule 17.1 Onsite Rule 17.1Onsite-1 A11&B11&C11&"-1" Rule 17.1 Onsite Rule 17.1Onsite-2 A12&B12&C12&"-2" Rule 17.1 Offshore Rule 17.1Offshore-1 A13&B13&C13&"-1" Rule 17.1 Offshore Rule 17.1Offshore-2 A14&B14&C14&"-2" Rule 17.1 Offshore Rule 17.1Offshore-3 A15&B15&C15&"-3" Rule 17.1 Offshore Rule 17.1Offshore-4 A16&B16&C16&"-4" Rule 17.1 Offshore Rule 17.1Offshore-5 A17&B17&C17&"-5" Rule 17.1 Offshore Rule 17.1Offshore-6 A18&B18&C18&"-6" Rule 17.1 Offshore Rule 17.1Offshore-7 A19&B19&C19&"-7" PIPP Onsite PIPPOnsite-1 A20&B20&C20&"-1" PIPP Offshore PIPPOffshore-1 A21&B21&C21&"-1" PIPP Offshore PIPPOffshore-2 A22&B22&C22&"-2" PIPP Offshore PIPPOffshore-3 A23&B23&C23&"-3" PIPP Offshore PIPPOffshore-4 A24&B24&C24&"-4" - nive1110Regular Visitor
i was able to acheive this using the formula in excel convert the same to Power apps formula or Power . I generated unquie value code and then concatenated it Please fins below
Project Sub Project details Location Conca Value Generate Number Formula Used to generate number Final Result Formula Used for Final result E-Elec CC Onsite E-ElecCCOnsite 1 COUNTIFS($D$2:D2,IF(ISBLANK(D2)="","",D2)) E-ElecCCOnsite-1 CONCATENATE(D2,"-",E2) E-Elec CC Offshore E-ElecCCOffshore 1 E-ElecCCOffshore-1 E-Elec CC Offshore E-ElecCCOffshore 2 E-ElecCCOffshore-2 E-Elec ABC Onsite E-ElecABCOnsite 1 E-ElecABCOnsite-1 E-Elec ABC Offshore E-ElecABCOffshore 1 E-ElecABCOffshore-1 E-Elec ABC Offshore E-ElecABCOffshore 2 E-ElecABCOffshore-2 E-Elec Mail Onsite E-ElecMailOnsite 1 E-ElecMailOnsite-1 E-Elec Mail Offshore E-ElecMailOffshore 1 E-ElecMailOffshore-1 E-Elec Mail Offshore E-ElecMailOffshore 2 E-ElecMailOffshore-2 Rule 17.1 Onsite Rule 17.1Onsite 1 Rule 17.1Onsite-1 Rule 17.1 Onsite Rule 17.1Onsite 2 Rule 17.1Onsite-2 Rule 17.1 Offshore Rule 17.1Offshore 1 Rule 17.1Offshore-1 Rule 17.1 Offshore Rule 17.1Offshore 2 Rule 17.1Offshore-2 Rule 17.1 Offshore Rule 17.1Offshore 3 Rule 17.1Offshore-3 Rule 17.1 Offshore Rule 17.1Offshore 4 Rule 17.1Offshore-4 Rule 17.1 Offshore Rule 17.1Offshore 5 Rule 17.1Offshore-5 Rule 17.1 Offshore Rule 17.1Offshore 6 Rule 17.1Offshore-6 Rule 17.1 Offshore Rule 17.1Offshore 7 Rule 17.1Offshore-7 PIPP Onsite PIPPOnsite 1 PIPPOnsite-1 PIPP Offshore PIPPOffshore 1 PIPPOffshore-1 PIPP Offshore PIPPOffshore 2 PIPPOffshore-2 PIPP Offshore PIPPOffshore 3 PIPPOffshore-3 PIPP Offshore PIPPOffshore 4 PIPPOffshore-4