Named Formulas & User Defined Functions in Power Apps

Поделиться
HTML-код
  • Опубликовано: 1 авг 2024
  • Discover the game-changing capabilities of Named Formulas and User Defined Functions in Power Apps in this tutorial video. Introducing Named Formulas: A powerful concept that has been in Excel for a very long time, that is now available in Power Fx. With it, you can simplify your app’s initialization, reduce app load time, reuse logic, and improve the maintainability of your apps. A must learn for all Power Apps makers.
    Named Formulas offer distinct advantages, such as always-available values without timing dependencies (unlike App.OnStart), real-time updates based on control properties or database records, and an immutable definition in App.Formulas as the single source of truth. Enjoy the flexibility of deferred calculations, allowing Named Formulas to be computed precisely when needed, optimizing performance.
    Learn about User Defined Functions in PowerApps and revolutionize your coding experience. Write code once and reuse it effortlessly throughout your Power App. Learn how to build your own custom functions, define input parameters & data types, and call custom functions from App.
    📃 Named Formulas: learn.microsoft.com/en-us/pow...
    🔗 Power Fx: Introducing Named Formulas: powerapps.microsoft.com/en-us...
    ⬇️ Download App shown in video ➡️ link in Community Tab for Channel Members (Silver Club 🥈 or higher)
    #PowerApps #PowerFx #Microsoft #powerplatform
    0:00 Introduction to Named Formulas and User Defined Functions in Power Apps
    0:23 Types of Variables in Canvas Power Apps
    2:42 What are Named Formulas in Power Apps?
    5:00 OnStart vs App.Formulas (Set variables or Named Formulas)
    6:41 Learn User Defined Functions (UDF) in PowerApps
    10:50 Examples of Named Formulas and custom functions in Power Apps
  • НаукаНаука

