Tokenizer - getting the third node from this format (800,PA,PAC,Package)

Hi Folks,
I am trying to get the third node from the following format: 800,PA,PAC,Package
The correct output is PAC.
Your help is very much appreciated!
Just to add the code that I have is as follows:
Import com.sap.mw.jco.*;
//write your code here
String DBTABLE = a;
String WHERE_CLAUSE = b+" = "+"'"c"'" ;
//...some code in here...
// Create function
JCO.Function function = null;
IFunctionTemplate ft = mRepository.getFunctionTemplate("RFC_READ_TABLE");
function = ft.getFunction();
// Obtain parameter list for function
JCO.ParameterList input = function.getImportParameterList();
// Pass function parameters
input.setValue( DBTABLE, "QUERY_TABLE");
input.setValue( "," , "DELIMITER");
//Fill the where clause of the table
JCO.ParameterList tabInput = function.getTableParameterList();
JCO.Table inputTable = tabInput.getTable("OPTIONS");
inputTable.appendRow();
inputTable.setValue(WHERE_CLAUSE,"TEXT");
mConnection.execute( function );
//This is the part where the output is generated
JCO.Table valueSet = function.getTableParameterList().getTable("DATA");
String resultSet = valueSet.getString("WA"); //WA contains 800,PA,PAC,Package
mConnection.disconnect();
return resultSet;

Hi Morgalr,
Thank your for the tip.
I am not sure if there is a better way to do the coding. But what what I have come up is the following:
JCO.Table valueSet = function.getTableParameterList().getTable("DATA");
String resultSet []= valueSet.getString("WA").split("(double \ in here),");
mConnection.disconnect();
return resultSet[2];
Let me know if this works with you.
regards,
Lex

