Urgent:Struts question

Hi,
I am working on a web application using struts framework. I know Struts provides internationalization of messages and labels using MessageResources. I have a requirement that all the error messages (not the fields labels on the form) should come from a table in the database. I know how to do this using a messageresource properties file. Is there any way I can retrieve the error messages from a database table and still be able to provide internationalization. Please help.

have look at this page:
http://java.sun.com/docs/books/tutorial/i18n/resbundle/propfile.html
if they are using a code line like this
ResourceBundle labels =
ResourceBundle.getBundle("LabelsBundle", currentLocale);
in struts you should be able to simply provide
a class named like the application properties you specify in struts-config.xml implementing the ResourceBoundle interface ... and it should get called for retrievign messages.
You should be able to find details on the page mentioned above.
Also it might be a good idea to browse the struts sourcecode for a line like the one above to check if they really do it that way..
good luck
Spieler

Similar Messages

  • Urgent SQL question : how to flip vertical row values to horizontal ?

    Hello, Oracle people !
    I have an urgent SQL question : (simple for you)
    using SELECT statement, how to convert vertical row values to horizontal ?
    For example :
    (Given result-set)
    MANAGER COLUMN1 COLUMN2 COLUMN3
    K. Smith ......1
    K. Smith ...............1
    K. Smith ........................1
    (Needed result-set)
    MANAGER COLUMN1 COLUMN2 COLUMN3
    K. Smith ......1 .......1 .......1
    I know you can, just don't remeber how and can't find exactly answer I'm looking for. Probably using some analytic SQL function (CAST OVER, PARTITION BY, etc.)
    Please Help !!!
    Thanx !
    Steve.

    scott@ORA92> column vice_president format a30
    scott@ORA92> SELECT f.VICE_PRESIDENT, A.DAYS_5, B.DAYS_10, C.DAYS_20, D.DAYS_30, E.DAYS_40
      2  FROM   (select t2.*,
      3                row_number () over
      4                  (partition by vice_president
      5                   order by days_5, days_10, days_20, days_30, days_40) rn
      6            from   t2) f,
      7           (SELECT T2.*,
      8                row_number () over (partition by vice_president order by days_5) RN
      9            FROM   T2 WHERE DAYS_5 IS NOT NULL) A,
    10           (SELECT T2.*,
    11                row_number () over (partition by vice_president order by days_10) RN
    12            FROM   T2 WHERE DAYS_10 IS NOT NULL) B,
    13           (SELECT T2.*,
    14                row_number () over (partition by vice_president order by days_20) RN
    15            FROM   T2 WHERE DAYS_20 IS NOT NULL) C,
    16           (SELECT T2.*,
    17                row_number () over (partition by vice_president order by days_30) RN
    18            FROM   T2 WHERE DAYS_30 IS NOT NULL) D,
    19           (SELECT T2.*,
    20                row_number () over (partition by vice_president order by days_40) RN
    21            FROM   T2 WHERE DAYS_40 IS NOT NULL) E
    22  WHERE  f.VICE_PRESIDENT = A.VICE_PRESIDENT (+)
    23  AND    f.VICE_PRESIDENT = B.VICE_PRESIDENT (+)
    24  AND    f.VICE_PRESIDENT = C.VICE_PRESIDENT (+)
    25  AND    f.VICE_PRESIDENT = D.VICE_PRESIDENT (+)
    26  AND    f.VICE_PRESIDENT = E.VICE_PRESIDENT (+)
    27  AND    f.RN = A.RN (+)
    28  AND    f.RN = B.RN (+)
    29  AND    f.RN = C.RN (+)
    30  AND    f.RN = D.RN (+)
    31  AND    f.RN = E.RN (+)
    32  and    (a.days_5 is not null
    33            or b.days_10 is not null
    34            or c.days_20 is not null
    35            or d.days_30 is not null
    36            or e.days_40 is not null)
    37  /
    VICE_PRESIDENT                     DAYS_5    DAYS_10    DAYS_20    DAYS_30    DAYS_40
    Fedele Mark                                                          35473      35209
    Fedele Mark                                                          35479      35258
    Schultz Christine                              35700
    South John                                                                      35253
    Stack Kevin                                    35701      35604      35402      35115
    Stack Kevin                                    35705      35635      35415      35156
    Stack Kevin                                    35706      35642      35472      35295
    Stack Kevin                                    35707      35666      35477
    Stack Kevin                                               35667      35480
    Stack Kevin                                               35686
    Unknown                             35817      35698      35596      35363      35006
    Unknown                                        35702      35597      35365      35149
    Unknown                                        35724      35599      35370      35155
    Unknown                                                   35600      35413      35344
    Unknown                                                   35601      35451      35345
    Unknown                                                   35602      35467
    Unknown                                                   35603      35468
    Unknown                                                   35607      35475
    Unknown                                                   35643      35508
    Unknown                                                   35644
    Unknown                                                   35669
    Unknown                                                   35684
    Walmsley Brian                                 35725      35598
    23 rows selected.

  • Urgent 508 Question!

    The only thing i need to do is add a title or label attribute to some of the controls.
    One of the ones to begin with that i am fixing is the ADF tag af:selectBooleanRadio. When i add some text to the shortDesc field of the control, the html is produces doesn't have the title attribute.
    So i tried to use the corresponding trinidad control tr:selectBooleanRadio, and add some text to the same shortDesc field for the control, and in this case it does add a title attribute in the html that it produces.
    Everything else in the code works fine as well when i add the trinidad control, except for one thing. I have a ValueChangeListener that gets called when you click on another tr:selectBooleanRadio. Within that valueChangeListener event handler function, i have a bunch of code which in the end displays a af:popup. The problem i am having when using the trinidad control is that it somehow is not allowing the display of the popup even though it is going through the code that executes display of the popup. When i click on another link or button that is supposed to display a different popup as well, then the popup associated with the tr:selectBooleanRadio also displays at that time, but not originally when the value changed by selecting a different tr:selectBooleanRadio.
    So, my question is, are there any other successful ways of adding a title attribute to the these controls. If its the af:selectBooleanRadio how do we make it so that the html it generates has the title attribute, or if its the tr:selectBooleanRadio, what might be happening during the event handling that it is not allowing the af:popup to display?
    A quick response to this appreciated since this is very urgent! Thanks very much for your help!

    JDev version is 11.1.1.5
    ok, i will go one step at a time so that it is easy to understand. So i will only mention the first thing right now and then we can try other things later.
    i have a af:selectBooleanRadio. After running the page/application, when the user does View Source in the browser for the page that has the radio button, it is in the form of an HTML tag <input> of type for radio button. What i want to do is to have a "title" attribute for the <input> tag for this radio button. I can use the tr:selectRadioButton trinidad control to do that, but then i have other issues with that, and we can talk about those later.
    Let me know if it is still not clear.
    Thanks very much for your help!

  • URGENT : Challenge questions query: Oracle Access Manager 10g

    Hi all,
    This is a query regarding password challenge questions in Oracle Access Manager 10g. We have created password policies for a specific container in OID (say cn=xxx,cn=users,dc=oracle,dc=com) and it is working fine.
    In order to exclude certain set of users (say user ABC ) for password policies, we have set the obpasswordchangeflag to false for those users which are in same container for which password policy is created.
    When we try to login to the application with the user say ABC, I am not seeing any reset password page - I am happy till this point. However it is showing Configure Challenge questions page. Is there any way to bypass this page? Or is this the expected behavior?
    This is very urgent and prompt reply is very much appreciated.
    -Mahendra

    Hi Mahendra,
    This is expected behaviour. In order to exclude the password policy management for some certains user for particular domain/container. please add the below configuration parameter to your OAM10g password policy.
    Password Policy Filter Field     (!(|(cn=xxx)(cn=abc)))
    ----Ajay

  • Urgent constructor question..

    I'm trying to call this Flower class in another class called Garden, in which I created a new Flower by using a statement
    private Flower lastflower;
    and it's saying it cannot find the symbol - constructor Flower.
    Can anyone tell me why and help correct this problem?
    Below is the code for my Flower class.
    Any help is really appreciated, it's for my Java class!
    import objectdraw.*;
    import java.awt.*;
    * Write a description of class Flower here.
    * @author (your name)
    * @version (a version number or a date)
    public class Flower
        protected FilledOval dot;
        protected FilledRect stem;
        protected FilledOval petal1;
        protected FilledOval petal2;
        protected static final int boundary = 100;
        protected RandomIntGenerator colorGen =
                new RandomIntGenerator(0,255);
        protected Color petalColor;
        protected Boolean flowerContains=false;
        private DrawingCanvas canvas;
        public void changeColor(){
        dot = new FilledOval(150,150,15,15, canvas);
        dot.setColor(Color.YELLOW);
        petalColor = new Color(colorGen.nextValue(),
                                    colorGen.nextValue(),
                                    colorGen.nextValue());
        petal1.setColor(petalColor);
        petal2.setColor(petalColor);
        public void grow(Location point){
        stem = new FilledRect (dot.getX()+3, dot.getY()+10, 10, 10, canvas);
        stem.setColor(Color.GREEN);
        if (dot.getY()>boundary){
            dot.move(0,-4);
        else{
         petal1 = new FilledOval(dot.getX()-12, dot.getY()-25, 40,70,canvas);
         petal2 = new FilledOval(dot.getX()-25, dot.getY()-10, 70,40,canvas);
         dot.sendToFront();
         stem.sendToBack();
         petal1.setColor(petalColor);
         petal2.setColor(petalColor);
        public Boolean flowerContains(Location point){
            if (petal1.contains(point)){
                return true;
            else if (petal2.contains(point)){
                return true;
            else if (dot.contains(point)){
                return true;
            else{
                return false;
    }

    I don't care how fucking urgent you think it is, it isn't to us. We will answer your question when and how we feel llike it. Have some manners and if you must, then bump your original post. Don't create another time wasting piece of cr&#97;p!

  • Strut Question

    I have a question about struts. I know Strut is good framework for designing a large website. It has a lot of classes that help to design well scaled websites. What about performance? Does it slow the processing of request. if speed is the main issue is it good idea to use strut?if website needs to handle about 200,000
    request per hour would you advice to use strut?

    You may get more responses in this forum but I thought I'd pass along a struts specific resource that you could also try.
    A good source of help on Struts specific questions is the Struts user mailing list at Apache ... it's filled with helpful people, and the archives are a gold mine of good advice. To subscribe, send an empty message to <[email protected]>.

  • Struts question ?

    hi,
    i am using the struts framework, i have createa my own
    RequestProcessor class in order to check if the user have already loggged on.
    import javax.servlet.*;
    import javax.servlet.http.*;
    import org.apache.struts.action.*;
    public class eShoopRequestProcessor extends RequestProcessor {          
    protected boolean processPreprocess(HttpServletRequest request,                                        HttpServletResponse response) {
                   HttpSession session = request.getSession();          
    //the user has already logged on          
    if (session.getAttribute("user") != null)
                   super.processPreprocess(request,response);          
    //the user has to logon          
    else {               
    //forward to login.jsp ?          }                   }}My question is, which is the best way to forward the request to another ressource "/jsps/logon.jsp", have i to use the ServletContext ??? or ActionMappings (how to access the ActionMappings class) ???
    i have also to say that there's a global-forward defined
    in structs-config.xml...
    <global-forwards>       
    <forward name="logon" path="/jsps/logon.jsp">
    </forward>
    </global-forwards>thanks for your answer.

    This is a cross-post:
    http://forum.java.sun.com/thread.jsp?forum=4&thread=439879&tstart=0&trange=15
    It's considered rude. You don't increase your chances of getting an answer when you submit the same question to several forums. It's better to pick the appropriate one and see what happens. If you get no response, THEN it might be considered okay to send it to another forum, as long as you let people know that it's a cross-post and provide a link to the original.
    Have you tried the Struts mailing list? Those folks are pretty responsive, and you're guaranteed to get a knowledgable audience. - MOD

  • Help please - urgent exam question

    I'm having difficulty with the following question for an OU exam:
    You will now create a method to enable students to make a list of the books they have read, whether they are on the course�s reading list or not.
    Add an instance method to the class, with the header: public Set<String> collectBooksRead()
    The method should first declare a local variable of type Set called readBooks capable of holding a set of strings.
    The method should then assign to that variable an appropriate set object.
    The method should then use a dialogue box to collect the book titles one at a time from the user.
    The dialogue box should have the prompt "Please input a book title or * to finish", and should have an empty string as its default reply.
    Each entered book title should be added to the set referenced by the local variable readBooks. Finally the method should return readBooks as the message answer.
    Here's my code so far but it endlessly loops and I'm unsure how to make it stop.
    public Set<String> collectBooksRead()
    Set<String> readBooks = new HashSet<String>();
    String title;
    do
    title = OUDialog.request("Please input a book title or * to finish",""); //OUDialog.request displays an input dialogue box as specified by a superclass
    readBooks.add(title);
    while
    (title != "*");
    }  

    I'm having difficulty with the following question for
    an OU exam:
    You will now create a method to enable students to
    make a list of the books they have read, whether they
    are on the course�s reading list or not.
    Add an instance method to the class, with the header:
    public Set<String> collectBooksRead()
    The method should first declare a local variable of
    type Set called readBooks capable of holding a set of
    strings.
    The method should then assign to that variable an
    appropriate set object.
    The method should then use a dialogue box to collect
    the book titles one at a time from the user.
    The dialogue box should have the prompt "Please input
    a book title or * to finish", and should have an
    empty string as its default reply.
    Each entered book title should be added to the set
    referenced by the local variable readBooks. Finally
    the method should return readBooks as the message
    answer.
    Here's my code so far but it endlessly loops and I'm
    unsure how to make it stop.
    unplug the computer. works every time

  • Very urgent BPS questions

    hey pals,
    I have couple of doubts which are very urgent to be clarified.
    1.how to debug the code in fox editor?
    2.can we use transactional infocubes in bps?
    3.can we use multiprovider for planning?
    4.how to fine tune the standard planning functions provided by sap?
    5.when exit variables are used?
    I need these answers asap.Anyone with suitable answer will be rewarded immediately.Thank you.
    Regards,
    Rags

    1.how to debug the code in fox editor?
         use break-point in FOX code
    2.can we use transactional infocubes in bps?
         yes. Transactional cubes are meant for only BPS.
    3.can we use multiprovider for planning?
       Yes. multiproviders can be used both in basic planning area as well as multi planning area.
    4.how to fine tune the standard planning functions provided by sap?
       these are not recommended. But, create exit & FOX functions to meet your requirements.
    5.when exit variables are used?
       If variable1 needs to be derived from variable2. (in which, end user fills only variable2).

  • Urgent: Struts Tile Version supported in 10.1.2.0.2

    We are porting a tiles-application to 10.1.2.0.2 OC4J. But we get some errors invoking a tiles-page.I think the struts version we are using is 1.2.6. The struts-tiles.tld says version 1.3 And the error we get is:
    Errors parsing struts-tiles.tld
    Error: <>tiles.taglib.useattributeTEI
    Any suggestions? Thanks.

    I've found this is a problem only with the standalone
    version of OC4J 10.1.2.0.0You mean it works correctly in Oracle 10gAS?I have yet to test the main application server.
    It only returns the JAZNUserManager each and every time.Pardon my ignorance, what are you expecting it to return?Well in previous revisions it has always returned the custom UserManager I have declared in my orion-application.xml.
    In my orion-application.xml file I have:
    <user-manager class="com.security.model.MyUserManager" display-name="MyUserManager">
         <property name="jdbcDriver" value="com.mysql.jdbc.Driver" />
         <property name="dbUrl" value="jdbc:mysql://localhost/mysql" />
         <property name="dbUser" value="user" />
         <property name="dbPass" value="user" />
    </user-manager>If I modify the application.xml file and place my own Custom UserManager there it affects the whole server. In my case it should only affect the current application it is declared in.
    I've already spent a week on this with metalink and we resolved that this is the way it should work.
    Going back to revision 9.0.4.0.0 of the OC4J standalone this problem does not exist and I get the Custom User manager returned that was declared.
    Even the standalone_guide.pdf in 10.1.2.0.0 still has the same reference that this should work - but it does not.
    Anthony

  • Urgent SSL questions

     

    Why in the name of God don't you post this sample code here in the newsgroup so everyone can see it instead of just emailing it to a single individual? Can you please post it?
    Bryan O'Sullivan <[email protected]> wrote:
    b> All docs on the BEA website talk about 2-way authentication with
    b> browsers and servlets. Can I use the T3Client (t3s://host:port) in
    b> setting up my InitialContext to talk to beans on the server to
    b> create the secure connection?
    Yes, you can. You need to set up some extra environment parameters to
    do this, which unfortunately aren't well-documented in 4.5. I'll send
    you a code example that should clarify things.
    b> Do I need a specific service pack to enable this functionality?
    You need at least 4.5.1sp5. This functionality was documented as
    working in earlier 4.5 releases, but embarrassingly enough for us, it
    didn't.
    b> "Important: Certificates from Microsoft Internet Information Server
    b> and Netscape Enterprise Server cannot be used with Weblogic Server,
    b> because they are stored in a proprietary format."
    b> Does this pertain to Netscape Certificate Server as well?
    I don't know; I've never used NCS. However, if NCS can spit out
    certificates in X.509 format, using either DER or PEM encoding, then
    you should have no problems.
    b> Where can I find code samples for doing what I want to do?
    If you're using a Java client, we actually don't ship any useful
    examples of two-way SSL authentication with WLS 4.5.x. However, I'll
    mail you a copy of an example program from Denali beta 2 which should
    work with a 4.5.x server.
    b> The "Using Weblogic SSL" page is not too useful for implementation
    b> details.
    I know. We've worked to beef the documentation up for Denali. As you
    can imagine, since we documented two-way SSL authentication as working
    in 4.5 but never really got any complaints from customers about the
    fact that it was broken (I just happened to notice it myself), it's
    not a feature that has seen much use yet. I apologise for the
    roughness around the edges so far; I hope this information helps you
    to find out what you need.
    When Denali beta 2 comes out, you might want to download it and look
    at its expanded support for two-way SSL authentication. It's really
    quite a bit more useful than 4.5 in this regard.
    If you have any further questions, please feel free to ask.
         <b
    Let us pray:
    What a Great System.
    Please Do Not Crash.
    ^G^IP@P6

  • URGENT: Unicode questions

    Hi experts out there
    We need to have a unicode system soon.
    At the moment we have a non unicode R/3 Rel. 4.7 Enterprise.
    My questions are:
    1. Are there patches that upgrade the non unicode R/3 Rel. 4.7 Enterprise to the unicode R/3 Rel. 4.7 Enterprise?
    2. Should we better upgrade it to ECC 6.0? What is the effort here?
    Any suggestions/responses would be very appreciated.
    Thanks
    HW

    There cant be patches because the data must be converted from a certain code page to unicode.

  • JSP, Struts question - novice

    Hi,
    I'm new to Struts and am trying to get the hang of it.
    Here's what I am trying to do.
    In my action class:
    Collection b_list = DM.findAllById();
    request.setAttribute("fields1", b_list);
    Here, DM is a java class and the findAllById method returns an ArrayList. Each item in the array list is lets say of the type: abc(String id, String value) with getId() and getValue() implemented in that class.
    Now in my JSP:
    I do not have a form bean asssociated with it. Infact, I do not want to submit any data from this. I simply want to show a drop down menu box with all items from the collection.
    But I presume I need to create a bean using the object I have added to the request object.
    So, I'm trying to do this: (i dont know if I need property="id" for html:select tag as I dont want to submit anything.
    <logic :p resent parameter="field1">
    <bean :p arameter id="mylist" name="field1"/>
    <html:select property="id">
    <html :o ptionsCollection label="id" name="myList" value="value"/>
    </html:select>
    </logic :p resent>
    OR
    <html :o ptions collection="myList" property="value" labelProperty="id"/>
    instead of html :o ptionsCollections
    Is this correct? I cant get it to work. Am I missing something?
    I do not want to submit any info from this jsp. My jsp (a popup actually) simply uses a javascript function to update something in the previous JSP.
    Also, please note that I am NOT using LabelValueBean and am passing the Collection in the request object and TRYING to create a bean on the fly using the Collection of objects in the JSP.

    I do not have a form bean asssociated with it.
    Infact, I do not want to submit any data from this. I
    simply want to show a drop down menu box with all
    items from the collection.and then do what with the selected value?
    makes no sense to me. (or i'll learn something, too.) put a form in there and send the selection back to the controller servlet. everything from a page has to go back to the controller.
    I do not want to submit any info from this jsp. My
    jsp (a popup actually) simply uses a javascript
    function to update something in the previous JSP.this defeats the purpose of struts and the front controller, if i understand it correctly. that puts page navigation inside pages, and that's exactly what struts is supposed to remove.
    you're not using struts right by doing this, imo.
    %

  • Urgent Reset Question--???  --Help???

    I know if I reset my Ipod to correct a Problem I will lose all my Music. My Question is will all my library of songs reload, or will I have to re-buy all my music?
    Thanks for your help!
    Dell   Windows XP Pro  

    Resetting the iPod does not affect the contents, you are confusing it with restoring the iPod.

  • Urgent - general question - cursor related, maybe?

    Background:
    I have a hierarchy of tables say A,B,C, each having a one to many relationship (A 1..n B 1..n C). I want to set one of the columns of A to a value of the primary key of one of the rows of B or C. The logic that I need to set the value in A is as follows:
    If one of the rows in B has one of the several columns = NULL(start with the column on the left and keep going to the right) then I need to set the primary for that row in B to the column in A.
    If all columns in all the rows in B <> NULL, then I need to drill down deeper into table C to do the same and set the Column in Table A to a value if I find a discrepnacy.
    Question:
    Is it possible to do this without using cursors? My boss thinks it can be done without using cursors. I don't see how it is possible. But if anyone has an idea please let me know.
    Thanks in advance.

    SQL> -- test data:
    SQL> SELECT * FROM a
      2  /
         PK_ID COL       COL2 COL3 COL4 COL5                                                           
             1 ABC        123 FRED ?    *                                                              
             2 XYZ        789 MIKE ??   **                                                             
    SQL> SELECT * FROM b
      2  /
         PK_ID       FK_A   COL1CODE   COL2CODE   COL3CODE COL1DESC COL2DESC COL3DESC                  
             5          1        111        222        333 ABC      SDF      TEST                      
             6          1        444        555        666 A35                                         
             7          2        111        222        333 ABC      SDF      TEST                      
             8          2        888        222        999 A60      B45                                
    SQL> -- update:
    SQL> UPDATE a
      2  SET    col4 =
      3           (SELECT pk_id
      4            FROM   (SELECT pk_id, fk_a,
      5                     NVL2 (col1desc,
      6                        NVL2 (col2desc,
      7                           NVL2 (col3desc, NULL, col3code),
      8                           col2code),
      9                        col1code) AS colcode,
    10                     ROW_NUMBER () OVER (PARTITION BY fk_a ORDER BY pk_id) AS rn
    11                 FROM   b
    12                 WHERE  NVL2 (col1desc,
    13                        NVL2 (col2desc,
    14                           NVL2 (col3desc, NULL, col3code),
    15                                 col2code),
    16                           col1code) IS NOT NULL)
    17            WHERE  rn = 1
    18            AND    fk_a = a.pk_id),
    19           col5 =
    20           (SELECT colcode
    21            FROM   (SELECT pk_id, fk_a,
    22                     NVL2 (col1desc,
    23                        NVL2 (col2desc,
    24                           NVL2 (col3desc, NULL, col3code),
    25                           col2code),
    26                        col1code) AS colcode,
    27                     ROW_NUMBER () OVER (PARTITION BY fk_a ORDER BY pk_id) AS rn
    28                 FROM   b
    29                 WHERE  NVL2 (col1desc,
    30                        NVL2 (col2desc,
    31                           NVL2 (col3desc, NULL, col3code),
    32                                 col2code),
    33                           col1code) IS NOT NULL)
    34            WHERE  rn = 1
    35            AND    fk_a = a.pk_id)
    36  WHERE EXISTS
    37           (SELECT pk_id
    38            FROM   (SELECT pk_id, fk_a,
    39                     NVL2 (col1desc,
    40                        NVL2 (col2desc,
    41                           NVL2 (col3desc, NULL, col3code),
    42                           col2code),
    43                        col1code) AS colcode,
    44                     ROW_NUMBER () OVER (PARTITION BY fk_a ORDER BY pk_id) AS rn
    45                 FROM   b
    46                 WHERE  NVL2 (col1desc,
    47                        NVL2 (col2desc,
    48                           NVL2 (col3desc, NULL, col3code),
    49                                 col2code),
    50                           col1code) IS NOT NULL)
    51            WHERE  rn = 1
    52            AND    fk_a = a.pk_id)
    53 
    SQL> /
    2 rows updated.
    SQL> -- results:
    SQL> SELECT * FROM a
      2  /
         PK_ID COL       COL2 COL3 COL4 COL5                                                           
             1 ABC        123 FRED 6    555                                                            
             2 XYZ        789 MIKE 8    999                                                      

Maybe you are looking for