I have a problem about that I will get reverse sequence message if the stored procedure called from linked server. I'm much appreciated if anyone know the root cause or provide a solution. Thanks in advance.
This is my test code:
CREATE PROCEDURE [dbo].[TestSP]
AS
BEGIN
SET NOCOUNT ON;
PRINT '1'
PRINT '2'
PRINT '3'
END
Calling it like this:
EXEC [dbo].[TestSP] (call by local)
Output:
1
2
3
It will show output with reverse order if executed by another linked server.
For example,
EXEC [XXX.XXX.XXX.XXX].[dbo].[TestSP]
Output:
3
2
1
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…