Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Sign up nowGet Fabric certified for FREE! Don't miss your chance! Learn more
Anyone know how DECLARE CURSOR works in Fabric? Is it not supported at all?
It supports in fabric script activities.
DECLARE CURSOR is not supported in Microsoft Fabric.
Use set-based queries (JOIN, CTE, MERGE, window functions) or Fabric components (Dataflows/Notebooks) instead.
Hallo The fabric toolbox contains many options and tricks manipulate data and to create cursor like functions. It depends on your situation, skills and the type of cursor you are looking for.
I see several options. To name a few: If you want to calculate a value , per group. You can alway´s use DAX and PowerBI within Fabric.
For example:
_previous value PREVIOUSDAY = CALCULATE ( SUM ( MyTable[Value] ), FILTER ( MyTable, MyTable[Date] = PREVIOUSDAY ( LASTDATE ( ALLSELECTED ( MyTable[Date] ) ) ) ) )
The result can be exported via the Powerautomate ´visual´ to almost any sink.
Another way is to create a query in powerquery m.
Grouping in Power Query; Getting The Last Item in Each Group - RADACAD
A third way would be to use a notebook. python - Assign Last Value of DataFrame Group to All Entries of That Group - Stack Overflow
Another option is the goodold Data factory (my personal favorite). Create wome aggregate activities to feed a warehouse or lakehouse.
There are probaly many more options i forgot.
Good luck.
If you love stickers, then you will definitely want to check out our Community Sticker Challenge!
Check out the January 2026 Fabric update to learn about new features.