Hello,
i am getting a little confusesd by your code, where do you adress the "temp table" ?
i hope the following ist still true because i havent used ASE for a while:
In ASE a temp table is any table prefixed with "#" and is stored in tempdb.
The name of this table follows the rules for normal tablenames( prefixed # ) , but is internally changed to avoid problems with other processes using the same tablename. Nevertheless the namechange ist transparent in your session of isql or whatever.
some more information on temptables you can get from Rob Verschoor:
Reading temporary tables that aren't yours
cheers
dj