This is best Fabric, Power BI, SQL and AI community event. How do we know? The last event sold out! Save €200 with code FABCMTY200.
Register nowA new Data Days event is coming soon! This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. Don't miss out.
I have a Fabric Data Warehouse. I want to export some views create script into a SQL file. Basically generate script operation. Is it possible ?
This type of scripts is not working:
SELECT
s.name AS schema_name,
v.name AS view_name,
m.definition
FROM sys.views v
INNER JOIN sys.sql_modules m ON v.object_id = m.object_id
INNER JOIN sys.schemas s ON v.schema_id = s.schema_id
where v.name like '%TEST'
ORDER BY s.name, v.name;
Solved! Go to Solution.
I ran the script (without the where and order by clause) and that works just fine in SSMS and the fabric UI.
The '%TEST' may be invalid. Try running it without the where and see what the results are? PS Keep in mind it is case sensitive.
What is it exactly what you are trying to achieve?
Cheers
Hans
Hi @selsoft1907 ,
Thank you for reaching out to the Microsoft Community Forum.
Hi @smeetsh Thank you for your prompt response.
Hi @selsoft1907 , As mentioned by @smeetsh , please provide more details about your issue and what you are trying to achieve.
Regards,
Dinesh
Hi @selsoft1907 ,
Thank you for reaching out to the Microsoft Community Forum.
Hi @smeetsh Thank you for your prompt response.
Hi @selsoft1907 , As mentioned by @smeetsh , please provide more details about your issue and what you are trying to achieve.
Regards,
Dinesh
I ran the script (without the where and order by clause) and that works just fine in SSMS and the fabric UI.
The '%TEST' may be invalid. Try running it without the where and see what the results are? PS Keep in mind it is case sensitive.
What is it exactly what you are trying to achieve?
Cheers
Hans
I fix the issue. The reason behind ssms. When I run this script it return space for view definition column. However when I run under fabric portal it returns data. Maybe reason is permissions.
Check out the April 2026 Fabric update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
| User | Count |
|---|---|
| 8 | |
| 7 | |
| 4 | |
| 4 | |
| 3 |
| User | Count |
|---|---|
| 21 | |
| 13 | |
| 10 | |
| 6 | |
| 6 |