Forum Discussion

wojciech's avatar
wojciech
Helper II
11 months ago
Solved

Data Source Parameters in Direct Lake mode

Hi Community,

I’m trying to find out whether it’s possible to parameterize a Direct Lake connection. From what I can see, once connected to a Lakehouse in Direct Lake mode, there’s no option to edit Power Query and add parameters.

Ideally, I’d like to parameterize the Workspace ID and Lakehouse ID in the connection path.

 

expression 'DirectLake - FlowMonitoring' =
    let
        Source = AzureStorage.DataLake(
            "https://onelake.dfs.fabric.microsoft.com/r0000d91-0000-0000-9745-4rty2fa0e23c/bb2xz8c3-0000-0000-0000-0056c4f0000", 
            [HierarchicalNavigation = true]
        )
    in
        Source

I took the above from the TMDL view. However, I’m not sure what the best way is to repoint my Direct Lake model to a different Lakehouse when promoting the model across workspaces.

 

Any advice would be much appreciated.

 

Thanks,
WJ

11 Replies

  • Hi wojciech ,

     

    If you are using Fabric I would suggest that you use a deployment pipelines to make the deploy to the final workspace, that will allow you to define the correct workspace and lakhouseid without the need to do it at the report level.

    https://learn.microsoft.com/en-us/fabric/cicd/deployment-pipelines/get-started-with-deployment-pipelines?tabs=from-fabric%2Cnew-ui

     

    You need to define the rules for the semantic model in order to get the correct values

    https://learn.microsoft.com/en-us/fabric/cicd/deployment-pipelines/create-rules?tabs=new-ui

     

     

    • wojciech's avatar
      wojciech
      Helper II

      Thanks Miguel,

      That could work, but we don't really use deployment pipelines for various reasons.

       

      Are we saying that parmetarisiation of direct lake models is currently not supported then?

       

      Thank you,

       

      WJ

      • MFelix's avatar
        MFelix
        Super User

        Hi wojciech ,

         

        Just to understand a little bit better when you refer to parameters in a connection to Direct lake you are refering to a Report connected to Direct Lake semantic model, or do you want to parameterize the Direct Lake semantic model itself?

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi wojciech ,

    Thanks both for the clarifications so far. wojciech  did you get a chance to look into the MFelix  follow-up question around whether you meant parameterizing the report connection or the Direct Lake semantic model itself? That distinction will really help narrow down if there’s any possible workaround outside of deployment pipelines.

    Regards,
    Akhil.

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi wojciech ,

    Just checking in, were you able to look into super user follow-up on whether you were referring to parameterizing the report connection or the Direct Lake semantic model itself? That clarification would really help in figuring out if there’s any workaround beyond deployment pipelines.

    Regards,
    Akhil

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi wojciech ,

    Circling back, were you able to clarify whether you were referring to parameterizing the report connection or the Direct Lake semantic model itself? That detail will help us determine if there’s any workaround beyond deployment pipelines. Let us know what you found so we can provide the right guidance.

    Regards,
    Akhil.

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi wojciech ,

    I hope the response provided helped in resolving the issue. If you still have any questions, please let us know we are happy to address.

    Thanks,
    Akhil.

  • Hello,

    anybody solve the case without using semantic labs? 
    Like in Power BI Studio?