Issue with running scenario from command line-RESOLVED
I have made appropriate changes in the odiparams.bat file and am trying to run the startscen command from the bin directory of the ODI installation on windows XP Pro SP2
startscen DPRI_SEC_PKG_POP_PRI_SEC_TBLS 001 GLOBAL "-v=2"
set ODI_SECU_DRIVER=oracle.jdbc.driver.OracleDriver
set ODI_SECU_URL=jdbc:oracle:thin:@pridb-test-1:1521:PRISBOX
set ODI_SECU_USER=PRI_MST_TST
set ODI_SECU_ENCODED_PASS=b1ya.1dDo.cclkh.IVhi5Ovp
set ODI_SECU_WORK_REP=PRI_WRK_TST
set ODI_USER=SUPERVISOR
set ODI_ENCODED_PASS=a7yXIxOwQ4avmSJZia4,79QAp
Below is the error I get:
OracleDI: Starting scenario DPRI_SEC_PKG_POP_PRI_SEC_TBLS 001 in context GLOBAL
com.sunopsis.sql.c: oracle.jdbc.driver.OracleDriver
at com.sunopsis.sql.SnpsConnection.a(SnpsConnection.java)
at com.sunopsis.sql.SnpsConnection.connect(SnpsConnection.java)
at com.sunopsis.dwg.cmd.e.h(e.java)
at com.sunopsis.dwg.cmd.e.g(e.java)
at com.sunopsis.dwg.cmd.e.y(e.java)
at com.sunopsis.dwg.DwgJv.treatCmd(DwgJv.java)
at com.sunopsis.dwg.DwgJv.main(DwgJv.java)
at oracle.odi.Agent.main(Agent.java)
DwgJv.main: Exit. Return code:-1
Please suggest where I might be going wrong? I've made sure that the repository connections as correct. It is not really telling what is wrong or maybe I don't understand the error message.
Edited by: user10184763 on Sep 26, 2008 10:50 AM
ALRIGHT....I picked up the original backed up odiparams.bat file and entered all the information one more time and then it worked...I dont know waht happened..but it worked!! Thanks people!
Edited by: zebango on Oct 14, 2008 10:39 AM
Still getting the same error. Work repository name is correct. Passwords freshly encoded. The thing is everytime I run the command agent encode <password> it gives me a new encoded password. Is tht expected behavior??
bq. C:\Program Files\Oracle\oracledi\oracledi\bin>startscen DPRI_SEC_PKG_POP_PRI_SEC \\ TBLS 001 GLOBAL "-v=2" \\ OracleDI: Starting scenario DPRISEC_PKG_POP_PRI_SEC_TBLS 001 in context GLOBAL \\ ... \\ com.sunopsis.sql.c: sun.jdbc.odbc.JdbcOdbcDriver \\ at com.sunopsis.sql.SnpsConnection.a(SnpsConnection.java) \\ at com.sunopsis.sql.SnpsConnection.connect(SnpsConnection.java) \\ at com.sunopsis.dwg.cmd.e.h(e.java) \\ at com.sunopsis.dwg.cmd.e.g(e.java) \\ at com.sunopsis.dwg.cmd.e.y(e.java) \\ at com.sunopsis.dwg.DwgJv.treatCmd(DwgJv.java) \\ at com.sunopsis.dwg.DwgJv.main(DwgJv.java) \\ at oracle.odi.Agent.main(Agent.java) \\ DwgJv.main: Exit. Return code:-1
My ODI params.bat for reference. again this Windows XP Prof2
bq. set ODI_SECU_DRIVER=sun.jdbc.odbc.JdbcOdbcDriver \\ set ODI_SECU_URL=jdbc:oracle:thin:@pridb-test-1:1521:PRISBOX \\ set ODI_SECU_USER=PRI_MST_TST \\ set ODI_SECU_ENCODED_PASS=b1yaZszHYl5dvTmffPVqRhkp \\ set ODI_SECU_WORK_REP=PRI_WRK_TST \\ set ODI_USER=SUPERVISOR \\ set ODI_ENCODED_PASS=a7yXTDTi0KW4pefy2MPpHSuDy
Any suggestions?
Similar Messages
-
How to run Ant from command line in Tarantella env?
I am getting Exception in thread "main" java.lang.NoClassDefFoundError: org.apache.tools.ant.launch.Launcher error message when I run Ant from tarantella command line. Is this Ant version issue? I can only find Ant with version 1.4.2. Where can I find the correct Ant version (1.6.5) and what class path do I need to specify if I want to run Ant from command line. This works if I run Ant inside of Jdeveloper 11g.
thanksHi
What is the correct Java version? What are the steps to rectify the problem? -
Problem with tokenized input from command line
I am trying to take an input from the command line, parse it to tokens and perform whatever operation is needed depending on the name of the token, on a binary tree of stacks for example, if i type 1 2 1 3 printLevelOrder, then the root of the tree should have 3, 2,1 in the stack, the left child should have 1 and the right child should be empty. and then a level order print of the tree should be performed.
however what is happening when i run this code is the numbers are being put into the right stacks of the tree, but any commands such as printLevelOrder or PrintPopRoot are entering the code that is for placing numbers onto the stack instead of executing that command and skipping past this piece of code.
so my question is, why is the if statement if (word =="printLevelOrder") not being executed when thats whats in the word ?
example input and output shown below code fragment.
try {
BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
String line = "";
while (line != "***") {
System.out.print("> prompt ");
line = in.readLine();
StringTokenizer tokenizer = new StringTokenizer(line," ");
String word = new String();
while (tokenizer.hasMoreTokens()) {
word = tokenizer.nextToken();
boolean notCommand = true;
if (word =="printLevelOrder") {
theTree.printLevelOrder();
System.out.println("(word ==printLevelOrder)");
notCommand=false;
if (word == "printPopLevelOrder") {
theTree.printPopLevelOrder();
notCommand=false;
if (word == "printPopInorder") {
theTree.printPopInorder();
notCommand=false;
if (word == "printPopPreorder") {
theTree.printPopPreorder();
notCommand=false;
if (word == "printPopRoot") {
theTree.printPopRoot();
notCommand=false;
if (word == "***") {
notCommand=false;
if (notCommand == true) {
System.out.println("(notCommand == true)");
boolean notPlaced = true;
int v = 1;
while ((notPlaced==true) && (v < theTree.size())) {
if (theTree.element(v).isEmpty()) {
theTree.element(v).push(Integer.valueOf(word));
System.out.println("Inserting"+word);
System.out.println("in empty stack at location: "+v);
notPlaced=false;
if (notPlaced==true) {
if ( Integer.valueOf(word) >= Integer.valueOf( theTree.element(v).top().toString() ) ) {
theTree.element(v).push(Integer.valueOf(word));
System.out.println("Inserting"+word);
System.out.println("in stack at location: "+v);
notPlaced=false;
v++;
}valid inputs: int value, printLevelOrder, printPopLevelOrder, printPopInorder, p
rintPopPreorder, printPopRoot, *** to quit
prompt 1 3 2 4 2 printLevelOrder(notCommand == true)
Inserting1
in empty stack at location: 1
(notCommand == true)
Inserting3
in stack at location: 1
(notCommand == true)
Inserting2
in empty stack at location: 2
(notCommand == true)
Inserting4
in stack at location: 1
(notCommand == true)
Inserting2
in stack at location: 2
(notCommand == true)
Exception in thread "main" java.lang.NumberFormatException: For input string: "printLevelOrder"
at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
at java.lang.Integer.parseInt(Integer.java:447)
at java.lang.Integer.valueOf(Integer.java:553)
at TreeStack.main(TreeStack.java:73)
Press any key to continue . . .lol aww, shame that you forgot to do that. i had 10 / 10 for mine, and seing as the deadline is now well and trully over,
here is the entire source for anybody who was following the discussion or whatever and wanted to experiment.
additional files needed >
http://users.cs.cf.ac.uk/Paul.Rosin/CM0212/Stack.java
http://users.cs.cf.ac.uk/Paul.Rosin/CM0212/ArrayStack.java
http://users.cs.cf.ac.uk/Paul.Rosin/CM0212/StackEmptyException.java
http://users.cs.cf.ac.uk/Paul.Rosin/CM0212/StackFullException.java
/*TreeStack.java - reads command line input of values and assigns them to stacks in a binary tree and performs
operations on the ADT. valid inputs: <int>, printLevelOrder, printPopLevelOrder,
printPopInorder, printPopPreOrder, printPopRoot. Terminates on invalid input.
Written by George St. Clair.
S/N:0208456 22/11/2005
import java.util.Vector;
import java.io.*;
import java.util.StringTokenizer;
public class TreeStack {
private final int TREE_CAPACITY = 7 + 1;
private final int STACK_CAPACITY = 10;
Vector tree = new Vector(TREE_CAPACITY) ;
//collect input from command line, add values to stacks at nodes of the teee
//and perform required operations on the treestack
public static void main (String [] args) {
//create a tree of stacks
TreeStack theTree = new TreeStack ();
try {
//collect standard input
BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
String line = "";
while (line != null) {
System.out.print("");
line = in.readLine();
//tokenise input
StringTokenizer tokenizer = new StringTokenizer(line," ");
String word = new String();
while (tokenizer.hasMoreTokens()) {
//assign word to the token
word = tokenizer.nextToken();
boolean notCommand = true;
//perform operation on treestack depending on what word is
if (word.equals("printLevelOrder")) {
System.out.println("printLevelOrder");
theTree.printLevelOrder();
notCommand=false;
if (word.equals("printPopLevelOrder")) {
System.out.println("printPopLevelOrder");
theTree.printPopLevelOrder();
notCommand=false;
if (word.equals("printPopInorder")) {
System.out.println("printPopInorder");
theTree.printPopInorder();
notCommand=false;
if (word.equals("printPopPreorder")) {
System.out.println("printPopPreorder");
theTree.printPopPreorder();
notCommand=false;
if (word.equals("printPopRoot")) {
System.out.println("printPopRoot");
theTree.printPopRoot();
notCommand=false;
//if word was not a command it must be a number
if (notCommand == true) {
boolean notPlaced = true;
int v = 1;
//starting at the root, find suitable place for number
while ((notPlaced==true) && (v < theTree.size())) {
//if the stack at v is empty, number goes here
if (theTree.element(v).isEmpty()) {
theTree.element(v).push(Integer.valueOf(word));
System.out.println("inserting: "+word);
System.out.println("in empty stack at location: "+(v-1));
notPlaced=false;
//if the stack is not empty
if (notPlaced==true) {
//if the value on the top of the stack is smaller than number, number goes onto the stack
if ( Integer.valueOf(word) > Integer.valueOf( theTree.element(v).top().toString() ) ) {
theTree.element(v).push(Integer.valueOf(word));
System.out.println("inserting: "+word);
System.out.println("in stack at location: "+(v-1));
notPlaced=false;
//if that node was no good, check the next one for suitability
v++;
catch (Exception e) {
//occurs when user inputs something that is neither a command, or a number, or upon EOF, or stack is full
public TreeStack () {
//create the TreeStack ADT by adding stacks in the vector, note vector 0 is instantiated but not used.
for (int i = 1;i<=TREE_CAPACITY;i++)
tree.add(new ArrayStack(STACK_CAPACITY));
public int size() {
//return the size of the tree +1 (as 0 is not used)
return tree.size();
public ArrayStack element (int v) {
//return the ArrayStack at v
return (ArrayStack)tree.get(v);
public int leftChild (int v ) {
//return left child of v
return v*2;
public int rightChild (int v ) {
//return the right child of v
return v*2+1;
public boolean children (int v ) {
//search for children of v and return true if one exists
for (int i =v;i<size();i++) {
if (i/2==v ) {
//left child found at i
return true;
if ((i-1)/2==v ) {
//right child found at i
return true;
//no children found
return false;
public boolean isInternal (int v ) {
//test whether node v is internal (has children)
if (children (v)== true) {
//has children
return true;
return false;
//print the top value in each stack encountered on a level-order traversal of tree
public void printLevelOrder() {
//for every node of tree v
for (int v = 1;v<size();v++) {
if (!element(v).isEmpty() ) {
//print the top value in stack v
System.out.println(" "+element(v).top());
else {
//stack at v is empty
System.out.println(" -");
//pop off and print the top value in each stack encountered on a level-order traversal of tree
public void printPopLevelOrder () {
//pop off and print the top value in stack v
for (int v = 1;v<size();v++) {
//for each node of tree v
if (!element(v).isEmpty() ) {
//if v isnt empty print the top value in stack v
System.out.println(" "+element(v).top());
//pop the top value in the stack at v
element(v).pop();
else {
//stack at v is empty
System.out.println(" -");
//pop off and print the top value in each stack encountered on an in-order traversal of tree
public void printPopInorder () {
printPopInorder (1);
public void printPopInorder (int v) {
boolean isInternal = false;
if (isInternal (v)) {
//use a boolean for isInternal to save on running the method twice
isInternal = true;
//recursively search left subtree
printPopInorder (leftChild(v));
//pop off and print the top value at v
if (element(v).isEmpty() ) {
//stack at v is empty
System.out.println(" -");
else {
//if v isnt empty print the top value in stack v then pop
System.out.println(" "+element(v).top());
element(v).pop();
if (isInternal ) {
//recursively search right subtree
printPopInorder (rightChild(v));
//pop off and print the top value in each stack encountered on an pre-order traversal of tree
public void printPopPreorder() {
printPopPreorder(1);
public void printPopPreorder(int v) {
//pop off and print the top value at v
if (!element(v).isEmpty() ) {
//if v isnt empty print the top value in stack v then pop
System.out.println(" "+element(v).top());
element(v).pop();
else {
//stack at v is empty
System.out.println(" -");
if (isInternal (v)) {
//recursively search left and right subtrees
printPopPreorder (leftChild(v));
printPopPreorder (rightChild(v));
//pop off and print all values from the stack at the root
public void printPopRoot (){
//while the root stack has values left
while (!element(1).isEmpty()) {
//print, then pop
System.out.println(" "+element(1).top());
element(1).pop();
} -
Running report from command line with multiple value for same parameter
Hey,
I know how to run a report from the command line specifying parameters values each time but I was wondering if someone could tell me how I would go about running the same report multiple times in a batch program but specifying a list of values to pass to a parameter each time.
So for example if a parameter was 'School Number', how could I run a report in a batch program that would pass a school number to the report as a parameter using a list of school numbers generated for a sql statement or something. So if I had 300 school numbers in my list then I would get 300 different reports when the batch program finished.
This leads me to another question. How can I dynamically change the name of the report generated by the batch to use the school number value passed in, so for example if the value 3 was passed in the name would be something like School 3.pdf, if 4 was passed in the name would be School 4.pdf....etc
Any help on this?
ThanksHello,
Bursting and Distribution may help you ....
37 Bursting and Distributing a Report
http://download-uk.oracle.com/docs/cd/B14099_17/bi.1012/b13895/orbr_dist.htm
Regards -
Program not running with -cp option from command line
I'm trying to run a very basic emailing program in Linux (Fedora 5) using Sun's j2sdk1.4.2_16.
I can run the program no problem from the command line using
"java RunEmailer"
but if I try both:
"java -cp /usr/lmt-programs/mail_send/RunEmailer"
or
"[JAVA_HOME]/java -cp /usr/lmt-programs/mail_send/RunEmailer"
I keep getting the help print out about options when running java.
I need the -cp option to work as I need to run this program from crontab.
Thanks in advance.uberalles wrote:
"java -cp /usr/lmt-programs/mail_send/RunEmailer"Here you specify the classpath (the directory /usr/lmt-programs/mail_send/RunEmailer) but you don't specify the class that is to be run. If the class you want to run is named RunEmailer and it's in the directory /user/lmt-programs/mail_send then you want this command:
"java -cp /usr/lmt-programs/mail_send RunEmailer" -
Running mxmlc from command line - unable to open file
Hello all,
Just tried to get Flex up and running - but have run into
probably a simple problem. Here's the scenario:
1. I've put the flex 2.0 installation folder on my C drive
such that the path is c:\flex_sdk_2
2. I've set my system path to reference the the mxmlc with
c:\flex_sdk_2\bin
3. I've set up a folder on my desktop for my flex programs,
creatively called 'flex'
4. From my command line I use 'xmxlc --strict=true
--file-specs filename.mxml'
My output is this:
Loading configuration file <etc>
Error: unable to open filename.mxml
As I said before, probably an easy fix but thought I'd put
something up to see if anybody knew an answer off the top of their
head? I'm running Windows XP. Home Edition, V. 2002 if it helps.
Many thanks!
ShannanNevermind, figured it out. My files had the .txt appended to
the end of the file-name.
*der* -
Syntax to run scenario from comand line
Can some one give me the syntax to run a scenario from the command line using an agent.
According with OracleDI Getting Started (page 61):
Run the Scenario from an OS Command
1. Open an MS-DOS command prompt window or a console in UNIX.
2. In the Oracle Data Integrator installation folder, open the "bin" directory.
3. Enter the following command:
startscen LOAD_SALES_ADMINISTRATION 001 GLOBAL "-v=2"
Note: The parameters for the startscen command are:
- Scenario name
- Scenario version
- Scenario context
- Logging level
These parameters are separated by spaces.
4. When execution is finished, the command prompt should look like this:
C:\oracledi\bin>startscen LOAD_SALES_ADMINISTRATION 001 GLOBAL "-
v=2"
Oracle Data Integrator: Starting scenario
LOAD_SALES_ADMINISTRATION 001 in context GLOBAL ...
06/27/2005 11:33:05 AM(main): Creating session for
scenario:LOAD_SALES_ADMINISTRATION - 001
06/27/2005 11:33:06 AM(main): Session : 14003 is running
06/27/2005 11:33:16 AM(main): Session : 14003 finished with
return code : 0
DwgJv.main: Exit. Return code:0
But I got same error (in UNIX):
./startscen.sh FLOW9 001 Development -Name=LOCALHOST_20910
OracleDI: Starting scenario FLOW9 001 in context Development ...
com.sunopsis.core.SnpsInexistantObjectException: SnpContext.getContextByCode : SnpContext does not exist
at com.sunopsis.dwg.dbobj.SnpContext.getContextByCode(SnpContext.java)
at com.sunopsis.dwg.cmd.DwgCommandScenario.b(DwgCommandScenario.java)
at com.sunopsis.dwg.cmd.DwgCommandScenario.treatCommand(DwgCommandScenario.java) -
Errors when running db_stat from command line
Hi,
I'm trying to use db_stat at the command line to generate statistics.
However, I keep getting errors. I cannot use the db->stat call
because this is to be done at a customer site using their existing binary.
Note that the call to db_stat -m fails, while the call to db_stat -d <dbname>
prints an error/warning then appears to succeed.
Most likely, there is some usage subtlety that I have missed.
Any suggestions about what I have done wrong?
I am using BDB 4.6.21 on Windows. Databases are created inside a
db environment.
Here is a transcript:
C:\Program Files\SonicWallES\PluginDefault\collab\data>dir __*
Volume in drive C has no label.
Volume Serial Number is 7084-88E3
Directory of C:\Program Files\SonicWallES\PluginDefault\collab\data
08/07/2008 07:11 PM 24,576 __db.001
08/07/2008 07:11 PM 65,536 __db.002
08/07/2008 07:11 PM 270,336 __db.003
08/07/2008 07:11 PM 499,712 __db.004
4 File(s) 860,160 bytes
0 Dir(s) 2,177,224,704 bytes free
C:\Program Files\SonicWallES\PluginDefault\collab\data>"C:\Program Files\SonicWallES\utilities\bdb\db_stat.exe" -m
db_stat.exe: __db.001: unable to find environment
db_stat.exe: DB_ENV->open: No such file or directory
C:\Program Files\SonicWallES\PluginDefault\collab\data>dir ..
Volume in drive C has no label.
Volume Serial Number is 7084-88E3
Directory of C:\Program Files\SonicWallES\PluginDefault\collab
08/18/2008 12:44 PM <DIR> .
08/18/2008 12:44 PM <DIR> ..
08/07/2008 10:09 PM 2,646,016 c_thumbprint.db
09/05/2008 03:08 PM <DIR> data
07/16/2008 06:43 PM <DIR> dbs
08/07/2008 10:09 PM 42,131,456 e_thumbprint.db
08/07/2008 10:09 PM 10,485,760 f_thumbprint.db
08/07/2008 10:09 PM 5,226,496 g_thumbprint.db
08/07/2008 10:09 PM 41,869,312 h_thumbprint.db
08/07/2008 10:09 PM 41,926,656 i_thumbprint.db
08/09/2008 02:47 AM <DIR> old_data
08/07/2008 10:09 PM 10,633,216 p_thumbprint.db
08/14/2008 05:26 PM 1,749 redirect.xml
09/08/2008 04:12 PM <DIR> sn_data
08/07/2008 10:09 PM 78,725,120 t_thumbprint.db
08/07/2008 10:10 PM 42,074,112 v_thumbprint.db
08/07/2008 10:50 PM 335,790,080 x_thumbprint.db
11 File(s) 611,509,973 bytes
6 Dir(s) 2,177,224,704 bytes free
C:\Program Files\SonicWallES\PluginDefault\collab\data>"C:\Program Files\SonicWallES\utilities\bdb\db_stat.exe" -d ..\x_thumbprint.db
db_stat.exe: __db.001: unable to find environment
Mon Sep 08 16:17:01 2008 Local time
61561 Hash magic number
9 Hash version number
Little-endian Byte order
Flags
8192 Underlying database page size
0 Specified fill factor
4882732 Number of keys in the database
4882732 Number of data items in the database
24548 Number of hash buckets
35M Number of bytes free on bucket pages (82% ff)
0 Number of overflow pages
0 Number of bytes free in overflow pages (0% ff)
8220 Number of bucket overflow pages
32M Number of bytes free in bucket overflow pages (51% ff)
0 Number of duplicate pages
0 Number of bytes free in duplicate pages (0% ff)
1 Number of pages on the free listIf I'm reading your code correctly, you're starting a Korn shell session, then executing your C shell script as if you were at at the session window's prompt. If that is correct, you haven't caused your standard out (stdout) to hit ENTER yet. I'm not an expert, but I hope this works for you.
Your code:
Process Child = runtime.exec("/usr/bin/ksh"); // execute command
BufferedWriter outCommand = new BufferedWriter(new OutputStreamWriter(Child.getOutputStream()));
outCommand.write("/home/mypath/tesh.csh");
outCommand.flush();I think you need to enter one extra line before the flush():
Process Child = runtime.exec("/usr/bin/ksh"); // execute command
BufferedWriter outCommand = new BufferedWriter(new OutputStreamWriter(Child.getOutputStream()));
outCommand.write("/home/mypath/tesh.csh");
outCommand.newLine(); // hit ENTER
outCommand.flush();P.S. If you're running this script and your Java program from the same UNIX machine, you could just execute the shell script inside the runtime.exec() call. -
How to execute ODI scenarios from command line in Unix
Hi Friends,
I am using ODI 11g.
I want to execute ODI senarios using the command line argument in Unix.
Please let me know how to proceed with this.
Thanks,
LonyHi,
unser the /your_ODI_HOME/agent/bin folder.
Excute this
sh startscen.sh REFRESH_ID 001 GLOBAL 5 -NAME=agent_ODI
REFRESH_ID=Your Scenario name
001:Version
GLOBAL:Context name
5=Log Level
agent_ODI=Your agent name
Regards -
Issues with running UNIX shell command from Java
Here is my java class file:
create or replace and compile java source named host as
import java.lang.* ;
public class Host
public static void cmdTest()
String cmd = "ps -ef | grep orcl" ;
int rc = 0 ;
int = runCmd(cmd) ;
public static int runCmd(String str )
Runtime rt = Runtime.getRuntime() ;
int rc = -1 ;
try
Process p = rt.exec(str) ;
int bufSize = 4096 ;
BufferedInputStream bis =
new BufferedInputStream(p.getInputStream(), bufSize) ;
int len ;
byte buffer[] = new byte[bufSize] ;
// Log what the program spit out
while ((len = bis.read(buffer, 0, bufSize)) != -1)
rc = p.waitFor() ;
catch (Exception e)
e.printStackTrace();
rc = -1 ;
finally
return rc ;
show errorsI can call runCmd directly from SQLPlus using an Oracle stored procedure and it runs like expected. I can see the returned output using dbms_java.set_output(1000000).
But when I call cmdTest from SQLPlus using an Oracle stored procecdure it just hangs forever and I have to kill the session.
Is there something I am missing in the cmdTest method?Jimmy,
If you haven't already seen it, I think the following article may be of help:
http://www.javaworld.com/javaworld/jw-12-2000/jw-1229-traps.html
Also a "finally" block should not contain a "return" statement:
http://weblogs.java.net/blog/staufferjames/archive/2007/06/_dont_return_in.html
Good Luck,
Avi. -
Error while running a Discoverer Workbook with parameter from command line
I am trying to run a discoverer report from command line and export the results in xls on to my local machine. I could do it fine for a simple workbook, but if I add a parameter(madatory) to the workbook and run it from command line specifying the parameter value I wanted to run the report for, I do not get any results. Here is the command line I am using.
dis51usr.exe /connect user/password@database /apps_user /apps_responsibility "System Administrator" /eul EUL_US /open C:\Disco\Test.DIS /sheet Testsheet /parameter Period Jan-07 /export xls C:\Disco\X.xls /batch
Parameter value is entered in correct format(Jan-07).
When I removed /batch from this to see if I get any error, Discoverer Desktop opened up, logged in and gets terminated saying 'Oracle Discoverer Desktop has encountered a problem and need to close. We are sorry for the inconvenience.'
Did anybody come across this issue before?Hello,
If you have a few minutes, Windows is also aborting for me:
the differences are, my situation is:
a) am running the command line from a .bat file
b) am NOT running with parms, want the discoverer query to come up for the user
c) am running a query from the database
i am signing in as myself BUT running a query that was created by a generic user called SREG
c) if i run the .bat file from Windows Explorer, the query opens fine
d) if i execute the .bat file from within Microsoft Access using the shell command,
the query opens and then aborts RIGHT BEFORE the parm screen would display
e) btw, if i modify the .bat file, to run a query from MY database signon, then (d) - running .bat file
from vb using SHELL command works
Do you have a ideas as to why (d) does not work? I would be very grateful for your time, tx, sandra
this is what i posted yesterday, tx: Re: Running Discoverer command line
tx, sandra -
Unable to build and run Javapetstore using Sun SDK from Command Line
Hi,
Here is a problem I?ve come across building and running JavaPetstore from Command Line using Ant.
It shows that Build is successful but there is an error message in very beginning:
?Unable to locate tools. jar. Expected to find it in C:\Program Files\Java\jre 1.5.0_11\lib\tools.jar?
But there is no such a file in jre-1.5.0_11 or previous versions.
The only place where the file with such name can be found is jdk\lib.
All attempts to run end up with:
? BUILD FAILED.
C:\<PETSTORE_HOME>\bp-project\command-line-ant-task.xml:77;unable to find javac compiler;com.sun.tools.javac.Main is not on the class path.
Perhaps JAVA_HOME does not point to JDK."
Directories C:\Sun\SDK\bin and C:\Sun\SDK\jdk are in the PATH.
JAVA_HOME as a System variable is set up to C:\Sun\SDK\jdk.
Building and running other applications like a BluePrints or Samples bring to same result.
I will post more information if needed.
Thank you in advance for help.If you are using Windows XP:
1. Right click on my computer
2. Select Properties from the popup dialog
3. Click on the "Advanced" tab
4. Click the button towards the bottom that says "Environment Variables"
5. In the dialog that pops up, look in both the User variables and the System variables for a variable named CLASSPATH
6. If its not there, you need to create it. If you want to make it available to all users of your computer, create it as a System variable. If you only want it to be available to the current user, add it as a User variable.
7. If it is there, or if you just created it, it needs to contain the following values: the current directory (symbolically abbreviated as a period: "."), any class libraries you want to be available to the java compiler (javac) or the java interpreter (java). By default, jre/lib and jre/lib/ext are searched for classes, so you don't need to include anything located in one of these folders on the classpath. -
JSPC Compiler gives FileNotFound Exception from command line
I have problem running jspc from command line
From the browser, the jsp pages compile fine.
I have tested this on NT 4.0 and on HP UX 10.0 with Weblogic Server
4.5.1 and SP 9.
The command I typed in as follows:
$java weblogic.jspc -d /opt/b2berp/jspclassfiles/ - docroot
/opt/b2berp/web -keepgenerated true -classpath
/opt/jdk/1.2.2/lib/classes.zip:/opt/weblogic/weblogicaux.jar:/opt/b2berp/lib
I get the following exception:
I checked the file is in PATH and I am also specifying the absolute path
and filename.
My document directory is /opt/b2berp/web/auctions/
All of my jsp pages are under /opt/b2berp/web
This is also my web folder.
Gives error unable to find file
(FileNotFoundException)
Does anyone know what is going on.
Rauf
Hi,
did you place setWLSEnv in your path ?
----Anilkumar kari -
Work from command line but did not work from JSP call
I have a test class that should perform Triple DES. When I run it from command line work ok, but when runs from JSP it give me an error:
Exception:
======================================
javax.crypto.IllegalBlockSizeException: Input length not multiple of 8 bytes
put 3 check points inside the code, and run it from command line and here is the result:
C:\Documents and Settings\salasadi\Desktop\DigitalMailer>java TDESStringEncrypto
r 123456781234567812345678 "CID=103&A
this is pass 3
this is pass 1
this is pass 2
here is the class:
import javax.crypto.*;
import javax.crypto.spec.*;
import java.security.*;
import java.io.*;
public class TDESStringEncryptor
static final int DATA_STRING_LENGTH = 64;
public static void main(String[] args)
try
TDESStringEncryptor enc = new TDESStringEncryptor();
String value = enc.Encrypt(args[0], args[1]);
System.err.println(value);
catch (Exception ex)
System.err.println(ex);
public String Encrypt(String inkey, String data)
throws Exception
// convert key to byte array and get it into a key object
byte[] rawkey = inkey.getBytes();
DESedeKeySpec keyspec = new DESedeKeySpec(rawkey);
SecretKeyFactory keyfactory = SecretKeyFactory.getInstance("DESede");
SecretKey key = keyfactory.generateSecret(keyspec);
Cipher cipher = Cipher.getInstance("DESede/ECB/NoPadding");
cipher.init(Cipher.ENCRYPT_MODE, key);
byte[] out = cipher.doFinal( padString(data).getBytes( ) );
System.out.println("this is pass 1");
return byteArrayToHexString( out );
private String byteArrayToHexString(byte in[])
byte ch = 0x00;
int i = 0;
if ( in == null || in.length <= 0 )
return null;
String pseudo[] = {"0", "1", "2", "3", "4", "5", "6", "7", "8",
"9", "A", "B", "C", "D", "E", "F"};
StringBuffer out = new StringBuffer( in.length * 2 );
while ( i < in.length )
ch = (byte) ( in[i] & 0xF0 );
ch = (byte) ( ch >>> 4 );
ch = (byte) ( ch & 0x0F );
out.append( pseudo[ (int) ch] );
ch = (byte) ( in[i] & 0x0F );
out.append( pseudo[ (int) ch] );
i++;
String rslt = new String( out );
System.out.println("this is pass 2");
return rslt;
private String padString( String s )
StringBuffer str = new StringBuffer( s );
int strLength = str.length();
for ( int i = 0; i <= DATA_STRING_LENGTH ; i ++ )
if ( i > strLength ) str.append( ' ' );
System.out.println("this is pass 3");
return str.toString();
And here is the JSP call:
TDESStringEncryptor encryptz = new TDESStringEncryptor();
String cryptodata1 = encryptz.Encrypt(Keyz,cryptodata);
ThanksPlease use [ code ] tags when posting code.
Please indicate the line that causes the exception.
Please indicate what Keyz and cryptodata is. -
Running Unit Test from test manager that run bat file from command line
Hi ,
I am trying to run Jsystem (java framewotk) from command line using runScenario.bat thru unit test that i associated to test in test manager.
the idea is that when i ran the automated test from MTM - it will run the the unit test that will run the appropriate test case in java.
i wrote the code like this :
using System;
using Microsoft.VisualStudio.TestTools.UnitTesting;
namespace UnitTestProject3
[TestClass]
public class UnitTest1
[TestMethod]
public void TestMethod1()
try
String command = "c:\\JSYSTEM\\runner\\runScenario.bat
c:\\Users\\ryeshua\\Source\\Workspaces\\Auto1\\my-tests-project\\target\\classes scenarios\\feature1 RoeySetup.xml ";
System.Diagnostics.ProcessStartInfo procStartInfo =
new System.Diagnostics.ProcessStartInfo("cmd", "/c " + command);
procStartInfo.RedirectStandardOutput = true;
procStartInfo.UseShellExecute = false;
//procStartInfo.CreateNoWindow = true;
System.Diagnostics.Process proc = new System.Diagnostics.Process();
proc.StartInfo = procStartInfo;
proc.Start();
string result = proc.StandardOutput.ReadToEnd();
Console.WriteLine(result);
catch (Exception objException)
// Log the exception
and when i ran it from visual studio it worked perfect. and update the Jsystem logs of the junit test in the jsystem/runner/log folder.
but when i added it to associated test and ran it from MTM - it pass but it does not update the logs in jsystem folder.
the problem that i dont know what is not working. i cant see the output of it when i ran from mtm but can see when i ran from VS.
i am using VS 2013 Pro with MTM 2013.
please advice
RoeyHi Roey,
Thank you for posting in MSDN forum.
Based on your issue, could you please tell me how you generate the log file under the jsystem folder?
Generally, I know that when we run unit test from VS IDE, the file will be saved into the local machine. But when we run unit test from MTM, the unit test method will be run on the test agent machine, so the file will be saved into the test agent machine.
Therefore, I suggest you could check if you did not see the updated logs file in jsystem folder on the test agent machine.
In addition, I suggest you could try to copy this unit test project on this test agent machine and then run the unit test method using mstest.exe in command line and then check if you can update the logs file.
https://msdn.microsoft.com/en-us/library/ms182489.aspx?f=255&MSPPError=-2147217396
If you have any updated message about this issue, please tell me.
Best Regards,
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey.
Maybe you are looking for
-
Is there a way to set wireless network priority on iphone? If not, there should be!
Is there a way to set wireless network priority on iphone? If not, there should be! I have a wireless router with dual band signals, as well as an extender at the other end of my home... it would be nice if I could set a priority list so my phone kno
-
hi all.. does anyone knows if this board supports intel's vt-x? msi p31 neo-f http://eu.msi.com/index.php?func=proddesc&maincat_no=1&prod_no=1286 how can i enable it? edited. updated the link above
-
Hi After upgrading to OS X Mavericks the Belkin HUB is unstabel makes the mac crash, the external display sometimes blinks lose mous connection and ethernett any tip
-
what should i do..i already purcahse item COD ghost like ripper and soap pack..i already downloaded it to my ps3 but its still not available in game..pls help..
-
Sommes keys are not workng on my Elite Book 2530p
sommes keys are not working on my Elite Book 2530p On the somme range 8 i k , are not working key fn also is not working propely