I have a problem with a stored procedure.
The procedure gets as an argument the number of rows needed, but the following does not work in HANA:
SELECT TOP :NUM_OF_ROWS * FROM TABLE_NAME
I read that TOP in HANA only receives a number, not an expression. Is there another way to do this? My solution for the moment is to select everything and delete the unneeded records on the service, but it's not very efficient.
Instead of TOP n you can use the LIMIT n option. That one can bind variables.