Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.
Hi All,
How do we reference multiple lakehouse within a notebook. Can anyone please help me with sample code for writing data to another lakehouse Table within the workspace.
when I try this code, it gives me error - silver_zone is not defined. but i have created a lakehouse named silver_zone
df.write.format("delta").mode("overwrite") \ .saveAsTable('silver_zone.output_table_Silver')
Thanks,
Pallavi
Solved! Go to Solution.
Hey @pallavi_r ,
I assume that both lakehouses are in the same workspace as the notebook, then this is a strange message because this is my sample code:
# the default lakehouse of the notebook
df_asimpletable.write.mode("overwrite").format("delta").saveAsTable("df_asimpletable_new")
# another lakehouse but the same workspace
df_asimpletable.write.mode("overwrite").format("delta").saveAsTable('a_new_lakehouse.df_asimpletable_newer')
And it works perfectly.
Hopefully, this helps to tackle your challenge.
Regards,
Tom
Hey @pallavi_r ,
I assume that both lakehouses are in the same workspace as the notebook, then this is a strange message because this is my sample code:
# the default lakehouse of the notebook
df_asimpletable.write.mode("overwrite").format("delta").saveAsTable("df_asimpletable_new")
# another lakehouse but the same workspace
df_asimpletable.write.mode("overwrite").format("delta").saveAsTable('a_new_lakehouse.df_asimpletable_newer')
And it works perfectly.
Hopefully, this helps to tackle your challenge.
Regards,
Tom
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.