If you are using a stored procedure, I suspect, that query on a query would not work for you anyway.
I have read, on here, that people have managed to get stored procedures to work in Webi, but it is unsupported, more here:-
https://bobj-board.org/t/94285
In 3.0 and above you can create a universe level stored procedure solution, you can then use this in Webi.
Mak 1 (BOB member since 2005-01-06)