on 08-25-2007 11:44 PM
I am installing xEM 2.0 SP 10 (SAP xApp Emissions Management) in a windows environment with SQL 5000. I installed xEM on NW 2004, usage types AS Java and EP 6.
I am attempting to load the initial data or the variances (delta) data into the system. Instruction is on page 15 in the install guide.
I am supposed to enter the following in the command line:
java -Djava.ext.dirs=. -jar SAPtrans.jar import logfile=import.log datafile=init.dat connectstring=[JDBC Driver];[JDBCUrl];[User];[Password]
Example command for import into SQL Server:
java -Djava.ext.dirs=. -jar SAPtrans.jar import logfile=import.log datafile=init.dat connectstring=com.ddtek.jdbc.sqlserver.SQLServerDriver; jdbc:datadirect:sqlserver://vma03:1433;SAPC11DB;password
The customer I am with is running the xEM database on a different instance. This is where I run into a problem. I am not sure how to specify the instance in the script. This is what I have attempted so far:
C:\>cd temp\load
C:\Temp\load>java -Djava.ext.dirs=. -jar SAPtrans.jar import logfile=import.log datafile=init.dat connectstring=com.ddte
k.jdbc.sqlserver.SQLServerDriver;jdbc:datadirect:sqlserver://PRODSQL43:SQL3:1534;SAPPEMDB;password
java.lang.Exception: ERROR: Cannot connect to the database:ERROR: Connect failed to database jdbc:datadirect:sqlserver:/
/PRODSQL43:SQL3:1534 as user SAPPEMDB (java.sql.SQLException/[DataDirect][SQLServer JDBC Driver]Unable to connect. Inva
lid URL.): [DataDirect][SQLServer JDBC Driver]Unable to connect. Invalid URL.
at com.sap.sdm.util.dbaccess.DBTask.dbImport(DBTask.java:356)
at com.sap.sdm.util.dbaccess.SapTransTask.perform_import(SapTransTask.java:293)
at com.sap.sdm.util.dbaccess.SapTransTask.execute(SapTransTask.java:51)
at com.sap.sdm.util.dbaccess.SapTrans.main(SapTrans.java:21)
import aborted with java.lang.Exception: ERROR: Cannot connect to the database:ERROR: Connect failed to database jdbc:da
tadirect:sqlserver://PRODSQL43:SQL3:1534 as user SAPPEMDB (java.sql.SQLException/[DataDirect][SQLServer JDBC Driver]Unab
le to connect. Invalid URL.): [DataDirect][SQLServer JDBC Driver]Unable to connect. Invalid URL.
C:\Temp\load>java -Djava.ext.dirs=. -jar SAPtrans.jar import logfile=import.log datafile=init.dat connectstring=com.ddte
k.jdbc.sqlserver.SQLServerDriver;jdbc:datadirect:sqlserver://PRODSQL43;SQL3:1534;SAPPEMDB;password
java.lang.Exception: ERROR: Cannot connect to the database:ERROR: Connect failed to database jdbc:datadirect:sqlserver:/
/PRODSQL43 as user SQL3:1534 (java.sql.SQLException/[DataDirect][SQLServer JDBC Driver]Error establishing socket. Connec
tion refused: connect): [DataDirect][SQLServer JDBC Driver]Error establishing socket. Connection refused: connect
at com.sap.sdm.util.dbaccess.DBTask.dbImport(DBTask.java:356)
at com.sap.sdm.util.dbaccess.SapTransTask.perform_import(SapTransTask.java:293)
at com.sap.sdm.util.dbaccess.SapTransTask.execute(SapTransTask.java:51)
at com.sap.sdm.util.dbaccess.SapTrans.main(SapTrans.java:21)
import aborted with java.lang.Exception: ERROR: Cannot connect to the database:ERROR: Connect failed to database jdbc:da
tadirect:sqlserver://PRODSQL43 as user SQL3:1534 (java.sql.SQLException/[DataDirect][SQLServer JDBC Driver]Error establi
shing socket. Connection refused: connect): [DataDirect][SQLServer JDBC Driver]Error establishing socket. Connection ref
used: connect
C:\Temp\load>java -Djava.ext.dirs=. -jar SAPtrans.jar import logfile=import.log datafile=init.dat connectstring=com.ddte
k.jdbc.sqlserver.SQLServerDriver;jdbc:datadirect:sqlserver://PRODSQL43:1534;SQL3;SAPPEMDB;password
java.lang.Exception: ERROR: Cannot connect to the database:ERROR: Connect failed to database jdbc:datadirect:sqlserver:/
/PRODSQL43:1534 as user SQL3 (java.sql.SQLException/[DataDirect][SQLServer JDBC Driver][SQLServer]Login failed for user
'SQL3'.): [DataDirect][SQLServer JDBC Driver][SQLServer]Login failed for user 'SQL3'.
at com.sap.sdm.util.dbaccess.DBTask.dbImport(DBTask.java:356)
at com.sap.sdm.util.dbaccess.SapTransTask.perform_import(SapTransTask.java:293)
at com.sap.sdm.util.dbaccess.SapTransTask.execute(SapTransTask.java:51)
at com.sap.sdm.util.dbaccess.SapTrans.main(SapTrans.java:21)
import aborted with java.lang.Exception: ERROR: Cannot connect to the database:ERROR: Connect failed to database jdbc:da
tadirect:sqlserver://PRODSQL43:1534 as user SQL3 (java.sql.SQLException/[DataDirect][SQLServer JDBC Driver][SQLServer]Lo
gin failed for user 'SQL3'.): [DataDirect][SQLServer JDBC Driver][SQLServer]Login failed for user 'SQL3'.
C:\Temp\load>java -Djava.ext.dirs=. -jar SAPtrans.jar import logfile=import.log datafile=init.dat connectstring=com.ddte
k.jdbc.sqlserver.SQLServerDriver;jdbc:datadirect:sqlserver://PRODSQL43:1534:SQL3;SAPPEMDB;password
java.lang.Exception: ERROR: Cannot connect to the database:ERROR: Connect failed to database jdbc:datadirect:sqlserver:/
/PRODSQL43:1534:SQL3 as user SAPPEMDB (java.sql.SQLException/[DataDirect][SQLServer JDBC Driver]Unable to connect. Inva
lid URL.): [DataDirect][SQLServer JDBC Driver]Unable to connect. Invalid URL.
at com.sap.sdm.util.dbaccess.DBTask.dbImport(DBTask.java:356)
at com.sap.sdm.util.dbaccess.SapTransTask.perform_import(SapTransTask.java:293)
at com.sap.sdm.util.dbaccess.SapTransTask.execute(SapTransTask.java:51)
at com.sap.sdm.util.dbaccess.SapTrans.main(SapTrans.java:21)
import aborted with java.lang.Exception: ERROR: Cannot connect to the database:ERROR: Connect failed to database jdbc:da
tadirect:sqlserver://PRODSQL43:1534:SQL3 as user SAPPEMDB (java.sql.SQLException/[DataDirect][SQLServer JDBC Driver]Unab
le to connect. Invalid URL.): [DataDirect][SQLServer JDBC Driver]Unable to connect. Invalid URL.
C:\Temp\load>
My last attempt was a command using colons and semicolons with the following results. The closest (there was a significant delay before the error or failure) appears to have been //PRODSQL43;SQL3:1534; (second attempt). The error listed from this attempt is "Error establishing socket. Connection refused: connect".
I also checked the default database that user SAPPEMDB has in place and it is assign the correct database.
Please help.
Message was edited by: Owner
Mike Smayrabunya
Hey,
It looks like one of the following:
1. The DB is down,
2. The user SAPPEMDB does not have the right authorization.
3. The password of the user SAPPEMDB is not password
4. The syntax is incorrect
in order to find what is the problem,
please:
1. Login in the the DB PRODSQL43:1534 with the user "SAPPEMDB" and the password "password",
this will eliminate the options 1 - DB down, 2 -SAPPEMDB does not have authorization and 3 - password of the user SAPPEMDB is not password.
2. If the login failed, than please run sql trace with security elements (in the client there is a tool called "SQL Profiler"
3. If the login is correct, than you check the syntax of the command:
"java -Djava.ext.dirs=. -jar SAPtrans.jar import logfile=import.log datafile=init.dat connectstring=com.ddtek.jdbc.sqlserver.SQLServerDriver; jdbc:datadirect:sqlserver://vma03:1433;SAPC11DB;password"
According to the error message "Error establishing socket. Connection refused"
it looks like The DB is down or syntax is incorrect.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you for your time. The DB was actually up. I found a resolution:
set path=%JAVA_HOME%\bin;%path%
After modifying the path on the application server so that the java.exe was taken from the C:\j2sdk1.4.2_14\bin-directory (by moving it to the beginning), the SAPTrans could eventually start successfully.
(This actually means: there is somewhere another java.exe in the directories listed in the path before the c:\j2sdk1.4.2_14. This one was used and on this location the charsets.jar couldn't be found (I assume it's searching relative to this position). This should be removed to avoid such problems in the future.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.