S.O.S PROBLEMS COMUNICANTING EXTERNAL PROCESSES IN JAVA UNDER LINUX

I've programmed a little program in C called "cinterpreter" which works like
an interpreter, when it launches it shows a welcome message to the display
(standart output), then is always waiting for strings from the keyboard
showing the length of the input strings until the "quit" string is received,
in that case the C program named "cinterpreter" finish, here we can see the
code:
# include <stdio.h>
# include <string.h>
# include <stdlib.h>
char presentacion[8][80] = {
" ||||||||||||||||||\n",
" --- Welcome to Maude ---\n",
" ||||||||||||||||||\n",
" Maude version 1.0.5 built: Apr 5 2000 15:56:52\n",
" Copyright 1997-2000 SRI International\n",
" Thu Aug 9 13:40:25 2001\n",
" \n",
" \n"};
void longitud(char * cadena)
int t;
for(t=0;t<3;t++)
printf("MAUDE_OUT> la cadena %s tiene %d caracteres\n",cadena,strlen(cadena));
fflush(stdout);
int main()
char cadena[80];
int i;
char ch;
for(i=0;i<8;++i) printf("%s",presentacion);
printf("\n");
fflush(stdout);
do {
printf("Press any key to continue\n");
scanf("%c",&ch);
printf("%c\n",ch);
fflush(stdout);
}while (ch != 'q');
printf("\n");
while( strcmp(cadena,"quit") !=0)
printf("\nMAUDEENTRADA>");
fflush(stdout);
scanf("%s",cadena);
longitud(cadena);
I'm intereted in running this program, control it's standart input and
starndart output through a java program through the Runtime , process class
and the correponding methods like "exec", getInputStream, getOutputStream,
getErrorStream, the question is that I do not Know what I'm doing wrongly but
I don't get what I want, I'm interested in sending input to the C subprocess
thorugh its stdin getting it by getoutputStream method, and then read its
answer from its stdout getting it by getoutputStream, then question is that I
can sent de first string and read the first answer but I can't repeat it
again, and I would like to begin a dialog with the subprocess so I need to
send many messages and receive its answer to it, but many times, not just one,
by the moment I got it but just one, if any body can help with this please
answer the question or send any answer to the next adresses
e-mail:
[email protected]
[email protected]
*************** java code **********************
import java.io.*;
public class mioss {
static String proceso = "/bin/cinterprete";
static Process p = null;
//--------- input writting method -----------
static void escribe(OutputStream procesoescribe, String s) {
BufferedWriter laentrada = new BufferedWriter(new
OutputStreamWriter(procesoescribe));
try{
laentrada.write(s + "\n");
laentrada.flush();
}catch(IOException e) {System.out.println("error de escritura");}
//----------- output reading method ---------------
static void leesalida(InputStream procesosalida){
String l;
BufferedReader lasalida = new BufferedReader(new
InputStreamReader(procesosalida));
try{
while ((l = lasalida.readLine()) != null){
System.out.println(l);
} catch(IOException e) {System.out.println("error de readline");}
//------------- reading error method --------------------
static void leerror(Process p){
String l;
BufferedReader elerror = new BufferedReader(new
InputStreamReader(p.getErrorStream()));
try{
while ((l = elerror.readLine()) != null){
System.out.println(l);
elerror.close();
} catch(IOException e) {System.out.println("error de readline");}
//--------------- principal method main -------------------------
static Process proc = null;
public static void main(String [] Args) {
try{
Runtime r = Runtime.getRuntime();
proc = r.exec(proceso);
escribe(proc.getOutputStream(),"map(+2)[3,3]");
leesalida(proc.getInputStream());
escribe (proc.getOutputStream(),"map(*3)[2,2]");
leesalida(proc.getInputStream());
}catch(Exception e) {System.out.println("error de ejecucion del
proceso");}
System.out.println("THE END OF THE PROGRAM");

The problem is with the leesalida method.
There you are reading form the output sream of the process usingBufferedReader.readLine.
readLine returns null only when it gets to the end of the stream, or here the stream ends only when the external processes ends.
You can modify your code like this:
public class mioss {
    static String proceso = "cinterprete";
    static Process p = null;
    //--------- input writting method -----------
    static void escribe(OutputStream procesoescribe, String s) {
     BufferedWriter laentrada = new BufferedWriter(new
         OutputStreamWriter(procesoescribe));
     try{
         laentrada.write(s + "\n");
         laentrada.flush();
     }catch(IOException e) {System.out.println("error de escritura:" + e);}
    //----------- output reading method ---------------
    static void leesalida(InputStream procesosalida, int nLines){
     String l;
     BufferedReader lasalida = new BufferedReader(new
         InputStreamReader(procesosalida));
     try{
         while(nLines-- > 0) {
          l = lasalida.readLine();
                System.out.println("from java:\t" + l);
     } catch(IOException e) {System.out.println("error de readline");}
    //------------- reading error method --------------------
    static void leerror(Process p){
     String l;
     BufferedReader elerror = new BufferedReader(new
         InputStreamReader(p.getErrorStream()));
     try{
         while ((l = elerror.readLine()) != null){
                System.out.println(l);
         elerror.close();
     } catch(IOException e) {System.out.println("error de readline");}
    //--------------- principal method main -------------------------
    static Process proc = null;
    public static void main(String [] Args) {
     try{
         Runtime r = Runtime.getRuntime();
         proc = r.exec(proceso);
         leesalida(proc.getInputStream(), 9);
         escribe(proc.getOutputStream(),"first");
         leesalida(proc.getInputStream(), 4);
         System.out.println("Done first !\n");
         escribe (proc.getOutputStream(),"second");
         leesalida(proc.getInputStream(), 4);
         System.out.println("Done second !\n");
     }catch(Exception e) {System.out.println("error de ejecucion del proceso");}
     System.out.println("THE END OF THE PROGRAM");
} Regards,
Iulian

Similar Messages

  • S.O.S PROBLEMS COMUNICATING EXTERNAL PROCESES IN JAVA UNDER LINUX

    I've programmed a little program in C called "cinterpreter" which works like
    an interpreter, when it launches it shows a welcome message to the display
    (standart output), then is always waiting for strings from the keyboard
    showing the length of the input strings until the "quit" string is received,
    in that case the C program named "cinterpreter" finish, here we can see the
    code:
    # include <stdio.h>
    # include <string.h>
    # include <stdlib.h>
    char presentacion[8][80] = {
    " ||||||||||||||||||\n",
    " --- Welcome to Maude ---\n",
    " ||||||||||||||||||\n",
    " Maude version 1.0.5 built: Apr 5 2000 15:56:52\n",
    " Copyright 1997-2000 SRI International\n",
    " Thu Aug 9 13:40:25 2001\n",
    " \n",
    " \n"};
    void longitud(char * cadena)
    int t;
    for(t=0;t<3;t++)
    printf("MAUDE_OUT> la cadena %s tiene %d caracteres\n",cadena,strlen(cadena));
    fflush(stdout);
    int main()
    char cadena[80];
    int i;
    char ch;
    for(i=0;i<8;++i) printf("%s",presentacion);
    printf("\n");
    fflush(stdout);
    do {
    printf("Press any key to continue\n");
    scanf("%c",&ch);
    printf("%c\n",ch);
    fflush(stdout);
    }while (ch != 'q');
    printf("\n");
    while( strcmp(cadena,"quit") !=0)
    printf("\nMAUDEENTRADA>");
    fflush(stdout);
    scanf("%s",cadena);
    longitud(cadena);
    I'm intereted in running this program, control it's standart input and
    starndart output through a java program through the Runtime , process class
    and the correponding methods like "exec", getInputStream, getOutputStream,
    getErrorStream, the question is that I do not Know what I'm doing wrongly but
    I don't get what I want, I'm interested in sending input to the C subprocess
    thorugh its stdin getting it by getoutputStream method, and then read its
    answer from its stdout getting it by getoutputStream, then question is that I
    can sent de first string and read the first answer but I can't repeat it
    again, and I would like to begin a dialog with the subprocess so I need to
    send many messages and receive its answer to it, but many times, not just one,
    by the moment I got it but just one, it's very important that it's necesary to
    to interact with the subprocess like:
    1) send first string and then read the answer of the subprocess
    2) send the second string and then read the answer
    these steps must be done all the times I want, but I just can send the first
    string and read the first answer but no more steps work well, if any body can
    help with this please
    answer the question or send any answer to the next adresses
    e-mail:
    [email protected]
    [email protected]
    *************** java code **********************
    import java.io.*;
    public class mioss {
    static String proceso = "/bin/cinterprete";
    static Process p = null;
    //--------- input writting method -----------
    static void escribe(OutputStream procesoescribe, String s) {
    BufferedWriter laentrada = new BufferedWriter(new
    OutputStreamWriter(procesoescribe));
    try{
    laentrada.write(s + "\n");
    laentrada.flush();
    }catch(IOException e) {System.out.println("error de escritura");}
    //----------- output reading method ---------------
    static void leesalida(InputStream procesosalida){
    String l;
    BufferedReader lasalida = new BufferedReader(new
    InputStreamReader(procesosalida));
    try{
    while ((l = lasalida.readLine()) != null){
    System.out.println(l);
    } catch(IOException e) {System.out.println("error de readline");}
    //------------- reading error method --------------------
    static void leerror(Process p){
    String l;
    BufferedReader elerror = new BufferedReader(new
    InputStreamReader(p.getErrorStream()));
    try{
    while ((l = elerror.readLine()) != null){
    System.out.println(l);
    elerror.close();
    } catch(IOException e) {System.out.println("error de readline");}
    //--------------- principal method main -------------------------
    static Process proc = null;
    public static void main(String [] Args) {
    try{
    Runtime r = Runtime.getRuntime();
    proc = r.exec(proceso);
    escribe(proc.getOutputStream(),"map(+2)[3,3]");
    leesalida(proc.getInputStream());
    escribe (proc.getOutputStream(),"map(*3)[2,2]");
    leesalida(proc.getInputStream());
    }catch(Exception e) {System.out.println("error de ejecucion del
    proceso");}
    System.out.println("THE END OF THE PROGRAM");

    Just a guess, but I think your problem is at least partly due to repeated getting the Input and Output Streams of the process and repeatedly wrapping them in Readers and Writers. Get the InputStream once and wrap it in a Reader once and use that Reader. Also get the OutputStream once and wrap it in a Writer once and use that Writer.

  • Problem in external process using process flow

    Hi All,
    I want to execute a batch file ( which is appending 2 text files ) using OWB process flow.
    For this i am using external process in OWB process flow and giving the parameters for external process as below:
    COMMAND --- VALUE as c:\winnt\system32\cmd.exe
    PARAMETERS_LIST --- VALUE as ?c:\\fileappend.bat
    when i execute the process flow....it is showing
    Completion Status Completed successfully
    Starting Execution BATCH_PROC
    Starting Task BATCH_PROC
    Starting Task BATCH_PROC:EXTERNALPROCESS
    Microsoft Windows 2000 [Version 5.00.2195]
    (C) Copyright 1985-2000 Microsoft Corp.
    C:\owb\owb\bin\win32&gt;
    C:\owb\owb\bin\win32&gt;
    WARNING: Log file truncated - see RAB for further information.
    Completing Task BATCH_PROC:EXTERNALPROCESS
    Completing Task BATCH_PROC
    Completing Execution BATCH_PROC
    But i couldn't see the result, means the files appended.
    It is working when i execute the batch file through MS-DOS.
    Please let me know is there any other necessary steps i need to take.
    Thanks in advance
    Malli

    Hi Malli,
    Because you are using an external process you do not need to specify the cmd command to perform the execution. You can just put the call to the batch file you have in the command string and that is it. Beware that the working directory is <owb home>\owb\bin\win32.
    Mark.

  • 320 GB External Drive (PX1267E-1GB32) under Linux

    Hi,
    I just bought a Toshiba 320 GB External Drive (PX1267E-1GB32) and I need it to work under Linux.
    Linux recognizes the drive as a SDA but give an I/O error with an Unable to read partition table.
    Any idea what is the problem? Can I use this Drive under linux?
    Carlos.

    @Gipsyman
    Sorry, but he could be right imho.
    This disk mounts a cd-drive with the security software on it. This could be the reason why other operating systems could have difficulties recognizing it. A solution to the problem could be deleting the whole partition, which you mentioned, but you cannot use Disk Management for this issue. Because of the fact that the disk has one partition containing two partitions (CD-drive and FAT32 disk), one has to delete this partition as a whole. I haven't yet figured out how to delete this partition (which is tagged as 'BAD' by Partition Magic 8). I tried to format it to NTFS, but that doesn't work either.

  • Pocket PC -Problem executing external program from java

    Hi,
    I'm developing an application on Dell Axim x51 PDA. I am using mysaifu jvm. The application needs to execute an external program (.exe) for which I'm using the Runtime class.
    I get java.io.IOException: The system cannot find the file specified.
    I have verified that the file exists. ( i used File class to check if the file exists)
    here's the part of code :
    Runtime rt = Runtime.getRuntime ();      
    File sktScan = new File("\\My Documents\\RFID\\ScktScan.exe");
    if(sktScan.exists())
    System.out.println("FILE EXISTS");
    String command = sktScan.getAbsolutePath();
    process = rt.exec (command);
    System.out.println("Socket Scan Path is : "+command);

    You have acces to "java.lang.Runtime currentRuntime.exec()" method ? in my case NetBeans IDE dont give me for my compilation with :
              microedition.configuration     CLDC-1.1     
              microedition.profiles     MIDP-2.0

  • Problems running external programs from java

    Hello.
    I wrote a pair of perl scripts and a GUI in java to run them. The first perl script just read the files in one directory makes some changes to the names of the files and then group all this files in a set of new directories. The other perl scripts takes all this new files and calls BLAST sequence alignment program and perform some alignments among these sequences. I tested this scripts and they work fine.
    The problem comes when I try to run them for the JAVA GUI. I use RunTime and when I need to run the first perl script it all works well, but when The call to the second perl script is made the program fisishes without doing anything at all. I found out that the problem is that when running the script from the Java GUI it's not able to find BLAST program. So I guess that Java is not really starting a terminal session and it doesn't read my bash_profile to find out the path to my programs.
    So, my question is if anyone knows a method to tell Java to load all this paths in the bash_proflie file so all of my scripts work???.
    I have no idea is this can be done and how so any advice would be really wellcome.
    By the way, my java version is 1.4.2 and my OS is Mac OS X 10.3
    Thanks a lot , Julio

    Invoke /bin/sh -c and give it your program's full path with.
    (To understand what I've written, maybe reading
    http://www.javaworld.com/javaworld/jw-12-2000/jw-1229-traps_p.html
    http://mindprod.com/jgloss/exec.html
    and
    http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Runtime.html
    (especially the exec(String[] cmdarray) method)
    might help)
    -T-

  • Problem running jar files of java in Linux

    I cannot run jar files in java/jdk1.3.1_01/demo in Readhat Linux 6.2
    The command is :--
    [root@localhost Notepad]# java -jar Notepad.jar
    java.lang.NoClassDefFoundError: javax/swing/JPanel
    at java.lang.Class.forName(Class.java:33)
    at kaffe.jar.ExecJarName.main(ExecJarName.java:58)
    at kaffe.jar.ExecJar.main(ExecJar.java:61)
    [root@localhost Notepad]#
    My ~/profile setting is :---
    PATH="$PATH:/usr/X11R6/bin:/usr/java/jdk1.3.1_01/bin:/usr/java/jdk1.3.1_01/jre/bin:/usr/java/jre/lib"
    export JAVA_HOME=/usr/java/jdk1.3.1_01
    export NPX_PLUGIN_PATH=/usr/java/jdk1.3.1_01/jre/plugin/i386/ns4

    [root@localhost Notepad]# java -jar Notepad.jar
    java.lang.NoClassDefFoundError: javax/swing/JPanel
    at java.lang.Class.forName(Class.java:33)
    at
    at
    at kaffe.jar.ExecJarName.main(ExecJarName.java:58)
    at kaffe.jar.ExecJar.main(ExecJar.java:61)
    [root@localhost Notepad]#
    My ~/profile setting is :---
    PATH="$PATH:/usr/X11R6/bin:/usr/java/jdk1.3.1_01/bin:/u
    r/java/jdk1.3.1_01/jre/bin:/usr/java/jre/lib"
    export JAVA_HOME=/usr/java/jdk1.3.1_01
    export
    NPX_PLUGIN_PATH=/usr/java/jdk1.3.1_01/jre/plugin/i386/n
    4Add the line:
    export CLASSPATH=.:$JAVA_HOME/jre/lib/rt.jar
    Then, run the command "source ~/.profile" and then the jar file should be able to run.
    Bhav

  • External Processing with material Provided to Vendor

    Dear All,
    I have a problem in external processing of Maintenance Order.
    When i have created external processing operation.
    I have assigned one component for that external operation which i have to send to vendor.
    After saving the Maintenance order, system is generating Purchase Requisition for that operation.
    That purchase requisition is having account assignment category F. But it is not picking the item category L and the component assigned for this external operation is not flowing to the purchase requisition.
    Please guide me to solve this issue.
    Thanks & Regards
    Bala

    Hi
    For external service we can use PM03, for that we have to create service sheet and proceed further.
    But here my requirement is, just like PP external processing they are doing one operation outside.
    If you look at PP routing, Operation overview there is given external processing data and there will be subcontracting tick.
    If we tick the sub-contracting button, then system will pick the component assigned to that operation to the Purchase requisition.
    If we don't tick that button, system will not copy the component to PReq. .
    Is there any option available here in PM?
    Please guide me.
    Thanks & Regards
    Bala

  • External process destroy on Windows XP

    Hello friends.
    I have a small program that launches external process (another java program), reads and processes process output until the process is destroyed (terminates). The program works fine on Windows 2000 - when external java program launched as separate Process terminates, an inputStream.readLine() call throws exception, and my program can continue. However on XP when external process terminates, it is not unloaded from memory, and inputStream.readLine() blocks forever...
    I run under lates JVM 1.4... Any ideas why? Has anyone encountered this problem before?
    try {                          
       Process p=Runtime.getRuntime().exec("java SomeProgram");
       in=new BufferedReader(new InputStreamReader(p.getInputStream()));
       while ((s=in.readLine())!=null) { // blocks on XP, works on Win2000
          // Process input
    } catch(IOException ioe) {
    } catch (Exception e) {
    }Any help appreciated.

    I have a similar problem with a small Java program running on Linux, so it may not be OS specific. The code is similar to yours, except that the file being read is produced by a third party. The third party claims to produce a new file every 5 minutes, and it takes about 30 seconds for them to produce the file.
    The program is supposed to run indefinitely -- it reads the file, then sleeps for 5 minutes, then reads the file again.
    Every so often, (like once every 24-36 hours), the program hangs indefinitely at the readLine() call.
    What's driving me crazy is that I've used the exact same idiom in numerous other circumstances and I've never encountered this problem.
    At first I thought that perhaps the file was being changed while my program was reading it. But under those circumstances I would have thought I'd get some kind of IOException, and I don't.
    I'm going to explore using the ready() method of BufferedReader... but I'm not sure if that will solve the problem.
    I'd also be very greatful for any input on this matter!
    - Dean

  • Interact with extern process by Runtime.exec()

    Hi,
    I want interact with a extern process by Runtime.exec(), but I don't Know the way for introduce the params required for the extern process.
    So, Is posible, interact with the extern process from Java?
    Thanks

    Exactly, I would like to know how exec can pass a PIN
    number when the proccess already has been launched. Sounds like you're doing it through the process' stdin. Read that article I linked.
    You'll have to call Process.getOutputStream() or whatever that method is. To you it's an OutputStream, to the process, it's input. You'll write the stuff to that stream that you'd type to the command line. If you want to get that from the user interactively, you'll do it like you would any interactive user input in any Java program--get it by reading System.in or from some GUI element, and then take that and write it to the process' stream.
    If you're not familiar with I/O in Java, look here:
    http://java.sun.com/docs/books/tutorial/essential/io/index.html

  • Confirmation of external processing operation

    Dear All,
    I would like to know is it possible to prevent the confirmation of an external processing operation (pp02 control key) until the Purchase Order associated with that operation is received (GR) ?
    I checked the forum for this, but was unable to find any inputs & also in customizing where i find only settings for confirmation of orders & not at operation level.
    Hope my problem is clear, await inputs.
    Regards,
    Vivek

    Yes,
    it can be done but no through std SAP setting...but with user exit.
    Check this exit
    CONFPP03  PP order conf.: Cust. specific check after op. selection
    CONFPP04  PP order conf.: Customer specific input checks       
    CONFPP05  PP order conf.: Customer specific enhancements.

  • How to pass BindVariables to External Process (Workflow)

    I build a shell script (unix) which accepts a command line parameter .... a "filename"
    The "filename" is a dynamic name!
    The workflow is build with a custom input parameter "filename" ... which I want to pass to an external process, which calls this shell script:
    How can I do that ?
    ExtProcess:
    Command : Val=/bin/ksh
    Parameter_List : Val=":/home/bin/myscript.sh:${Task.Input}:"
    (Binding ":Filename" replaces the whole value, sorry)
    Succes_Threshold: Val=0
    Script : Val="" , Binding=":Filename"
    ... does not pass the value of ":Filename"
    Script : Val="/tmp/fixed.name"
    ... works only with fixed names
    what I really need is something simple like:
    Parameter_list : Val=":/home/bin/myscript.sh:${Parameter.Filename}:FIXPARAM:"
    or Script : Val=":${Parameter.Filename}:${Parameter.Param2}:${Parameter.Pram3}"
    ... similar problem I had with FTP, I found no way to pass dynamic filenames or other parameters (except LOCATION Parameters)
    ... similar problem I had with EMAIL I found no way to include PARAMETERS to the mail body (except to replace the whole body by 1 parameter)
    Is there a solution or is in current version OWB 9.2 only "static" parameters supported.
    I also was missing to pass OUTPUT-parameters for example of a TRANSFORMation,
    I also was missing some urgent SYSTEM-parameters for self identification of the process(like "SYSTEM.TASK_NAME" "SYSTEM.EXECUTION_AUDIT_ID" "SYSTEM.ITEM_KEY" )
    Thanks for all hints and best regards
    Martin

    Actually... After further investigation this may not be needed. I'd be interested in the answer, to understand what is possible.
    The concept of passing parameters in the OWB workflow designer is rather limited, in my humble opinion. Sure, you can designate a "start" sequence that takes a parameter and you can pass that to mappings/transformations but there is no chance for feedback. Ie, if I manually (or through some rigged script) execute the flow with the "PARAMETER" then it will be able to bind. What about mid-flow. IE, select the record to be "processed", then call a "flow" with that as a parameter.
    Am I mistaken? Is there a way to expose the "out" parameters of a mapping, or the return of a "transformation function" as "OUTS" in the process flow.
    Of course, in a world where everything is OWB and in the DB one can leave data in tables, and pick it up on the other mappings. HOWEVER, most BI systems involve external retrievals, etc. that need a bit more "intelligence" then "run and return 1,2,3" . :)
    Hope this is helpful for product feedback. If I'm mistaken on the WF capabilities please clue me in. :)
    btw, I'm an OWB fan, certainly. The progress over the past two years has been excellent.

  • Problem with external punchout in SRM Server 713

    Hello,
    We upgrade from SRM_SERVER 701 SP 04 to SRM_SERVER 713 SP 02, now we have a problem with external catalog, we did not change anything in standard call structure, however now when the user access to external catalog, select a product and "checkout", SRM returns to shopping cart screen without products and no message are register in log in transaction code SLG1.
    Our parameters in structure are:
    10                     https://xxxxxxxxx                          URL
    20 VIEW_ID          NAME                            Fixed value
    30 VIEW_PASSWD     XXXXXX               Fixed value
    40 USER_ID          SY-UNAME                   SAP field
    50 BRANDING      search5                     Fixed value
    60 LANGUAGE      ES                           Fixed value
    70 COUNTRY      MX                             Fixed value
    75 EASYORDER 1                          Fixed value
    80 target _top                                  Fixed value
    85 ~caller      CTLG                              Fixed value
    90 OCI_VERSION     4.0                     Fixed value
    91 FILTER                                      Fixed value
    92 OPI_VERSION 1.0                     Fixed value
    100 HOOK_URL                             return URL
    110 returntarget      _top                       Fixed value
    we made some test with parameter BYPASS_INB_HANDLER, set as 'X' but this not solve our issue.
    We have an implementation in badi BBP_CATALOG_TRANSFER to map product category, even if I set an external breakpoint in this implementation, system does not pass through it, also we test with this implementation inactive and behavior is the same, nothing transfer to shopping cart
    Does anyone know what's missing?
    Thanks in advance.
    Best regards,
    José Luis D.

    Hello Jason,
    Thank you for your answer, but as I told, If I set an external breakpoint it does not stop for debugging, so I can't see table as you recomended. This process (debugging) is familiar to me, in last version I can do it.
    Any suggestion?
    Thanks in advance, best regards
    José Luis D

  • Can SAP get material number in Purchase order in external processing?

    I have a question that:
    As I know, Exeternal processing is a service, so that Material number can not be shown in purchase order converted from PR for external processing. Here, PR can be automately generated from transaction CO01 to create an external processing production order. Meanwhile, for external processing, purchase info record is created without material number only with material group.
    So, I want to know that if there any solutions to show material number in purchase order generated for external processing?
    thanks,
    best regards,

    If therer are no production order, How can I get finished products from internal activity and external processing?
    Now, external processing in our company like this:
    1.create an purchase info record. (type:subcontracting, with material group, but not material ID)
    2.Maintan external processing data in external operation where external processing happens.(control key: pp02, external processing data: info record, purchase org. net price, cost element etc.)
    3.create a production order for the material.(one of the operations is an external processing operation described like step 2)
    4.Purchase requstion is changed into Purchase order. (Purchase requestion is automately created with the production order)
    5.MIGO to receive goods from the purchase order.
    6.finished the production order and delivery goods.then the production order is DLV.
    In step 4, purchase order can only get the production order ID, but there are no material ID shown in it. Only method to show material is that maintaining a description text in the external operation, then, purchase order item could show material in material text(but, here, there is no material ID derectly from info record or production order).
    this is the big problem now for our company. No material ID can be automately carried into the purchase order.
    Hope you help..
    thanks...

  • Substitute variables for external process activity in process flows

    Has anyone used with success substitute variables such as ${Working.Rootpath} for external process activity?
    I can't get it working. Variables aren't substituted and my scripts fail.
    Sample value for parameter_list parameter for external process I use is:
    |${Working.Rootpath}|
    and in the script I get:
    ${Working.Rootpath}
    which is of course not what I expected.

    In documentation is Working.Rootpath so there is a bug in documentation. It is ugly because it's hard to guess.
    Thank's for your reply Michael. I checked all that you described. Previously I had Working location set to "Use default location". When I changed it to actual location substitute variables started to work properly.
    If I correctly understand "Use default location" means: use location associated with process module. And for execution it works but for substitute variables doesn't. So I think it is a bug.
    Next thing is variables in the script itself. From examples sent by Mark (script: cd ${Working.RootPath}...) they should be set in environment and accessible to shell. This doesn't work for me but it is not described in documentation and can be easily achieved by passing parameters. So that's not a problem.
    One more question: Should I open tars and file bugs describing what we found?

Maybe you are looking for

  • Can i put a bigger hard drive in my intel imac?

    Hi, Is it possible to replace the internal hard drive in my 17" imac Intel core duo for a larger capacity drive? I did this on the first gen G5 imac ok but i'm not sure about the intel model, i was thinking of a 250gb or something. What type of drive

  • HMRC tools won't work on my iMac but will load on another iMac of same spec.

    HMRC PAYE Tools stoped working so I did a full install and re load of this software but when opened it opens a box that says it's creating history tables and just hangs there. I've tried in stalling the same download on an identical iMac and it works

  • TomaHawk dataList tag and javaScipt

    Hi, Does anyone have a sample javaScript function to access an inputText field inside a dataList tag? Thanks.

  • I tried to install the new iTunes & I get an error message

    I tried to install the new iTunes & i got an error message & i have already deleted all apple related things & reinstalled them. Now a message that says something about verify my apple mobile device keeps coming up & i have no idea how to fix this pr

  • Latest and finish start dates.

    Dear all, 1.What is actually meant by latest and finish start dates? 2.In my maintenance order, when i am using my workcenter against each operations, the earliest start date, earliest end date, earliest start time, and its finish time is calculating