Similar Messages

  • How can I get the XML structure from a flat structure?

    Hi all,
    in my XI SP 12 I use a JMS adapter to read information using the WebSphereMQ transport protocol.
    The structure that I receive have this format:
    <Name_A.KeyFieldValue><Name_A.fieldName_A1_Value>...<Name_A.fieldName_AN_Value>
    <NumberRecordType_B><NumberRecordType_c>
    <Name_B.KeyFieldValue><Name_B.fieldName_B1_Value>...<Name_B.fieldName_BN_Value>
    <Name_B.KeyFieldValue><Name_B.fieldName_B1_Value>...<Name_B.fieldName_BN_Value>
    <Name_C.KeyFieldValue><Name_C.fieldName_C1_Value>...<Name_C.fieldName_CN_Value>
    <Name_C.KeyFieldValue><Name_C.fieldName_C1_Value>...<Name_C.fieldName_CN_Value>
    the problem is that in this structure each line is not separated by a carriage return or a comma, I have all the information in a single line:
    <Name_A.KeyFieldValue><Name_A.fieldName_A1_Value>...<Name_A.fieldName_AN_Value><NumberRecordType_B><NumberRecordType_c><Name_B.KeyFieldValue><Name_B.fieldName_B1_Value>...<Name_B.fieldName_BN_Value>...<Name_B.KeyFieldValue><Name_B.fieldName_B1_Value>...<Name_B.fieldName_BN_Value><Name_C.KeyFieldValue><Name_C.fieldName_C1_Value>...<Name_C.fieldName_CN_Value>...<Name_C.KeyFieldValue><Name_C.fieldName_C1_Value>...<Name_C.fieldName_CN_Value>
    and the customer don't want to insert a line separator.
    Then, the question is:
    How can I get the XML structure from this structure?
    If possible, I don't want to develop new Module and add it in the JMS Module Sequence.
    PS I have already read the article "How to Use the Content Conversion Module with the XI 3 J2EE JMS Adapter.pdf" and it doesn't seem to help me.
    Best Regards,
    Paolo

    To get context parameters from your web.xml file you can simply get the ActionServlet object from an implementing action object class. In the perform (or execute) method make the following call.
    ServletContext context = getServlet().getServletContext();
    String tempContextVar =
    context.getInitParameter("<your context param >");

  • How can I get the example fonts from the font file Programmatically?

    Hi Friends,
             I am doing one mac application for the fonts management. Now I would like to Preview the Font in the NSTextView.  This is my coding for the textView.
        NSTextView *text3=[[NSTextView alloc]initWithFrame:NSMakeRect(250,500,450,30)];
        [text3 setString:@"ABCDEFGHIJKLMNOPQRSTUVWXYZ"];
        [text3 setFont:[NSFont fontWithName:@"GangofThree" size:40]];
        [[[self window] contentView] addSubview:text3];
    Because I have set the string in English for the NSTextView I can't able to view the other languages characters.I got the character set of the font file by using this code.
       NSCharacterSet *characterset = (NSCharacterSet *) CTFontCopyCharacterSet (fontRef);
    This Font is greek font.Now My question is how can I able to get the greek characters from this characterset.

    Your text string would certainly have to be in Greek itself, not Latin.  No normal font just translates Latin letters to Greek, they use other codepoints reserved for Greek letters.

  • Not able to get the Qualification data from BAPI

    Hi all,
    I am using a BAPI (BAPI_JOBREQUIRE_GETLIST) to get the qualifiaction data for requirement profile. It's working fine earlier but I did not get the qualification data from this BAPI, although the data is there in DB against this requirement profile.
    Can someone suggest me why I am getting this issue. I have looked into SDN and in BAPI documentation and found as below:
    "You require authorization (structural authorization) to read the Requirements subprofile."
    I am having the same User ID as I had before (when I getting back the correct data), so I don't think it should be authorization issue.
    Can someone help me out in this issue please.
    Thanks,
    Sanket Sethi

    Hi Shiva,
    It does not going to these includes at all. Message comes out with successfully done. The BApi is calling RHPP_COMMON_QUALI_READ inside, but this will not return any data. But if will call any qualification object ID, this BAPI will come up with data.
    So the QP type LO profile will not come up with any kind of data, but if we pass the OTYPE as Q and pass any Qualification object ID then the data will be returned.
    Is there any relationship or some other thing is missing? Any idea.
    Thanks,
    Sanket Sethi

  • How to get the leaf node in a hierachy????

    if i get a record that a parent node in a hierachy table ,so how can i get the leaf node of this parent node quicklly?????thank you!

    Hi xuhuanjun ,
    Refer to the below threads which disucss the same.
    Re: how to ensure a hierarchy tree's node is a internal leaf???????
    Re: Retrieve Hierarchy Leaf Node using API.
    Hope it helps.
    Thanks,
    Minaz

  • I Have Iphone 4... I had purchased from any store in second hand... and the third party whose this iphone not in contact with me and my phone goes to lose mode.. how can I activate my iphone

    I Have Iphone 4...
    I had purchased from any store in second hand...
    and the third party whose this iphone not in contact with me and my iphone in lose mode..
    how can I activate my iphone?????Plz help me...
    <Email Edited By Host>

    Digant Mevada wrote:
    can possible to contact apple server manager tu know my id or anythig do..??
    There is nothing you can do except return iPhone & get your money back.
    You will not be able to use the iPhone.
    Apple will not help you.
    -> Find My iPhone Activation Lock: Removing a device from a previous owner’s account

  • I cleared a conversation in messages. I did not delete.  How can I get it all the messages back from this sender.

    I cleared a conversation in my messages. I do not delete. How do I get all the messages back from this sender?

    Clearing a conversation is the same as deleting the messages, so unfortunately they're gone. You could always restore from a previous backup, but you would lose anything that you've added/changed etc on your phone between the last time you synced your phone and now.

  • When upgrading from osx 10.7.4 to osx mountain lion I get the following Alert!  This update requires OS X version 10.8.

    When upgrading from osx 10.7.4 to osx mountain lion I get the following Alert!  This update requires OS X version 10.8.

    Sounds like you downloaded the 10.8.1 update instead of the Mountain Lion installer from the Mac App Store.
    You have to purchase Mountain Lion from the App Store to get to 10.8

  • I have just bought a Panasonic Lumix compact camera. Aperture and Preview can't open the RAW files from this camera. Panasonic recommend downloading 'SYLKPIX Developer Studio SE' to save RAW file formats.How can Aperture and Preview read the files?

    I have just bought a Panasonic Lumix compact camera. Aperture and Preview can't open the RAW files from this camera. Panasonic recommend downloading 'SYLKPIX Developer Studio SE' to save RAW file formats.How can Aperture and Preview read the files?

    Either use 'SYLKPIX Developer Studio SE' to develope the RAW files and to save them in another lossless format like TIFF, or try if Adobe's free DNG Coverter can convert your Lumix RAW files to dng. Then import the dngs. This way, your files will still be RAW files.  This works (most times) for my Lumix FZ28.
    Adobe DNG Converter 8.3  http://www.adobe.com/support/downloads/detail.jsp?ftpID=5695

  • I have several times tried to stop following a thread in the PDF's forum about security issues and i still keep getting flooded with emails from this thread. I used the action within the thread that says stop following but appears to have no effect I stil

    I have several times tried to stop following a thread in the PDF's forum about security issues and i still keep getting flooded with  emails from this thread. I used the action within the thread that says stop following but appears to have no effect I still keep  getting from 5 to 20 emails daily. Please help!!!!!!!

    This may be helpful: How do I disable email notifications?

  • How do I get my money refunded?  I am not getting what I want from this, cannot email anyone for help, cannot get someone on the phone I can understand, and keep getting disconnected.  I just want my money back.

    How do I get my money refunded?  I am not getting what I want from this, cannot email anyone for help, cannot get someone on the phone I can understand, and keep getting disconnected.  I just want my money back.

    "this" being what?  You posted in the Workspaces.acrobat.com forum, which is a free service.
    If you subscribed to any of the paid services see Cancel your membership or subscription | Acrobat.com online services

  • HT201269 i don't know where to tell the iphone that it should look onto the icloud and get the back up from my old device.  This page says I will be prompted but I have not been.  Where should I look?

    i don't know where to tell the iphone that it should look onto the icloud and get the back up from my old device.  This page says I will be prompted but I have not been.  Where should I look?

    Settins > General > Reset and then Erase all content and settings. Then during setup assistant click restore from icloud backup

  • How can I get the "text" field from the actionEvent.getSource() ?

    I have some sample code:
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import java.util.ArrayList;
    public class JFrameTester{
         public static void main( String[] args ) {
              JFrame f = new JFrame("JFrame");
              f.setSize( 500, 500 );
              ArrayList < JButton > buttonsArr = new ArrayList < JButton > ();
              buttonsArr.add( new JButton( "first" ) );
              buttonsArr.add( new JButton( "second" ) );
              buttonsArr.add( new JButton( "third" ) );
              MyListener myListener = new MyListener();
              ( (JButton) buttonsArr.get( 0 ) ).addActionListener( myListener );
              ( (JButton) buttonsArr.get( 1 ) ).addActionListener( myListener );
              ( (JButton) buttonsArr.get( 2 ) ).addActionListener( myListener );
              JPanel panel = new JPanel();
              panel.add( buttonsArr.get( 0 ) );
              panel.add( buttonsArr.get( 1 ) );
              panel.add( buttonsArr.get( 2 ) );
              f.getContentPane().add( BorderLayout.CENTER, panel );
              f.setDefaultCloseOperation( JFrame.EXIT_ON_CLOSE );
              f.setVisible( true );
         public static class MyListener  implements ActionListener{
              public MyListener() {}
              public void actionPerformed( ActionEvent e ) {
                   System.out.println( "hi!! " + e.getSource() );
                   // I need to know a title of the button (which was clicked)...
    }The output of the code is something like this:
    hi! javax.swing.JButton[,140,5,60x25,alignmentX=0.0,alignmentY=0.5,
    border=javax.swing.plaf.BorderUIResource$CompoundBorderUIResource@1ebcda2d,
    flags=296,maximumSize=,minimumSize=,preferredSize=,defaultIcon=,disabledIcon=,
    disabledSelectedIcon=,margin=javax.swing.plaf.InsetsUIResource[top=2,left=14,bottom=2,
    right=14],paintBorder=true,paintFocus=true,pressedIcon=,rolloverEnabled=true,
    rolloverIcon=,rolloverSelectedIcon=,selectedIcon=,text=first,defaultCapable=true]
    I need this: "first" (from this part: "text=first" of the output above).
    Does anyone know how can I get the "text" field from the e.getSource() ?

    System.out.println( "hi!! " + ( (JButton) e.getSource() ).getText() );I think the problem is solved..If your need is to know the text of the button, yes.
    In a real-world application, no.
    In a RW application, a typical need is merely to know the "logical role" of the button (i.e., the button that validates the form, regardless of whether its text is "OK" or "Save", "Go",...). Text tends to vary much more than the structure of the UI over time.
    In this case you can get the source's name (+getName()+), which will be the name that you've set to the button at UI construction time. Or you can compare the source for equality with either button ( +if evt.getSource()==okButton) {...}+ ).
    All in all, I think the best solution is: don't use the same ActionListener for more than one action (+i.e.+ don't add the same ActionListener to all your buttons, which leads to a big if-then-else series in your actionPerformed() ).
    Eventually, if you're listening to a single button's actions, whose text change over time (e.g. "pause"/"resume" in a VCR bar), I still think it's a bad idea to rely on the text of the button - instead, this text corresponds to a logical state (resp. playing/paused), it is more maintainable to base your logic on the state - which is more resilient to the evolutions of the UI (e.g. if you happen to use 2 toggle buttons instead of one single play/pause button).

  • Is there a way to get the correct order from the dependent types of a sche

    Hi ,
    I have a CT facing the following problem:
    When trying to built a SQL script to create all the object types within a schema using the DBMS_METADATA packages.
    Did insert in a table the names of the types that will be exported following a concrete order, next loop into the table and call the DBMS_METADATA package for each row.
    These type are depedent between them, there are some type attributes calling other types and here the issue
    First : try to generate the order by created column of dba_objects and when the generated SQL script is launched a lot of type appearing as incomplete state due to the order isn't correct.
    Second : try to insert the table ordering by object_id colums of dba_tables view, it appears incomplete types too.
    Currently want to insert the table using a recursive query with connect by against the dba_type_attrs starting with the rows when ATTR_TYPE_NAME is not null (the types that are called by other types), but this way has a issue dificult to resolve: the roots of hierarchy are the rows when ATTR_TYPE_NAME is not null and we've dependencies between roots nodes
    The question is is there a way to get the correct order from the dependent types of a schema?
    Platform: IBM SP AIX
    DB version: 9.2.0.7
    Any help will be appreciated .
    Thanks in advance.

    The xxx_dependencies view should give you the dependencies betwee nthe various types. I would look at something along the lines of:
    SELECT object_name, referenced_name
    FROM (SELECT o.object_name, d.referenced_name
          FROM user_objects o, user_dependencies d
          WHERE o.object_name = d.name(+) and
                o.object_type = d.type(+) and
                d.referenced_type(+) = 'TYPE' and
                o.object_type = 'TYPE')
    START WITH referenced_name IS NULL
    CONNECT BY PRIOR object_name = referenced_nameThe outer join between user_objects and user_dependencies is required to generate the names of types which are not dependent on other types, or do not have other types dependent on them.
    HTH
    John

  • HT201269 My computer crashed and had to be restored to factory settings. My ipad has my ituned library. how do i get the music collection from the ipad to the computer?

    my computer crashed and had to be restored to factory settings losing ituness collection of music. My ipad has my itunes library. how do i get the music collection from the ipad to the computer?

    You should be able to copy iTunes purchases over to your computer's iTunes via File > Devices > Transfer Purchases. For music from other sources (e.g. copied from CDs) you will need a third-party program to copy them back from your iPad - there are some listed half-way down this page which should work : https://discussions.apple.com/docs/DOC-3991

Maybe you are looking for

  • How to inforce specific color settings in InDesign CS4 js

    Hi, I need to set specific color settings when creating a pdf from InDesign in Java script (not as a preset). What I found in previous discutions is: #target InDesign app.ColorSettings.cmsSettings="MyColorSettings"; ( in the Forum http://forums.adobe

  • Firefox doesn't work with tiscali webmail

    After entering the webmail account the browser doesn't display mail directory structure waiting indefinitely

  • Query output scroll Buttons

    It would be nice if there was a >> and << Buttons to get you to the bottom of a query return set and one to get you back to the beginning of the return set. It is time consuming to keep sliding the scroll bar to have the next xxx rows returned. Nice

  • Project Settings - paths, classes, etc

    I am interested in finding out if anyone is creating 'default project' settings. For example, having a 'production' source reference library, that would be searched during 'make/compile' and 'build' processes. More detail: Application 'ABC' currently

  • "Built In " battery ... what is the best way to deal with it ?

    Hi ... I just bought this laptop envy6-1100se with a built in battery and I actually heard alot of diffrent opinions about the best way to deal with the battery and charging and I don't know what to trust to make my batterylife the longest   so hope