Skip to content
Advertisement

spool to .csv file using for loop

need to spool output into .csv file using loop, fyi…I have data in 4 diff partition.

but no sure how to proceed.

code be like.

result:-

not sure if I am spooling properly, also please check the index variable of for loop in used correctly in my select statement.

Advertisement

Answer

You don’t need 4 different queries, just list all your partitions in the query:

User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement