Using Google Chrome?

Download my
free Chrome Extension, Power Notes Searcher, to make searching for and evaluating SAP notes, much easier.

Recent Posts

Thursday, March 17, 2016

SAP ASE with SAP Replication Server - Node ID

Print Friendly and PDF
While working on a SAP ASE database configured with SAP Replication Server (SRS) as part of a HADR pair, you may want to know how to identify which of the two databases in the HADR pair, you’re working on.

The only sure method I found is to query the @@nodeid global variable.
This nodeid value is different for each of the ASE databases.
Therefore if you’re logged onto the primary node, you will see a different ID.

I found this to be exceptionally useful when logging into a database as sapsso, since this user is redirected to the primary database in a HADR setup.
 

UPDATE: July 2016, I've since found this little gem:

> isql -Usapsa -S<SID> -w999 -X

1> select ASEHOSTNAME()
2> go

-------------------------------
SERVERHOSTNAME

(1 row affected)

No comments: