How to present my request result a "nicer way" ?

Dear Expert,
Two tables:
- User: UserID, UserName, JobID (FK on Job)
- Job: JobID, JobDescription
The request:
Select JoBDescription, UserName
from Job j, User u
where j.JobID = u.JobID
returns
Clerk, Mary
Clerk, John
Section Manager, Bob
Section Manager, Samantha
Section Manager, Lorrie
I'd like to change the presentation of the result like:
Clerk, Mary
(blank), John
Section Manager, Bob
(blank), Samantha
(blank), Lorrie
assuming that the (blank) means the JobDescription is the same as the for the above employee.
Is there a way to do so using SQL ?
Hope you can get some advice on that.
Best Regards,
Guillaume.

Re: duplicate column values in sort

Similar Messages

  • How to print sql request result to screen by page?

    Hello,
    I'm a beginer in java developpement. I'm looking for information for :
    I want to print to screen the result of a sql request. but I don't know how many lines will be selected. so I want to cut the result in many pages.
    1)how can I do this?
    2)may I do this in Java? if yes in wich package may I search? and is this take a lot of place in memory?
    3)or may I do this with SQL?
    Thank you for your help

    Hi,
    This is a small code snippet, i believe this is more than enough...
    String url = "jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=firstDB)))";
    String username= "test";
    String password = "test";
    String GET_EMPLOYEE_DETAILS = "select name, age from managers";
    Class.forName("oracle.jdbc.driver.OracleDriver").newInstance();
    Connection con = DriverManager.getConnection(url, username, password1);
    PreparedStatement pstmt =con.prepareStatement(GET_EMPLOYEE_DETAILS );
    ResultSet rs = pstmt.executeQuery();
    while ( rs.next())
    System.out.println(rs.getString("name") + ":"+ rs.getInt("age") );
    rs.close();
    pstmt.close();
    con.close

  • How to present results from a sql-query in java

    Hi - I'm having problems finding out how to present data from a database-query in a nice looking way in a JFrame. Want to present them similar to the way they are presented in the database. Is there an easy way doing this?

    Tried to use a JTable, but it's difficult when data in the table should be able to change all the time, i.e the number of rows. What is a Html-table? Can i use it in an application?

  • How I can displsy the results in a nice readable format

    I have this query in a cursor
    I is displaying the data like this
    Major/Minor RestrictionEnglish English and Theater Envir St-English
    How I can make it to display something like this
    Must be enrolled in one of the following Majors:
    English, English and Theater, Envir St-English
    looks easy but the descripton come from the union (cllumn    stvmAjr_desc)
         SELECT
         DISTINCT
           ssrrmaj_major_ind,
            DECODE (
                       ssrrmaj_major_ind,
                       'I', g$_nls.get ('BWCKSCH1-0088',
                               'SQL',
                               'Must be enrolled in one of the following Majors:' ,'<BR />'
                       'E', g$_nls.get ('BWCKSCH1-0089',
                               'SQL',
                               'May not be enrolled in one of the following Majors:','<BR />'
                          indicator1
                FROM ssrrmaj,
            scbcrse,
           ssbsect
          WHERE     scbcrse_subj_code = ssbsect_subj_code
          AND SCBCRSE_CRSE_NUMB = ssbsect_crse_numb
           AND ssrrmaj_crn = ssbsect_CRN
          --- AND ssrrmaj_majr_code = stvmajr_code
           AND ssrrmaj_term_code = ssbsect_term_code
           AND ssrrmaj_major_ind IS NOT NULL
           and SSRRMAJ_TERM_CODE = term  
           and ssbsect_subj_code = subj
           and ssbsect_crse_numb = crse_numb      
           UNION
           SELECT
           DISTINCT
             stvmajr_code,
           stvmAjr_desc
         FROM ssrrmaj,
            scbcrse,
           ssbsect,
          stvmajr
      WHERE     scbcrse_subj_code = ssbsect_subj_code
          AND SCBCRSE_CRSE_NUMB = ssbsect_crse_numb
           AND ssrrmaj_crn = ssbsect_CRN
           AND ssrrmaj_majr_code = stvmajr_code
           AND ssrrmaj_term_code = ssbsect_term_code
           and SSRRMAJ_TERM_CODE = term 
           and ssbsect_subj_code =  subj
           and ssbsect_crse_numb =crse_numb
           ORDER BY ssrrmaj_major_ind DESC;
      the second query display the data after the union
    like this
    1250 Earth and Oceanographic Sci
    1310 English and Theater
    1300 English
    1450 Envir St-English
    I guess I can deal with the dis play like
    this I only need the desc not the code
    Earth and Oceanographic Sci
      English and Theater
      English
    Envir St-English
    This is how I am displaying the results, the results are correct, I just need to diaplay the data in a more friendly format
    HTP.p ('<h4>Major/Minor Restriction</h4>');         
           FOR  ssrrmaj_major_REC IN  ssrrmaj_major_c (term_in,ssbsect_rec.ssbsect_subj_code,ssbsect_rec.ssbsect_crse_numb)
            LOOP
                IF  ssrrmaj_major_REC.ssrrmaj_major_ind IS NOT NULL
                THEN
                ----HTP.p ('<h4>Major/Minor Restriction</h4>');
                 twbkfrmt.p_printtext (ssrrmaj_major_REC.indicator1);  HTP.p ('<BR />') ;
                  ELSE
                  HTP.p ('<h4>Major/Minor Restriction N/A</h4>');
                  END IF;
                END LOOP ;   

    Just a thought...I suggest to use XSLT for doing these type of formatting. Its more flexible to get XML for te query columns and then define the formatting at XSLT level. This way you dont have to keep changing the procedure or query. Just XSL change will do the job..

  • View requests result should open in new browser window

    Hello !
    I am new in OAF. And I am tired of looking forsolution...
    I have a requrement. In the "Request Monitor" page, requests result should open in a new window. It means that each user's click on "View request result" should open in a new browser window.
    I have found url like this in access.log:
    OA_CGI/FNDWRR.exe?temp_id=1069558080
    This url returned from package : fnd_webfile.get_url. And this package is used in about 30 java files...
    And I do not know which one of these files is used in my page...
    Finally, I want to add ' target="_blank" ' to result html code. Like this:
    Maybe It can be done a more simply way?
    Thank you!
    P.S. Here java files:
    Which one is used in "Monitor Request"???
    oracle\apps\az\util\CpLogViewUtil.java
    oracle\apps\fnd\cp\fileops\
    FileConstants.java
    FNDFSFileFetch.java
    oracle\apps\fnd\cp\request\
    RemoteFile.java
    oracle\apps\fnd\cp\util\
    RemoteFile.java
    oracle\apps\fnd\cp\viewreq\server\ViewRequestAMImpl.java
    oracle\apps\fnd\oam\bizexcep\handlers\
    BflowContextDetailsHandler
    oracle\apps\fnd\oam\bobj\activity\
    FRDLog.java
    oracle\apps\fnd\oam\bobj\adconfig\
    AppsCtxtCompFileList.java
    AppsCtxtFiles.java
    oracle\apps\fnd\oam\bobj\manager\crm\
    CRMProcessLog.java
    oracle\apps\fnd\oam\bobj\manager\views\
    ICMProcessLog.java
    ManagerProcessLog.java
    oracle\apps\fnd\oam\bobj\requests\views\
    RequestView.java
    oracle\apps\fnd\oam\cp\fileops\
    FileConstants.java
    FNDFSFileFetch.java
    oracle\apps\fnd\oam\launchMode\restricted\handlers\
    RestrModeHandler.java
    oracle\apps\fnd\oam\sdk\util\files\
    FNDFSUtil.java
    oracle\apps\fnd\oam\sdk\util\log\
    LogHandler.java
    oracle\apps\fnd\oam\sdk\util\support\
    AppsSignatureNode.java
    oracle\apps\fnd\oam\servlet\ui\handlers\activity\
    DatabaseSessionHandler.java
    FRDFilesListHandler.java
    FrmSessionHandler.java
    oracle\apps\fnd\oam\servlet\ui\handlers\adconfig\adv\
    AdvCfgNode.java
    oracle\apps\fnd\oam\servlet\ui\handlers\debugwb\
    SearchPGHandler.java
    oracle\apps\fnd\oam\servlet\ui\handlers\gsc\
    SvcCompDetailsHandler.java
    oracle\apps\fnd\oam\servlet\ui\handlers\request\
    CpRequestHandler.java
    oracle\apps\fnd\oam\servlet\ui\handlers\services\
    ServiceProcHandler.java
    ServiceStsHandler.java
    oracle\apps\fnd\wf\oam\bobj\util\
    WfQuery.java
    oracle\apps\fnd\wf\oam\handlers\
    WfComplWorkItemHandler.java
    Edited by: rsn on 01.12.2010 15:43
    Edited by: rsn on 01.12.2010 15:46
    Edited by: rsn on 13.05.2011 11:27

    Anand, thank You very much!
    "In your page, is "View request result" a link ?
    If yes then
    click on "Personalize Page" link which is at the top right corner of the page. Select "Complete View" radio button and click on "Expand All" link. Search for item "link". If your page has more than one link then choose the link item which is related to "View request result". Click on "Personalize" pencil icon corresponding to "link" item/region. Change the "Target Frame" property value to "_blank" under "Site" level. Click on "Apply" button.
    -Anand"
    This is a great power in "Personalize Page"!
    I make solution in this steps:
    1. Activate personalization to user, by setting profile "Yes" value on user level:
    Personalize Self-Service Defn / FND_CUSTOM_OA_DEFINTION
    2. Personalize 2 regions items (Image & Link)
    ( Don't ask me how !!! ;)
    Image have not Target Property. I move URI to Link Region Item and remove in step 4 from Image Region Item.
    3. Export page and my region
    java oracle.jrad.tools.xml.exporter.XMLExporter /oracle/apps/fnd/cp/viewreq/webui/CPViewRequestPG -rootdir $APPL_TOP/personalizations -username apps -password *** -dbconnection "(description = (address_list = (address = (community = tcp.world)(protocol = tcp) (host = localhost)(port = 1521)))(connect_data = (sid = prod)))"
    java oracle.jrad.tools.xml.exporter.XMLExporter /oracle/apps/fnd/cp/viewreq/webui/customizations/site/0/CPViewRequestPG -rootdir $APPL_TOP/personalizations -username apps -password ***-dbconnection "(description = (address_list = (address = (community = tcp.world)(protocol = tcp) (host = localhost)(port = 1521)))(connect_data = (sid = prod)))"
    4. Modify in notepad /oracle/apps/fnd/cp/viewreq/webui/CPViewRequestPG.xml (remove URI from Image Region Item) from this file.
    5. Install script script for PROD like this:
    cp -R personalizations $APPL_TOP
    java oracle.jrad.tools.xml.importer.XMLImporter $APPL_TOP/personalizations/oracle/apps/fnd/cp/viewreq/webui/CPViewRequestPG.xml -username apps -password *** -dbconnection "(description = (address_list = (address = (community = tcp.world)(protocol = tcp) (host = localhost)(port = 1521)))(connect_data = (sid = prod)))" -rootdir $APPL_TOP/personalizations
    java oracle.jrad.tools.xml.importer.XMLImporter $APPL_TOP/personalizations/oracle/apps/fnd/cp/viewreq/webui/customizations/site/0/CPViewRequestPG.xml -username apps -password *** -dbconnection "(description = (address_list = (address = (community = tcp.world)(protocol = tcp) (host = localhost)(port = 1521)))(connect_data = (sid = prod)))" -rootdir $APPL_TOP/personalizations
    6. After install on PROD, You need to "bounce the apache". Additionally, it need to modify / upply button once on a region link. Right now I can not explain exactly, how it helps... But finnaly changes after 'XMLImporter' command will applyed after modify / upply manipulations.
    Edited by: rsn on 13.05.2011 11:16

  • How to print Spool requests for cheque printing sequentially

    Dear All,
    I am making vendor payments and printing cheques using F-58. It automatically creates a spool requests at the end of the transaction. When i complete all my payments and go to SP01 for viewing spool requests, the last request appears at the top of the list.
    If i select 3 consecutive requests and print them at a time, the last request gets printed first on the first cheque number and the first request gets printed on the last cheque number.
    This results in anomaly in the cheque number assigned in the system and the printed cheque as the last payment is printed on the first cheque.
    I am using dot matrix printer with  page format fixed for cheque specifications. The cheques are printed properly as per the format except the order of printing.
    Kindly let me know how to print multiple requests sequentially from the spool requests list such that the spool request number printed matches with the serial cheque numbers.
    Regards,
    SAP_2009

    Hi,
    I understod your issue.
    Whenever you posted multiple payment documents, and after that if you want to take cheque printouts sequentially by using more spool requests.........there is a way to sort out this issue.
    1) Select all of your spool requests and click on Sort in ascending Order (CtrlShiftF5) and click on Print directly (CtrlShiftF8). By doing this you will get the cheque printouts sequentially according to your payment document sequence.
    Hope this will help you
    Assign ********, if it solved your problem.
    Thanks,
    Srinu

  • How to display the search result without reloading the whole page

    HI,
    I have separate fragments for Search Box to enter keyword and Search Result to display the result. Also I have different sections within the page to put these fragments. So how could I display the results without reloading the whole page.
    Also if I have next button in my search result area, how could I display the search results in next page without reloading all other sections present in our page. Please let me know if any service or idoc function present such that result could be shown in search result section without reloading whole page.
    Please let me know how to restrict page reload for every action within a page.
    Thanks,
    Ramesh
    Edited by: Ramesh_Est on May 27, 2010 3:14 AM
    Edited by: Ramesh_Est on May 27, 2010 8:39 PM

    This is default behaviour of the template of your space. You can create a new page template and than you can create a region for the search results.
    Or you can create a custom taskflow were you use the webcenter taskflows to search for the space.
    Take a look at this white paper:
    Extending webcenter spaces: http://www.oracle.com/technology/products/webcenter/pdf/owcs_r11_extend_spaces_wp.pdf
    and this one:
    Customizing site templates: http://www.oracle.com/technology/products/webcenter/pdf/owcs_ps1_site_template_wp.pdf
    Edited by: Yannick.O on 13-Apr-2010 02:32

  • How to send a request and get a response through xml

    How to send a request and get a response through xml files?

    This is the code that works for me. Hope you find it useful.
         public static String sendHttpGetRequest(String endpoint, String requestParameters){
              String result = null;
              // Send a GET request to the servlet
              try{
                   // Send data
                   String urlStr = endpoint;
                   if (requestParameters != null && requestParameters.length () > 0){
                        urlStr += "?" + requestParameters;
                   URL url = new URL(urlStr);
                   HttpURLConnection conn = (HttpURLConnection) url.openConnection();
                   conn.setRequestProperty("Accept", "application/xml");
                   // Get the response
                   BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));
                   StringBuffer sb = new StringBuffer();
                   String line;
                   while ((line = rd.readLine()) != null){
                        sb.append(line);
                   rd.close();
                   result = sb.toString();
              } catch (Exception e){
                   e.printStackTrace();
              return result;
         }

  • Just bought Photoshop Elements 13...I'm trying to make a slideshow but can't figure out how to alter duration time that the slide is on the screen.  They presently move from one to another way too quickly...also need a different pan and zoom option.  Wher

    Just bought Photoshop Elements 13...I'm trying to make a slideshow but can't figure out how to alter duration time that the slide is on the screen.  They presently move from one to another way too quickly...also need a different pan and zoom option.  Where are all the options I had in PS10?  Also...Can I burn this to a DVD?

    The changes have brought improvements but also drawbacks compared with the old slideshow editor.
    The templates are now fairly fixed but I find the “Classic Dark” gives reasonable results with some panning and you can click the audio button and browse you PC for any track. Unfortunately there are only three speed choices linked to the music track. The improvement for most people is that you can now export to your hard drive at 720p or 1080p and upload to sites like YouTube and Vimeo.

  • How RAC hadling users requests

    Hi
    please advice how RAC handel users request within nodes is there wait come behind?
    is this affect system performance due to data synchronization.

    Hi
    please advice how RAC handel users request within
    nodes is there wait come behind?
    is this affect system performance due to data
    synchronization.Do you have any experience or example case to argue on, your question is not clear.
    Of course RAC has its own alternative costs, I think these two presentations can give an idea;
    http://juliandyke.com/Presentations/Presentations.html#ARoughGuideToRAC
    http://juliandyke.com/Presentations/Presentations.html#RACInternals
    ps: Julian's presentations are designed to be followed on slide show mode.

  • How to present a checkbox on editable grid

    Dear The Expert,
    I am learning APEX 4, I have a field named "Active" char(1), it only contained: Y or N
    how to present it as checkbox (Y as checked or N as unchecked) on the editable grid ?
    please advise
    many thanks in advance
    Regards
    Luc
    Edited by: LucKay on Jan 10, 2011 12:37 PM

    Thanks, it works ..
    but now I am facing with below error
    Not Found
    The requested URL /pls/apex/wwv_flow.accept was not found on this server.
    when try to submit new data with checkbox checked!.. ..
    again.. this problem ONLY occurs when any checkbox was checked!
    and I checked on Apache logs .. and found the following:
    [Mor Jan 10 15:59:33 2011] [error] [client 172.16.1.88] [ecid: 1294649973:127.0.0.1:6612:0:2474,0] mod_plsql: /pls/apex/wwv_flow.accept HTTP-404 \nwwv_flow.accept: SIGNATURE (parameter names) MISMATCH\nVARIABLES IN FORM NOT IN PROCEDURE: F06_NOSUBMIT\nNON-DEFAULT VARIABLES IN PROCEDURE NOT IN FORM: \n
    r_log.1294617600
    please help
    thanks
    Edited by: LucKay on Jan 10, 2011 3:54 PM

  • How biztalk handle multiple request at a time ?

    can TCP/IP adapter or biztalk handles multiple request at a time ?
    If yes,then how it process multiple request ? 
    Can TCP/IP send ports sends multiple request ?
    Prakash

    Yes.
    It processes multiple requests using THREADS. Each Connect starts off a thread that handles the receipt of the message, submission to BizTalk, wait for the response (matching two-way subscription) and then respond back to the client.
    TCP/IP Send ports handle multiple requests by creating fresh sockets (RPC High-end ports). As an example, in your browser you open multiple tabs and access different sites, each tab results in your browser opening a fresh socket connection for the request.
    Regards.

  • How can we get requester's user id using java code

    Hi,
    How can we get requester's user id using java code?
    eg: If i had logged in as xelsysadm and request a resource for user uid101 on the userid field it should display uid101 and not xelsysadm.
    also,
    I have a resoure "A" which on revoking should also revoke resources B and C. How can it be done. Resource A, B, and C are 3 different resource objects.
    ==Thanks,
    doki

    Ok, so there is a way, but it's not available during submission. You can use the findRequests api. From the result set, get the "Requests.Consolidated Data Value" value. In this information, you will get an xml formatted data. It provides the list of users on the request on the left side after submission. After the request is completed, this value is available. Upon completion, you could get the request information, get this value, and parse the information for user ids.
    In the same adapter, use the following API:
    formIntf.setObjectFormData(objInstanceKey, formHash)
    The formHash is a hashtable containing the field name on your object form, and the values you wish to populate it with. You could create a textarea box on your object form and populate the userids for who the request is for.
    However, this makes absolutely 0 sense. When you get a request, the list of userids are listed right there on the request.
    -Kevin

  • URGENT: How to delete the request in version management

    Hi,
    Please let me know how to delete a request in version management whcih is not released yet.
    I have released a request to quality server for an object. After that I was asked to make some changes to that object as there are some defects.
    So, i have created a new request and proceeded with the changes. Under that request I have made some changes and activated. but the result is worthless. So, I want to get the result of the object which i have released. i.e. i want to get back only the released request changes.

    Hi,
    yeah............goto version management......first ull hav ur new request......
    below that ull have ur previous request right.............
    check the check box of ur previous request.............
    and click retrine button.......all changes made in ur latest request ll be retrived back to its previous version.........
    come back activete it.............in ur program ull not find ur new useless changes........release it...........
    Cheers,
    jose.........

  • How can we restrict EQL result based on session value

    How can we restrict EQL result based on session value or by checking with EBS secured function?
    Example: I create a Item Search Dashboard but I have more than one inventory organizations and I want to restrict dashboard to bring inventory org respective data by validating responsibility/profile option.
    Can anyone help me on this or if my concept is wrong so can anyone please guide me?

    Hi Bob,
    Thank you. Sorry for the late reply but I was busy in other stuff. I did the jar file and copied that Jar file into .ear/APP-INF/lib and copied on server and updated the df.securitymanager property under framework settings on Endeca Studio and restarted Endeca Server and Studio but seems like my class didn't get read. Kindly suggest and find below snippet of code;
        public void applySecurity(PortletRequest request, MDEXState mdexState, Query query)
                throws MDEXSecurityException
      init(request);
      String remoteUser = request.getRemoteUser();
      String recordFilterExpression = "XX";
      if(recordFilterExpression != null) {
      DataSource ds;
      try {
      ds = new DataSource(request, mdexState.getId());
      try {
      ExpressionBase expression = ds.parseLQLExpression("FND_USER_NAME='" + remoteUser + "'");
      DataSourceFilter dataSourceFilter = new DataSourceFilter(expression); 
      } catch (Exception f) {
      throw new MDEXSecurityException("Unable to apply Expression", f);
      } catch (DataSourceException e) {
      throw new MDEXSecurityException("Unable to create DataSource", e);

Maybe you are looking for

  • How to run command line argument programe

    Hi guys, I am doing pass command line argument programe in java but I don't know how to run this programe. Path for this programe in my my computer is C:\Users\Desktop\Mainjava\mycode\CommandProgjava* {code/} public class CommandProg public static vo

  • Some applications are not opening

    Hi, Many of my applications are not opening. Sometimes when I try to open the application it doesn't even bounce in the dock.  Other times, applications will bounce in the dock and then stop.  These are crucial apps, like Mail, Pages, and iPhoto.  Sa

  • Downloading iTunes Plus song upgrades problem - network connection msg

    I recently upgraded to iTunes 10.1. I also purchased the iTunes plus song upgrades for most of my library. When I try to download these upgrades, I get the same message, which is something like "iTunes Network Connection Time Out". However, I have pu

  • My partner checked my location using find my IPhone on Sunday

    But the location he got was a few kilometres from where I was. He checked it again a few minutes later & the location was correct. I had answered a call & email. I never moved locations by why did my phone show differently?

  • Different photo count

    Hi all, I discovered a strange issue: If I click on "Photos" under "Aperture 3 Library" which should give me all existing pictures, I get a photo count of 6079 pictures. If I mark ALL my projects, which should also give me all existing pictures, I ge