English

How To: Create a batch file to manage 2 ArcSDE instances installed on the same Windows server

Summary

Instructions provided describe how to create a batch file to manage 2 ArcSDE instances installed on the same Windows server. When working with two instances of ArcSDE installed on the same server from the command line, it is best to have two environments set up. Run a batch file to set up the individual environments.

Procedure

Follow the steps below.

Customize this sample batch file to set up the individual ArcSDE environments:

Code:
echo off
rem Set path to sdebin directory
rem Describe the SDE environment

rem SDETYPE is a unique identifying string for this environment setup
set SDETYPE=NUNDA_ARCSDE802_ORA816

rem SDEDBBRAND should be ORACLE, DB2, INFORMIX, SQLSRVR or COVERAGES
set SDEDBBRAND=ORACLE

rem Where are the SDE utility programs on this system that you will use to access
rem the SDE server? Please note: you must use SDE 3.x utilities on your system
rem to talk to SDE 3.x servers and ArcSDE 8.x utilities for ArcSDE 8.x
rem servers.
set SDEHOME=C:\ArcGIS\arcexe81\arcsde\ora8iexe
rem Set the Oracle SID
set ORACLE_SID=orcl1

rem Add SDEHOME to your path
set PATH=%SDEHOME%\bin;%SDEHOME%\lib;%PATH%
rem C:\arcexe80\arcsde\sqlexe\bin;C:\arcexe80\arcsde\sqlexe\lib

rem Standard SDE connection needs
set SDEINSTANCE=sde8ora8i
set SDEUSERNAME=sde
set SDEPASSWORD=sde
set SDEHOSTNAME=keshequa

rem Set a title for the command window
set SDETITLE=SDE for %SDEDBBRAND%: %SDEHOSTNAME%:%SDEINSTANCE%

echo SDE Host Computer: %SDEHOSTNAME%
echo SDE Instance: %SDEINSTANCE%

echo on