SELECT Val from storedp_Value in the SQL Server Management Studio query editor, is this possible?
UPDATE
I tried to create a temporary table, but it didn't seem to work, so I asked here.
CREATE TABLE #Result ( batchno_seq_no int ) INSERT #Result EXEC storedp_UPDATEBATCH SELECT * from #Result DROP TABLE #Result RETURN
Saved UpdateBatch Procedure
delete from batchno_seq; insert into batchno_seq default values; select @batchno_seq= batchno_seq_no from batchno_seq RETURN @batchno_seq
What am I doing wrong and how to call it from the request window?
UPDATE # 2
Well, I would be grateful for the help in this direction or something else - this is what I am trying to achieve.
select batchno_seq from (delete from batchno_seq;insert into batchno_seq default values; select * from batchno_seq) BATCHNO INTO TEMP_DW_EKSTICKER_CLASSIC
This is part of a larger select statement. Any help is appreciated. In essence, this SQL code is corrupted as we migrated for Oracle.
sql sql-server tsql sql-server-2008
Nate
source share