Windows recipe
HL
Registered Posts: 14 ✭✭✭
Hello, I am currently working on a window recipe (to add a row number), and I would like this row number to be in the first column without using a Prepare recipe exclusively for that. Do you think it is possible ? Thank you !
Comments
-
Turribeach Dataiku DSS Core Designer, Neuron, Dataiku DSS Adv Designer, Registered, Neuron 2023 Posts: 2,185 Neuron
The esiest way is to use a Prepare recipe and define the formula as rowIndex. This will give an ID from 0 to N. If you want to start from 1 you can use "rowIndex + 1". You can add a row number in a Window recipe but it will need to have a sort order set. Where is using a Prepare recipe won't need a sort order.