Change output from 4 lines to 1.

ANyone know how I can change the output from this query so that it outputs a single row instead of 4? I need to be able to make the 4 decode select statements into a single one, this I know, but I have problems with the part where I want to take the col, find a row, then put in that value. Here is they query, and below the output.
select distinct(bt.Account_Obj_Id0),
decode( TO_CHAR( End_Dt, 'MM/DD/YYYY'), '09/01/2002', NVL( dt.Current_total ,0) ,0) as "over 120",
decode( TO_CHAR( End_Dt, 'MM/DD/YYYY'), '10/01/2002', NVL( dt.Current_total ,0) ,0) as "90-120",
decode( TO_CHAR( End_Dt, 'MM/DD/YYYY'), '11/01/2002', NVL( dt.Current_total ,0) ,0) as "60-90",
decode( TO_CHAR( End_Dt, 'MM/DD/YYYY'), '12/01/2002', NVL( dt.Current_total ,0) ,0) as "current"
from (select convert_t_time (end_t) End_DT,
total_due,
account_obj_id0,
current_total
-- convert_t_time (start_t) Start_DT
from bill_t
where account_obj_id0 = '9760259'
and convert_t_time (end_t) > trunc (sysdate - 120, 'MM') ) dt,
bill_t bt
where bt.account_obj_id0=dt.account_obj_id0
--GROUP BY bt.Account_Obj_Id0
ACCOUNT_OBJ_ID0 over 120 90-120 60-90 current
9760259 0 0 0 79.53
9760259 0 0 206.29 0
9760259 0 93.85 0 0
9760259 127.17 0 0 0

select bt.Account_Obj_Id0,
          MAX(decode( TO_CHAR( End_Dt, 'MM/DD/YYYY'), '09/01/2002', NVL( dt.Current_total ,0) ,0))  as "over 120",
          MAX( decode( TO_CHAR( End_Dt, 'MM/DD/YYYY'), '10/01/2002', NVL( dt.Current_total ,0) ,0)) as "90-120",
          MAX(decode( TO_CHAR( End_Dt, 'MM/DD/YYYY'), '11/01/2002', NVL( dt.Current_total ,0) ,0))  as "60-90",
          MAX(decode( TO_CHAR( End_Dt, 'MM/DD/YYYY'), '12/01/2002', NVL( dt.Current_total ,0) ,0))  as "current"
  from (select convert_t_time (end_t) End_DT,
                    total_due,
                    account_obj_id0,
                    current_total
                    -- convert_t_time (start_t) Start_DT
             from bill_t
              where account_obj_id0 = '9760259'
                  and convert_t_time (end_t) > trunc (sysdate - 120, 'MM') ) dt,
         bill_t bt
   where bt.account_obj_id0=dt.account_obj_id0
GROUP BY bt.Account_Obj_Id0

