Hi ,
Actually I added serveral ' print step(n) ' to the script to see how far it would go.
It stops short of this part:
-- ** -------------------------------------** --
DECLARE @max_rows INT, @Row_Count INT
SET @Row_Count = 1
SELECT @max_rows=count(*) FROM @DATABASES_TO_RESTORE
The piece that procedes it works just fine.
SELECT '25000994', '25000994'
UNION
SELECT '25001905', '25001905'
A select on the temporary database shows the values.
But after this nothing is printed anymore despite the print statements that follow.
cheers,
Cor