Комментарии • 234

  • @Stephenm84
    @Stephenm84 4 месяца назад +20

    This is a game changer. Great tutorial! Thank you so much.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Most welcome

    • @Stephenm84
      @Stephenm84 4 месяца назад

      Question: Can you use a named formula that references a data source, eg SharePoint List, with Patch()?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      @@Stephenm84 It can reference data sources. But Patch would be an on-demand call that you would make on click of a button.

    • @Stephenm84
      @Stephenm84 4 месяца назад

      ​@@RezaDorraniYep, but what I'm specifically asking is if I can keep all my references in one place:
      Formulas:
      dsMyList = MySchema_MyList;
      A Button's OnClick:
      Patch(dsMyList, Defaults(dsMyList), { field1 = "Value"})
      When I attempt this, Patch() gives me an error:
      "The first argument should be a collection"

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      @@Stephenm84 Yes, that should work. Best to try it out :)

  • @luisfernandomacedo1451
    @luisfernandomacedo1451 3 месяца назад +3

    It goes without saying that anyone who watches Reza's tutorial is taken from basic to advanced skills. The way he has laveraged the user defined function to complex calculation was insane. Great tutorial, Reza!1

  • @PA_Freak
    @PA_Freak 4 месяца назад +3

    UDF are a great enhancement, but they come with a small downside:
    To auto-format your code in “Formulas”, you’ll need to remove it first or comment-out /* */ .
    The other thing on named formulas, especially when replacing collections, they are not listed under Variables (X), so that there is a bit the overview lost…
    Certainly by marking it you’ll see the table/content.
    So good would to have another grouping to list down the NamedFormulas below Collections.
    Thanks Reza, for sharing this in such a great explanatory way, you are my first choice of information the Apps & Flows.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Most welcome!
      And thanks for sharing the feedback

  • @Bekesam
    @Bekesam 4 месяца назад +1

    I had already incorporated named formulas when it was first introduced, but at the time, collections were not yet permitted. Thank you so much sharing this and I will now update the rest!!!

  • @14gigigirl
    @14gigigirl 4 месяца назад +1

    Fantastic Reza! I have an exact use case for this and you have just provided me with the solution! Thank you for another excellent video showcasing the functions. ✨🚀

  • @alexpena9419
    @alexpena9419 4 месяца назад +2

    As always, your insights are timely and informative! Thank you so much❤

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Most welcome and thanks for watching

  • @Cybermatik
    @Cybermatik 4 месяца назад +1

    Great video reza, thanks for sharing ;)
    Using those formulas instead of onstart seems to be really efficient!

  • @TheKermit2110
    @TheKermit2110 20 дней назад

    best tutorial on named formulas i've seen so far, thanks so much Reza

  • @PA_Freak
    @PA_Freak 4 месяца назад +3

    Moving collections to NamedFormulas really boosts!! 🚀🚀
    Having a complex app with 15 screens >30 datasources and >20 collections, where I moved majority of collections (only static) to Formulas now.
    Result is impressiv: App loading time went down from 3-5 sec to 1 sec. !!
    Thx again for sharing this !

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Awesome!
      So happy to hear that

    • @baderahm
      @baderahm 3 месяца назад

      Thanks. But it will delay the load of the galleries n their update, after refreshing the data. Isn’t it?

    • @RezaDorrani
      @RezaDorrani  3 месяца назад

      @@baderahm Give it a try and check

    • @Bekesam
      @Bekesam 3 месяца назад

      @PA_Freak or @RezaDorrani, when mentioned "collections(only Static)", what do you mean by that? Thanks

    • @RezaDorrani
      @RezaDorrani  3 месяца назад

      @@Bekesam Best to try it out and check

  • @rarun0080
    @rarun0080 4 месяца назад +2

    very descriptive! Thanks for posting a video about named formulas

  • @callfusion2012
    @callfusion2012 4 месяца назад +1

    Work to be done! Step by step...

  • @traianpopescu3684
    @traianpopescu3684 2 дня назад

    Great video, thank you Reza!
    Waiting from Microsoft for the day when we can define full functions with multiple lines of code, Patch functionality and any kind of Parameter or Return types 🙏🏼

  • @twosatoshis2478
    @twosatoshis2478 4 месяца назад +1

    I'm learning so much with you. Appreciate how you go about teaching

  • @Christian-tf6ol
    @Christian-tf6ol 4 месяца назад +1

    Truly game changer. Thank you for sharing Reza! 💯

  • @RidewithMrUnknow
    @RidewithMrUnknow 4 месяца назад +2

    As always you rocked with your explanation capabilities ❤

  • @jasonmcandrew5661
    @jasonmcandrew5661 4 месяца назад +1

    Fantastic Reza, I can definitely see how my apps can be improved with this. Thank you. 🙏

  • @alec734
    @alec734 4 месяца назад +2

    Thank you for the video! This will reduce the use of variables and collections significantly.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Named formulas first. Then collections and variables. Each have their own space.

  • @BhupinderSingh
    @BhupinderSingh 4 месяца назад +1

    Thanks for explaining the functions. I always wanted this feature.

  • @JoseAugustoDeLimaPereira
    @JoseAugustoDeLimaPereira 4 месяца назад +1

    This is really awesome!!! TY Reza, you're the best!

  • @patelbhargav
    @patelbhargav 4 месяца назад

    Thanks for the early access Reza!

  • @rajasekare3817
    @rajasekare3817 4 месяца назад +1

    Useful for me Reza... Thanks for sharing...!

  • @oluwatobiyusuf
    @oluwatobiyusuf 3 месяца назад +1

    This is a game changer for me. Thank you Reza

  • @MegaKumar0
    @MegaKumar0 4 месяца назад +1

    Nice explanation! Thank you

  • @stelianrusu9881
    @stelianrusu9881 4 месяца назад +1

    Great info! Thanks!

  • @mohammaddanish5997
    @mohammaddanish5997 4 месяца назад +1

    What a great explanation and It gonna help a lot. Thank you Reza.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Most welcome and glad to hear it’s helpful.

  • @OzStomper
    @OzStomper 4 месяца назад +1

    really great video - thanks!

  • @Ankjain30
    @Ankjain30 4 месяца назад +1

    Really useful, Thanks for this video Reza 👍

  • @SadekInfos7392
    @SadekInfos7392 4 месяца назад +2

    Thank you dear brother...we need more videos about this new feature if possible bro ❤

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      Most welcome!
      I try to bring something new in each video.

  • @YAS-dn6xn
    @YAS-dn6xn 3 месяца назад +1

    Reza, AWESOME WORK as usual

  • @udp77fac1
    @udp77fac1 6 дней назад +1

    very helpful bro! thanks!!

  • @lowcodedev
    @lowcodedev 4 месяца назад +1

    Great tutorial 👍👏

  • @KuldeepSingh-nq1vi
    @KuldeepSingh-nq1vi 4 месяца назад +1

    Very Nice Explanation Reza..

  • @STY-ze3yy
    @STY-ze3yy 4 месяца назад +1

    Excellent bro!

  • @isaiaguillon9878
    @isaiaguillon9878 4 месяца назад +1

    OMG! This is pure gold!!! Thank you for sharing Reza.... quick question, if I use a Named Formula in a gallery, I will not be able to do the grid approach you explained in one of your videos where you can add (patch) records to the gallery and then to the datasource, will that be a limitaton of namedformulas?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Collections, Variables and Named formulas will all coexist.

  • @nadyam.7733
    @nadyam.7733 4 месяца назад +1

    TY! ☺️

  • @jaddfigaro7246
    @jaddfigaro7246 4 месяца назад +1

    All formulas in one easy place … GAME CHANGER !!
    Way easier to see where you almost duplicate formula without knowing

  • @aducaale328
    @aducaale328 4 месяца назад +3

    Ramadan mubaarak to all of you.

  • @aiwak.9554
    @aiwak.9554 4 месяца назад +1

    very cool! I don't need refresh icon of gallery no more. I would love to use your techniques in my App. Thank you.

  • @itxhamza5543
    @itxhamza5543 4 месяца назад +1

    That's really cool respect from Pakistan

  • @carlosvelver3194
    @carlosvelver3194 3 месяца назад +1

    Thanks for all the extremely valuable content Reza!! Is it possible to include optional parameters in this named functions?

    • @RezaDorrani
      @RezaDorrani  3 месяца назад

      I don't think optional params is currently an option

  • @stoplis87
    @stoplis87 4 месяца назад +1

    Great video Reza! Quick question, when using name formulas to filter a table do you know if it adds any delegation to it? e.g. a collection can only hold so many records but this isn’t creating a local copy so does it have that limit?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Thanks!
      It is delegation ready!

  •  4 месяца назад +1

    Thanks for this video. I had considered the formulas as constants until now. I didn't know they were updated based on arguments. Do the delegation criteria apply in this case?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      Delegation criteria does apply

  • @shaikhfirdos2723
    @shaikhfirdos2723 4 месяца назад +1

    Awesome❤❤

  • @karukarthi2609
    @karukarthi2609 4 месяца назад +1

    Thanks for your video and so informative. I assume all these named formulas will load when the app starts run and if the value is never used, then those formula need never be calculated.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Formulas will run only when needed.

  • @skawathe
    @skawathe 4 месяца назад +1

    Thanks for the amazing video!
    I got below questions. It will be really helpful for me if you provide some insights on these. Thanks in advance.
    Are named formulas delegable?
    Gallery loads records in batches of 100 for performance optimization. If we use named formula in such case, will my gallery show all records? Will data row limit affect named formulas?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      Delegable as long as query is delegable.
      Gallery will load data in batches of 100 with named formulas (as long as query is delegable against data source)

  • @szfagier1779
    @szfagier1779 28 дней назад +1

    Hi, great video as always!! Do you think is there a way of creating UDF that would be across all apps as some sort of component?

    • @RezaDorrani
      @RezaDorrani  28 дней назад

      Thanks!
      Currently, UDFs are per app only

  • @sergiizelenko4114
    @sergiizelenko4114 4 месяца назад

    Great video, thank you very much!
    There are some cases when I need to use a collection within a single screen (when modifying a gallery and patching the result to DB, for instance). Can such collection be "local" to save pc memory?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Named formulas, collections and variables each have their use cases. None of them should be used as a data source.
      Check savedata loaddata functions for your scenario

  • @vonis22
    @vonis22 3 месяца назад +1

    Hi Reza, amazing video once again! Is there a way to use User Defined Functions in behavior like OnSelect. To make a Patch to Dataverse Generic from different places in the app for instance?

  • @arunv1909
    @arunv1909 4 месяца назад +1

    Thanks

  • @VanitaSharma-mr9tl
    @VanitaSharma-mr9tl 4 месяца назад +1

    Hi Reza, you are right. This is a game-changer. I do have one question though. If I create a collection named formula, as you mentioned, it will be executed only when needed. Then, what if I am referring to the collection multiple times and on multiple screens? Does it make it an expensive operation?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      It will run the formula when needed on demand as you land on those screens.
      It does do smart caching as well.
      Easiest way to check if to run monitor tool and see the api calls.

  • @nihar4713
    @nihar4713 11 дней назад +1

    Amazing

  • @davidhardy2063
    @davidhardy2063 4 месяца назад

    Thanks, Reza. I have a need to do a block of code from multiple spots in my app, e.g., clear a block of variables. Could we do a parameter-less Custom Formula that can execute several statements at once, allowing me to just call the function wherever I need to execute the statements?
    Something like: nfClearSignatureVars():Boolean = Set(varSignBlob, Blank()); Set(varSignBinary, Blank()); Set(varSignPrintedName, Blank());

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Not sure if setting variables in named formulas is even an option

  • @abdussalambaderkudhal-fz7jw
    @abdussalambaderkudhal-fz7jw 4 месяца назад

    Thank you, Reza, for the access.
    Will this named formulas work in ForAll loop?
    if there is no sequence in named formula, that means we cannot use dependent formula?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      It should work in forall also. Best to test and check.

  • @clairevoyance26
    @clairevoyance26 Месяц назад

    Hi rezza, ive just added named formulas but how do you control the splash screen when its visibility is dependent on the data from a collection in named formula? In OnStart, you can just add set variables of the loading screen before and after the collection.

    • @RezaDorrani
      @RezaDorrani  Месяц назад

      Named formula and a static variable is one and the same. Name formula will calculate Instantly.

  • @derekgray3019
    @derekgray3019 4 месяца назад +1

    absolutely brilliant Rezza, I've been meaining to learn this to move most, if not all my App.OnStart variables to named formulas. One thing I have been trying to do is use a sharepoint list of roles, so I can control who can view different views in my Apps e.g. Security role and use this to control and filter galleries. I know you did one a couple of years ago but unable to find it. And my question is can this be done using Named Formulas?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Thanks so much!
      Absolutely, named formulas is the way to go.
      Here is the video you are looking out for ruclips.net/video/dIzOAbMjN7g/видео.htmlsi=xKqPYLJXnUnEUqDn

    • @derekgray3019
      @derekgray3019 4 месяца назад +1

      Perfect! I knew i had seen it before and struggled to get it to work, but now I am more experienced I think I can get to work. Thank you Sir 🙂

    • @derekgray3019
      @derekgray3019 4 месяца назад

      Just one question, i have a list of 8 items in the Security list for business area, can i filter against the list in the named formula for each business area so that a logged in user can only see what he has item level permissions for?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      @@derekgray3019 If security is already configured at item level, you simply get all items from list. Power Apps will respect security.

  • @markusj4729
    @markusj4729 4 месяца назад +1

    Great vid! :) Was wondering - In order to use User Defined Functions you need activate new analysis engine, I've seen that people have reported several errors after activating it, have you experienced any issues regarding this?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      UDF is in preview so would not suggest using that in prod scenarios yet.

    • @markusj4729
      @markusj4729 4 месяца назад +1

      @@RezaDorrani true :) thanks

  • @ErinMark11
    @ErinMark11 Месяц назад

    Hi Reza, question about the named formulas and having your datasource filtering there instead of inside the gallery itself... are there any delegation concerns? or is the named formula acting like it was written inside the gallery's "items" property?

    • @RezaDorrani
      @RezaDorrani  Месяц назад +1

      Its like it’s written inside gallery items property (as far as I remember)
      Best to try it out and check

  • @jesperchristiansen639
    @jesperchristiansen639 4 месяца назад +1

    Does Named Formulas or User Defined Function support Patch() ??
    I want to create a Custom Function to Patch some data as i use the same Patch function in several screens.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      It does not as far as I know

  • @vivekmurli5137
    @vivekmurli5137 Месяц назад

    Hi Reza,
    Does UDF support using a custom connector inside the UDF? Do you have any articles or code samples for this?
    Is return type in UDF compulsory since the custom connector just writes to SQL.
    Any help would be appreciated 🙂

    • @RezaDorrani
      @RezaDorrani  Месяц назад

      I don’t think it supports custom connector.
      I do not have any references on it.

  • @user-oc1ny9ie5z
    @user-oc1ny9ie5z 4 месяца назад

    Hi Reza,
    Thank you for sharing this.
    When multiple users are simultaneously working on the same app, if User 1 updates an item, will that update automatically reflect for User 2 without requiring a manual refresh?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      It wont update automatically. Its the same behavior for any other feature in Power App. A manual refresh or restart of app or execution of a delegable function via an action like go to screen or button click would be needed.

    • @user-oc1ny9ie5z
      @user-oc1ny9ie5z 4 месяца назад +1

      @@RezaDorrani Thank you 🌹

  • @dhavalbendale5509
    @dhavalbendale5509 4 месяца назад

    Hello Reza, Is there any way i can remove the attachment from the sharepoint list through Powerapps? for other fields we can Patch Blank() values but how to delete attachments or Image fields.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Patch function does not support attachments. Form control or flow is your other options.
      Image column can be patched. To make values blank with patch - ruclips.net/user/shortsfg-4nu_amJI?si=i9y5dZJalZZae5XE

  • @RowDogSA
    @RowDogSA 4 месяца назад

    Great video. I am very confused with where you changed the collection colItems to a named formula nfHighPriorityTasks. The nfHighPriorityTasks table is not visible in the variables section like collections are. Is it stored locally somewhere?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      Named formulas dont list out in variables section. You simply refer to it where you need it and the formula will run.

    • @RowDogSA
      @RowDogSA 4 месяца назад +1

      @@RezaDorrani Thank you!

  • @peterbibb8967
    @peterbibb8967 3 месяца назад

    My annual period runs from 1st April to 31st March, what's the easiest way to set up two variables StartOfPeriod (eg 1/4/2024) and EndOfPeriod (31/3/2025) such that today is within that period? Is it using formulae, or setting global variables? Thanks

  • @kiran_gawade
    @kiran_gawade 4 месяца назад

    Raza, one question for formulas. When we use, it instantly execute it for collection. Does it will impact per day request cap or limit?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Not sure what instantly execute for collection means.
      These formulas are only calculated when referenced on a screen.

  • @lakshmichaitanya3504
    @lakshmichaitanya3504 4 месяца назад

    Hi, I came across browser crashing issue suddenly in development environment (lower Environment) with data table control where as it's working fine in production environment (higher/live environment).
    I have checked both environments are having same authoring versions but why the issue in dev not in prod...?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      I have no clue about this. Not something I have come across.

  • @sridharreddy1607
    @sridharreddy1607 3 месяца назад

    Hi Reza, I have a combobox in that onchange I have a logic to update few variables coming from database sql server which works perfectly in edit mode but not in play mode as I can't see the variable values getting updated any help/suggestion please ?

    • @RezaDorrani
      @RezaDorrani  3 месяца назад

      I have not come across this issue and hence not sure what the cause for it could be.
      I will recommend posting your issue on forums in case someone has experienced something similar powerusers.microsoft.com

  • @benjaminlahsen6721
    @benjaminlahsen6721 4 месяца назад

    Hi Reza! This is great. I can´t activate named formulas in my Power Apps tho. I can see the Formulas property in the App screen but it doesn't work and I am sure I am using the right syntax.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Named Formulas is Generally Available. No need to activate it.
      Im not sure why it would not show up in your app.

    • @benjaminlahsen6721
      @benjaminlahsen6721 4 месяца назад

      it does show up, but when I close the formula using ';' as requested, the error message says "Missing parent close". It is wierd@@RezaDorrani

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      @@benjaminlahsen6721 I would recommend posting your issue on forums
      powerusers.microsoft.com

  • @putzz67767
    @putzz67767 4 месяца назад +1

    Greatttt

  • @avpnile
    @avpnile 4 месяца назад +1

    Nice feature.
    Is there any way I can define a user define function and use in different canvas apps?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      As of now, its for current app only

  • @seenakhan3063
    @seenakhan3063 4 месяца назад +1

    Hello Reza, Thanks a lot , nice tutorial. I have doubt on one scenario, when we importing power apps solution multiple times into the same environment , is there any issues will happen on flow actions? My flows are triggering based on SharePoint list updates. On my development environment flows are executing as expected , but in my testing environment same flows gives multiple action , specifically two emails receiving. Can you please give me a solution for this

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Welcome!
      I have not come across this issue and hence not sure what the cause could be.
      I recommend posting your issue on forums in case someone has experienced something similar powerusers.microsoft.com

    • @seenakhan3063
      @seenakhan3063 4 месяца назад

      @@RezaDorrani sure will do - Thank you so much 😊

  • @jevinwang3769
    @jevinwang3769 4 месяца назад

    One more question - UDF does not support return type to be an array / items, right? many thanks

  • @Bekesam
    @Bekesam 3 месяца назад

    In a sense, does this not dramatically minimize the use of collections? Almost to the point that named formula's would replace collections, except for discrete use cases?

    • @RezaDorrani
      @RezaDorrani  3 месяца назад

      Named formulas would and should reduce variables and collections usage

  • @user-tr2tx5nf8h
    @user-tr2tx5nf8h 4 месяца назад

    Hi @Reza. This video really helped during my first POC. I ran into an issue. not sure if its a bug.
    Now the Calendar view does not display the SharePoint List Data but if I edit the item in SP and save it as is, it will then display in PowerApps. I tried removing the data source and adding it again but didnt help.
    Request your assistance please. Thanks again

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Calendar view?

    • @pritishable
      @pritishable 4 месяца назад

      Sorry, it's this video
      ruclips.net/video/pA7pcAOvf10/видео.htmlfeature=shared

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      I do not remember running into any issues with that video. I would recommend posting your issue on forums at powerusers.microsoft.com/

  • @giorgiosurian2190
    @giorgiosurian2190 4 месяца назад

    Thank you as always! Question, doesn't this way make many more calls to the database compared to collections? Example, I have a collection of employees. In many galleries with records inserted by employees I want their picture to be displayed. With a collection I made one single call OnStart, wouldn't NamedFormulas make 1 call for each record of the galleries to retrieve the pictures of employees having hundreds of separate calls each time?
    Also, would views from Sql Server also be automatically refreshed?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Calls within galleries (n+1) query should be taken into consideration. For that specific scenario, a collection makes more sense

    • @giorgiosurian2190
      @giorgiosurian2190 4 месяца назад

      Understood, thank you. Would views from SQL be automatically refreshed?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      @@giorgiosurian2190 I have not tried with sql views hence not sure

  • @naveen-i3w
    @naveen-i3w 24 дня назад

    when iam trying to write a named formula to a list and when i see data from name formula variables pane ,it is displaying as 0 rows
    eg: nfListName='List Name' ,'List Name' is sharepoint list name. But other named formulas are assigning as you mentioned in the video

    • @RezaDorrani
      @RezaDorrani  24 дня назад

      Im not sure why that would be the case

  • @adityapadmawar8754
    @adityapadmawar8754 3 месяца назад

    Hi Reza sir, is UDF still a preview feature? When can we expect this function in production?

  • @Vennex89
    @Vennex89 2 месяца назад

    Hi Reza, I have some complex collections I use that I've split into two collections: 1 to collect the raw data and another to do non-delegable functions on the raw data. How does this play into Formulas? Just now when I tried transferring these collections over to formulas and added the named formula to a gallery, it almost stalled out the app. 😅 Any pointers? Should I get the raw data as a formula and a normal collection for the complex work afterwards? Or the other way around?

    • @RezaDorrani
      @RezaDorrani  2 месяца назад +1

      Non-delegable functions will remain non-delegable. You use collections or not, it won't matter. I encourage using delegable functions only.

    • @Vennex89
      @Vennex89 2 месяца назад

      @@RezaDorrani Thank you! So if I need to perform functions that are not delegable, like "AddColumns", should I use the Named Formulas to get the raw data first, such as just filtering by RecordStatus = "Active", and then create a collection off of that Named Formula? I guess I'm just trying to determine whether it is faster this way or if I should just do it all using collections instead.
      Appreciate the response if you have the time. Thank you again!

    • @RezaDorrani
      @RezaDorrani  2 месяца назад +1

      @@Vennex89 It wont be faster as query is not delegable. Continue using collections

    • @Vennex89
      @Vennex89 2 месяца назад

      @@RezaDorrani Thank you! Really appreciate it Reza! And thank you for responding to comments. You are only of my true and faithfuls to go to!

  • @gaultztaguinod9289
    @gaultztaguinod9289 4 месяца назад

    Last time I used User Defined Function (a few weeks ago), my canvas app wouldn't publish - it just kept trying but was never successful.
    I had to roll back my changes to fix.
    Has anyone successfully publish to production?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Yes, I was able to 😊
      Trick is to reference data sources separately. Check the named formulas syntax I show at end of video.

  • @rudivanderlocht3212
    @rudivanderlocht3212 4 месяца назад

    Reza, Can named formulas already be used in a PROD environment?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Named Formulas is generally available and should be used for production scenarios.
      UDF is in preview.

  • @siddeshgawande3924
    @siddeshgawande3924 4 месяца назад

    Hii reza, is it possible to Navigate different screen if user having access then navigate to screen 1 otherwise navigate to Screen 2.
    In start screen and on start property of app I am not able to Navigate screen automatically by reading my access management.. Pls provide any solution
    While loading app 1st read the access, based on that navigate to particular screen

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Closest video link I have is ruclips.net/video/Hrc51S2NgBo/видео.html

  • @pintu1502
    @pintu1502 4 месяца назад

    Hi Reza
    how to put row limit in editable table in powerapp. like only want 10 rows in editable table .

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Check firstN formula documentation

  • @ashokreddy9723
    @ashokreddy9723 Месяц назад

    Hi Reza, you are replaced onstart code with named formula but in onstart property we are creating the collection and creating a variables right, if we delete here and write code on named formulas is any error will come because the collection, variable syntax is breaking right, could you please clarify on this....

    • @RezaDorrani
      @RezaDorrani  Месяц назад +1

      Note: I said move onstart code to named formulas for scenarios where you know the values wont change in app.

    • @ashokreddy9723
      @ashokreddy9723 Месяц назад

      @@RezaDorrani understood Thanks

  • @dixitjoshi3947
    @dixitjoshi3947 4 месяца назад

    So, If we attach the named Formula to a gallery component will it automatically refresh or we have to manually refresh it.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      It will auto refresh when user lands on the page having the gallery or a filter or reset action is initiated.

    • @dixitjoshi3947
      @dixitjoshi3947 4 месяца назад +1

      @@RezaDorranigot it. Thanks for the super fast response.

  • @gates1978
    @gates1978 4 месяца назад

    Thank you so much. I can't find the li k to download.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      Link to download is for members only (check description for details)

  • @GordeNN
    @GordeNN 3 месяца назад

    Can we do patch SharePoint list inside UDF?

    • @RezaDorrani
      @RezaDorrani  3 месяца назад

      Have not tried it so not sure

  • @fr.minabarsoum8528
    @fr.minabarsoum8528 2 месяца назад

    Hello there, I am trying to load more than 2000 records into a table in a named formula section using forall but can't achieve that. Appreciate your help

    • @RezaDorrani
      @RezaDorrani  2 месяца назад

      ForAll is NOT a delegable function.
      Best to follow best practices and work with delegation - watch ruclips.net/video/2cKcylsGlPg/видео.htmlsi=VxmN0FnKcMdLcPfB

    • @fr.minabarsoum8528
      @fr.minabarsoum8528 2 месяца назад

      @@RezaDorrani Sure - anyother suggestion how to load the 3 iterration of 2000 records each into 1 table but not as a collection (managed to do that in the onstart function) but was really happy to move most of my funcitons to formulas after watching this video

    • @RezaDorrani
      @RezaDorrani  2 месяца назад

      Why do u need to load all data at once?
      If your query is delegable, as you scroll through the results it will load all the data.

    • @fr.minabarsoum8528
      @fr.minabarsoum8528 2 месяца назад

      Because the query is not delegable, hence I'm trying to load it all.

    • @RezaDorrani
      @RezaDorrani  2 месяца назад

      @@fr.minabarsoum8528 That will impact app performance in a big way and not recommended.

  • @GroverParkGeorge
    @GroverParkGeorge 4 месяца назад

    I love the idea of UDFs. Can I call a SQL Server Stored Procedure from a UDF in a Named Formula?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      Sql stored procedure just got announced. I have not tried it. Give it a shot and see.

    • @GroverParkGeorge
      @GroverParkGeorge 4 месяца назад +1

      @@RezaDorrani LOL. That's a nicer way of telling people what I always tell people in forums. "What happened when YOU tried it?" I will let you know. 😊😊

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      @@GroverParkGeorge Always best to try it.

    • @GroverParkGeorge
      @GroverParkGeorge 4 месяца назад

      @@RezaDorrani It looks like SQL Server Stored Procs can't be executed in Named Formulas. 😔😔

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      @@GroverParkGeorge same with cloud flows.

  • @jevinwang3769
    @jevinwang3769 4 месяца назад

    How come I defined the named formula without error, but when I try to use it, it shows "unknown or unsupported function"? thanks!

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      No idea about that as I have not experienced this

    • @jevinwang3769
      @jevinwang3769 4 месяца назад

      @@RezaDorrani Oh I know - forgot to toggle the UDF on

  • @steviesimsii
    @steviesimsii 4 месяца назад

    Can you call power automated flows with named formulas?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      Currently, No

    • @steviesimsii
      @steviesimsii 4 месяца назад

      @@RezaDorrani Ok so run The call OnStart , set the return in a variable and then Collect the collection in named formulas !?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      @@steviesimsii Better to use collection in those scenarios.

  • @shaikhrijwan9322
    @shaikhrijwan9322 4 месяца назад

    Hello sir...
    I want to watch your power platform training videos...
    So. How much amount i need to pay?

    • @RezaDorrani
      @RezaDorrani  4 месяца назад +1

      If you click on JOIN button on my channel on a web browser, it will show you the pricing for each tier.

  • @ravirachchh4062
    @ravirachchh4062 4 месяца назад

    Record and Table type of parameter not supported?

  • @malikhan0123
    @malikhan0123 4 месяца назад +1

    Happy Ramazan

  • @pream7461
    @pream7461 4 месяца назад

    @RezaDorrani "I have a question regarding PowerApps form mode. When I add an attachment to the form and then switch to view mode, clicking on the attachment opens it in a new tab. However, PDF and image files open in view mode as intended, while Word documents and Excel files open in edit mode. I want all file types and documents to open in view mode when clicked on in a new tab". Clear the doubt and make one video.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      I have not experienced an issue with opening attachment based on modes hence not sure.
      I recommend posting your issue on forums in case someone has experienced something similar powerusers.microsoft.com

    • @pream7461
      @pream7461 4 месяца назад

      @@RezaDorrani Thank you @RezaDorrani 🤝.
      "Why don't you try using PowerApps to achieve this?"

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      @@pream7461 "Why don't you try using PowerApps to achieve this?" ??

    • @pream7461
      @pream7461 4 месяца назад

      @@RezaDorrani😂😂 I've experimented multiple times, but unfortunately, I haven't been successful in achieving the desired effect. I'm seeking your guidance and expertise for a suitable solution recommendation.

    • @RezaDorrani
      @RezaDorrani  4 месяца назад

      @@pream7461 I cannot reproduce your issue. Best place to post your issue would be the forums powerusers.microsoft.com/