Similar Messages

  • Issue with PO change output - Service line items

    Hi All,
    This is issue with PO change output. We have PO with line item 10, 20 and item 10 has 4 service line items. PO is approved and initial print out is taken.
    Some one goes and makes changes to 1st service line items of PO line item 10.
    A change output gets triggered. When this output is printed, it prints line item 10 details. This is standard functionality as this item is changed. But its printing all the service line items for this PO line item. Consider a case where there are 3000 service lines for a PO item. If I add 1 service item to this PO line item, the change form prints 3001 services for that line item. There were no changes done to first 3000 service line items.
    Currently PO change form takes care of changes at PO line item but it does not take care of changes at service line item level.
    Is there any setting that needs to be done for this so that it only considers the changes at Service line item level also.
    Regards,
    Shahu

    If you're using a standard form, send a message to SAP. Otherwise make a change in the form.

  • No output from line out 1 and 3, audig

    A while ago, I observed no sound coming from several speakers in our 5. sound system. 2 of the speakers provide sound. Also running windows xp and audigy 4.
    I followed the trouble shooting guide using headphones and have no sound card ouput from lines and 3. Line 2 provides output.
    We are using a 5. speaker system and individually plugged each of the 3 lines from the speaker system into line 2 out from the sound card and all the speakers sound good.
    uninstalled and reinstalled the drivers 5.2.6.6?
    The troubleshooting guide mentions a "digital only output" toggle under the volume advanced tab. I searched the sound and audio device properties utility from top to bottom but can't find the toggle.
    I am not sure what to do regarding further troubleshooting. Please advise.
    Regards,
    Jer?

    Never mind: focus was on the wrong computer on the KVM.

  • User Exit / BADI to change output from FAX to Email in SRM 5.0

    Hi All,
    I have a requirement to change the Fax output to be changed by Email type and use the fax no as email id for sending the Purchase Order output in SRM 5.0 system.
    Actually here we are not using the FAX server and email is used for faxing things. So I would like to change all the FAX entries to Email and put the email id as <[email protected]> and update the NAST entry.
    Any Clues on this please let me know.
    Thanks in advance.

    Hi,
    i've also tried using the BAdI mentioned to change for some changes required for price during goods movement.
    after discussion with developer, we found out that the when the program reach the BAdI mentioned, it is already too late as the standard program has already populated the accounting document structure to be posted.
    to change the amounts to be posted to the accounting document can be managed with enhancement spots in inlcude program of LRWCLF01.
    but requires heavy logic to restrict to specific scenarios and  intensive testing, not recommended as it is not within the boundaries of standard SAP allowed changes.
    Cheers,
    Joaquin

  • Can I change the Subject line of a saved email?

    Sometimes I save an email and want to revise the subject line so it's more descriptive of what's actually in the message. I remember being able to do this in Outlook, but can't quite figure out how to do it in Apple Mail. (And I don't want o have to forward it to myself, as that changes the From line.)
    Is there a way to simply edit the Subject line of a saved email?

    Actually, MailTags will kind of do what you want. You can tag a message in a number of ways, and one of them is to make a note, and display that note as the subject of the email. For example, I have a message:
    Re: Re: Initial generic topic
    Which actually contains useful information, so in MailTags I make a note "Pablo's Thesis Results" and click "Show as Subject", and now I see the subject as
    Pablo's Thesis Results
    Matt

  • Changing the seeded rdf report output from text to PDF

    Hi All,
    I am trying to change the seeded report "Print Requisition Report" output from text to PDF. I changed the output format in the concurrent program definition from text to pdf. The report is now getting displayed in pdf format, but the alignment of the fields are changed. The output is not printing as it was printing while in the text output format. The output looks very sloppy, with uneven fonts and too much of text wrapping.
    I tried some formatting and fields are somehow getting displayed but doesnt look in proper format. I am not able to change the font style in the report builder 6i, even if i change it is printing in the same font style with uneven font size. I think reducing the font size might help, but i am unable to change.We are on 11.5.10.2. Please provide your valuable suggestions on how to go about.
    Thanks
    Sarvesh

    Hi Hussein,
    Thanks for the information. After the adjustments in the layout and the font change the report is now getting displayed without any clipping when clicked on view output. But when the same report is printed some characters on the left and and right side is getting clipped. Please help on how to solve this issue.
    Thanks,
    Sarvesh

  • Changing standard output from Text to XML customization?

    Hi Team,
    We wanted to get an excel output for a standard reports Accounts Payables Trial Balance, we changed the output from Text to XML. We did not attach a data definition or template definition ..we just wanted to see the XML output.. We got an error in the process ."Caused by: oracle.xdo.parser.v2.XMLParseException: '=' missing in attribute" .. for which we raised a TAR..
    We were told in the TAR that changing the standard output from Text to XML is customization!!!!... can you please clarify if this is the case..

    Hi
    Is this issue get resolved ???
    Thanks
    Shivdeep Singh

  • Change Email subject line for PDF output through smartforms

    Dear all,
    Currently i am working in Client ECC6.and we are useing The Smartform for Sending PDF document to the Customer.
    Since recently email was setup so these invoices can be mailed directly to the customers, but we face the problem that when invoices are sent via email, the subject is like this.
    From: Ramesh Babu mailto:ramesh_babu@abc
    Sent: Wednesday, August 27, 2008 10:40 AM
    To: Babu, Ramesh
    Subject: New Invoice (mail/prnt).
    Now the customer Requirement is that ,they dont want to disclose the Email address of the sender.
    so they want to change the Form line and one hard codeed line always send to the customer like Ex below.
    From: "Help Me Please'' .
    This will aplicable for all sender ,if he send it by foreground or background as well.
    so could you please sugest me how can i do that coding,or is there a user-exit to overrule the Standard SAP behaviour.
    My Print program name: ZLB_BIL_INVOICE .
    Regards,
    Moni

    Hi,
    refer this,
    you can change the subject line.
    FORM docu_send_email USING pv_otfdata  TYPE tsfotf
                               pv_emailid  TYPE any
                               pv_formname TYPE any.
      DATA: lv_filesize    TYPE i,
            lv_buffer      TYPE string,
            lv_attachment  TYPE i,
            lv_testo       TYPE i.
      DATA: li_pdfdata  TYPE STANDARD TABLE OF tline,
            li_mess_att TYPE STANDARD TABLE OF solisti1,
            li_mtab_pdf TYPE STANDARD TABLE OF tline,
            li_objpack  TYPE STANDARD TABLE OF sopcklsti1,
            li_objtxt   TYPE STANDARD TABLE OF solisti1,
            li_objbin   TYPE STANDARD TABLE OF solisti1,
            li_reclist  TYPE STANDARD TABLE OF somlreci1,
            li_objhead  TYPE soli_tab.
      DATA: lwa_pdfdata  TYPE tline,
            lwa_objpack  TYPE sopcklsti1,
            lwa_mess_att TYPE solisti1,
            lwa_objtxt   TYPE solisti1,
            lwa_objbin   TYPE solisti1,
            lwa_reclist  TYPE somlreci1,
            lwa_doc_chng TYPE  sodocchgi1.
      CONSTANTS: lc_u           TYPE char1  VALUE 'U',
                 lc_0           TYPE char1  VALUE '0',
                 lc_1           TYPE char1  VALUE '1',
                 lc_pdf         TYPE char3  VALUE 'PDF',
                 lc_raw         TYPE char3  VALUE 'RAW',
                 lc_ordform     TYPE char15 VALUE 'ZORDCONFIRM_01',
                 lc_attachment  TYPE char10 VALUE 'ATTACHMENT'.
      CALL FUNCTION 'CONVERT_OTF'
        EXPORTING
          format                = lc_pdf
          max_linewidth         = 132
        IMPORTING
          bin_filesize          = lv_filesize
        TABLES
          otf                   = pv_otfdata
          lines                 = li_pdfdata
        EXCEPTIONS
          err_max_linewidth     = 1
          err_format            = 2
          err_conv_not_possible = 3
          err_bad_otf           = 4
          OTHERS                = 5.
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      LOOP AT li_pdfdata INTO lwa_pdfdata.
        TRANSLATE lwa_pdfdata USING ' ~'.
        CONCATENATE lv_buffer lwa_pdfdata INTO lv_buffer.
        CLEAR lwa_pdfdata.
      ENDLOOP.
      TRANSLATE lv_buffer USING '~ '.
      DO.
        lwa_mess_att = lv_buffer.
        APPEND lwa_mess_att TO li_mess_att.
        CLEAR lwa_mess_att.
        SHIFT lv_buffer LEFT BY 255 PLACES.
        IF lv_buffer IS INITIAL.
          EXIT.
        ENDIF.
      ENDDO.
    Object with PDF.
      REFRESH li_objbin.
      li_objbin[] = li_mess_att[].
      DESCRIBE TABLE li_objbin LINES lv_attachment.
    Object with main text of the mail.
      lwa_objtxt = space.
      APPEND lwa_objtxt TO li_objtxt.
      CLEAR lwa_objtxt.
      DESCRIBE TABLE li_objtxt LINES lv_testo.
    Create the document which is to be sent
      lwa_doc_chng-obj_name  = text-008.
      lwa_doc_chng-obj_descr = text-008.
      lwa_doc_chng-sensitivty = lc_0.
      lwa_doc_chng-obj_prio = lc_1.
      lwa_doc_chng-doc_size = lv_testo * 225.
    Pack to main body.
      CLEAR lwa_objpack-transf_bin.
    header
      lwa_objpack-head_start = 1.
    The document needs no header (head_num = 0)
      lwa_objpack-head_num   = 0.
    body
      lwa_objpack-body_start = 1.
      lwa_objpack-body_num   = lv_testo.
      lwa_objpack-doc_type   = lc_raw.
      APPEND lwa_objpack TO li_objpack.
      CLEAR lwa_objpack.
    Create the attachment.
    Fill the fields of the packing_list for the attachment:
      lwa_objpack-transf_bin = gc_x .
    header
      lwa_objpack-head_start = 1.
      lwa_objpack-head_num   = 1.
    body
      lwa_objpack-body_start = 1.
      lwa_objpack-body_num   = lv_attachment.
      lwa_objpack-doc_type   = lc_pdf.
      lwa_objpack-obj_name   = lc_attachment.
      lwa_objpack-obj_descr  = text-008.
      lwa_objpack-doc_size =  lv_attachment * 255.
      APPEND lwa_objpack TO li_objpack.
      CLEAR lwa_objpack.
      lwa_reclist-receiver   = pv_emailid.
      lwa_reclist-rec_type   = lc_u.
      lwa_reclist-notif_del  = gc_x.
      lwa_reclist-notif_ndel = gc_x.
      APPEND lwa_reclist TO li_reclist.
      IF li_reclist IS NOT INITIAL.
        CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
          EXPORTING
            document_data              = lwa_doc_chng
            put_in_outbox              = gc_x
          TABLES
            packing_list               = li_objpack
            object_header              = li_objhead
            contents_bin               = li_objbin
            contents_txt               = li_objtxt
            receivers                  = li_reclist
          EXCEPTIONS
            too_many_receivers         = 1
            document_not_sent          = 2
            document_type_not_exist    = 3
            operation_no_authorization = 4
            parameter_error            = 5
            x_error                    = 6
            enqueue_error              = 7
            OTHERS                     = 8.
        IF sy-subrc <> 0.
             MESSAGE ID sy-msgid TYPE 'I' NUMBER sy-msgno
                     WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
        ENDIF.
      ENDIF.
    ENDFORM.                    " DOCU_SEND_EMAIL

  • How do i change the time line in Au from time since recording start to the actual time?

    how do i change the time line in Au from time since recording start to the actual time? I have a recording that was started at 10:00 but obviously in Au it starts at 0:0:00. Basically i want to time shift this to 10:00:00

    In the Properties panel, modify the Start Time parameter.

  • Change RFQ & PO output from fax to e-mail

    Change RFQ & PO output from fax to e-mail

    You can set this up in NACE as a default or you can also set up condition records to specify if the form should be print, fax, or email.   See if the NACE transaction works for you..use Application EF for Purchase Orders and Application EA for RFQ's.   Hope this is helpful.

  • I need to change the "from" address (the "add to addressbook" address) in the first line of emails that I send. How do I do this?

    I need to change the "from" address (the "add to addressbook" address) in the first line of emails that I send so that people reply to my email alias not the address where my emails originate. How do I do this?

    So you have added a new 'Identity' to your existing email address.
    If someone sends an email using that 'other identity'
    you have a choice of where those received emails can go. they can be received into the original mail account, like a collect all in the one Inbox or perhaps sent to Local Folders, so you can see them as separate. Or you can filter on that identity to put those emails in a specific folder.
    When you REply to any incoming mail that has used that new identity email address, it will use the new identity in the Email address in FROM assuming the received email in the main mail account of which the new identity email is applied.
    This should also now offer the added identity email address as an option in the FROM drop down list. So you can easily swap when sending an email if required.
    If you want to send using your default email address to people, but want their reply to use the identity email address:
    Tools > Account Settings
    select the original email address mail account name
    Where it says: 'Reply to addresses: enter the reply to identity email address.
    click on OK
    This means when they click on 'Reply' it will auto insert the Reply-to option.
    This will work providing it is a 'Reply' to an email you sent which contains the Reply-to email address.
    If someone is not actually replying by using the Reply-to new identity email address:
    In other words they are sending you a new email using the original email address because perhaps that is the one in their address book or the one they located on a webpage etc.
    Then, when you select to Reply to that email, it will use the email address to which it was sent to in the FROM field - the original email address. Hence why you would need to select the new identity FROM in the drop down list.
    One way to get around this is set out below.
    If you do not use an identity - instead you create another existing mail account for the 'identity' email address, so you have two mail accounts for the two email addresses.
    You can move selected emails manually or perhaps using a filter to screen them from the original mail account into the newly created mail account.
    Then when you click on Reply, it will use the new mail account email address instead of the original email address.

  • Get output from dos window to jtextarea/textarea

    hi
    i am executing the following lines of code:
    1)Runtime r=Runtime.getRuntime();
    Process p=r.exec("javac <filename.java>");
    when executing this there is no exception fired but i am not being able
    to get the output from the ods console to a textarea
    or for that matter i donot get any output anywhere
    2)if i change it to
    Process p=r.exec("java <filename");
    similar thing happens i.e no output
    can anyone plz help
    thanx.

    Sorry, this < was the wong way around
    Process p=r.exec("java filename >test.txt")
    Then read in data from test.txt, something like this should do it :))   public String getTextFile(String text) throws Exception{
          int reader = 0;
          text = "";
          FileReader in = new FileReader("test.txt");
             do {
                reader = in.read();
                text += (char)reader;
             }  while (reader != -1);
          in.close();
          return text;

  • SB Live! changing between Speaker&Line-

    I do have a Soundblaste Li've! (CT4830) with the Li'veware3.0 Driver installed and want to use a Headset and/or Speaker.
    Headset is installed in Mic and Speaker Out, Speaker are in Line-Out. So in a 4 Speaker Setup the Headset would be Front and Speakers Rear.
    Is there a possibility to switch between these 2 Line-Outs so i don't have to change the jack every time i want to use the speakers?

    Simon983 wrote:
    I do have a Soundblaste Li've! (CT4830) with the Li'veware3.0 Driver installed and want to use a Headset and/or Speaker.
    Headset is installed in Mic and Speaker Out, Speaker are in Line-Out. So in a 4 Speaker Setup the Headset would be Front and Speakers Rear.
    Is there a possibility to switch between these 2 Line-Outs so i don't have to change the jack every time i want to use the speakers?
    When you set speakers to 4/4. --> don't you get the output from both (if not --> is there some setting like CMSS you need to use?)?
    Also, there are some software solutions too (like; Foobar --> move stereo to rear channels, BeatPort Player --> you can set output channels freely, etc.), but ....
    jutapa

  • Error message by periodic weekly: No output from the 1 file processed

    Hi there,
    since four weeks, I got a problem with the maintenance script periodic weekly. Up to December 22nd, the script did, what it should do: rebuilding the database of locate and whatis, rotating log-files. Since one week later, I got the error message: No output from the 1 file processed.
    Normally, I use Anacron to do the job. When I noticed the problem, I tried to start the script with Tinker Tool System getting the same result. Another try using the Terminal (sudo periodic weekly) also failed. The commands locate and whatis are working, locate.updatedb and makewhatis also. I'm running 10.4.8; in the past, I did not have such problems. Anyone with an idea or solution?
    Thanks
    Klaus
    MacBook Pro   Mac OS X (10.4.8)  

    Hi Gary,
    here is the output you were asking for:
    Last login: Thu Jan 25 20:03:55 on console
    Welcome to Darwin!
    DeepThought:~ dirk$ sudo /private/etc/periodic/weekly/500.weekly; echo $?
    Password:
    Sorry, try again.
    Password:
    Rebuilding locate database:
    Rebuilding whatis database:
    find: /usr/local/man: No such file or directory
    makewhatis: /usr/share/man/man1/fetchmailconf.1.gz: No such file or directory
    Rotating log files: ftp.log lpr.log mail.log netinfo.log ipfw.log ppp.log secure.log
    access_log error_log
    Running weekly.local:
    Rotating psync log files:/etc/weekly.local: line 17: syntax error near unexpected token `)'
    /etc/weekly.local: line 17: `if [ -f /var/run/syslog.pid ]; then kill -HUP 0 80 79 81 0cat /var/run/syslog.pid | head -1); fi'
    2
    DeepThought:~ dirk$ ls -loe /private/etc/periodic/weekly/500.weekly
    -r-xr-xr-x 1 root wheel - 2532 Jan 13 2006 /private/etc/periodic/weekly/500.weekly
    DeepThought:~ dirk$
    It seems, Rogers idea, PsynX respectively the deficient uninstalling by me is responsible for my problems, is correct. Should I remove the whole file weekly.local or should I only remove the content? I prefer removing the whole file, because it was created while installing PsyncX. The date of creation is the same as the date of installing the app (December 25).
    Klaus
    By the way: it seems to me, the solution of my problem is in sight. So I want to thank you all for the amazing aid I got from you!

  • JDev generated webservices encodes XML output from PL/SQL procedure

    I have a PL/SQL packaged procedure which takes some input parameters and produces one output parameter. The output parameter is of type CLOB and after the procedure has run, it contains a big piece of XML data.
    Using JDeveloper 10.1.3.1, I've published this packaged procedure as a webservice. The generated webservice is fine and works, except for one tiny little issue: the XML that is taken from the output parameter is encoded.
    Here is an example of the SOAP message that the webservice returns:
    <?xml version="1.0" encoding="UTF-8"?>
    <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:ns0="http://gbv0300u/GBV0300U.wsdl/types/"><env:Body><ns0:gbv0300uResponse
    Element><ns0:result><ns0:obvglijstOut> & gt;type>GBV0001& gt ;/type& lt;
    & gt;diensten& lt;
    & gt;dienst>some value& gt;/dienst& lt;
    & gt;/diensten& lt;
    </ns0:obvglijstOut></ns0:result></ns0:gbv0300uResponseElement></env:Body></env:Envelope>
    (I've manually added an extra space between the & and lt; or gt; to make sure a browser will not translate it into a < or >!)
    The contents of the <ns0:obvglijstOut> element are filled with the output parameter from the PL/SQL package.
    How can I change the generated webservice, so the output from the PL/SQL package is used as is instead of being encoded?

    Update: I've tested a bit more by adding some output statements to the java code that JDeveloper generated. I'm now 100% sure the PL/SQL code gives the XML data correctly to the webservice.
    At this moment my guess is that somewhere in the WSDL definition there is something that enables the encoding of the data. But I'm not sure.
    Any help is greatly appreciated.

Maybe you are looking for