Order by Not working in Group by Above

I m using this query in SQL (TOAD) it is working fine
and also when I create report in Tabular it also work accordingly,
I have DOC_NO varchar2(10)
and store data in 1 ...50 record like serial no.
but when I create report with GROUP ABOVE data not sorting ?
select a.doc_no,a.v_name,a.loa,a.beam,a.dwt,a.bert_date,a.sale_date,a.total_hours,a.sh_name,a.s_name,a.bl_qty,
        b.p_name,b.r_name,b.rec_qty 
from cargo_handle a, sub_cargo_handle b
where a.doc_no = b.doc_no
and a.bert_date between :dd1 and :dd2
order by to_number(a.doc_no)

The ordering in groups is controlled by the Break Order property. You cannot use order by in your query. See the online help:
The order of column values in a default group is determined by the ORDER BY clause of the query for SQL queries and by the sort column for Express queries. For column values in user-created groups, however, you must use Break Order to specify how to order the break column's values.

Similar Messages

  • Layout Options - Page Order Does Not Work Correctly

    I have a Photosmart C7280 All-in-One printer.  The Layout Option - Page Order does not work as expected.  The User Guide (page 95) states that the default for a multiple page document is to print first page first.  The manual states that to print last page first requires one to change the Page Order to "Back to Front".  For my Excel, Word, Internet Explorer and PDF pages, I need to leave the Page Order as "Front to Back" if I want the last page to print first.  This makes no sense.  In addition, I can't get my Quicken reports to print last page first no matter what I try.  Does anyone no why the Page Order does not work as expected for Excel, Word, IE and PDF, and does not work at all for Quicken?

    Keisha,
    If you uncheck the "show" option, then the corresponding HTML for that item is not rendered on the page. Thus, when you try to inspect that item via APEX_APPLICATION.G_F02, it simply doesn't exist.
    One trick that I use when I want to have hidden items on the page, but not make them take up any space, is to concatenate them to items that will be visible.
    Using your query as an example, I would re-write it like this:
    SELECT APEX_ITEM.CHECKBOX(1,ROWNUM,'CHECKED')ATTENDED,
    APEX_ITEM.HIDDEN(2,C.PARTY_ID)
      || APEX_ITEM.HIDDEN(3,C.PARTY_TYPE_CODE)
      || C.PARTY_TYPE_CODE PARTY_TYPE_CODE,
    S.PERSON_ID,
    S.PERSON_FIRST_NAME AS NAME,
    C.PARTY_CASE_ID
    FROM CASE.PARTY C
    INNER JOIN DN.PERSON S
    ON C.PARTY_ID = S.PERSON_ID
    WHERE C.PARTY_CASE_ID = :P18_CDBCASE_ID
    AND C.PARTY_SEQ_NO = :P18_SEQThus, the second APEX report column will contain the HTML for the hidden items PARTY_ID & PARTY_TYPE_CODE, as well as the value for PARTY_TYPE_CODE. When you submit the page, you should not encounter any issues.
    Thanks,
    - Scott -
    http://sumnertechnologies.com/
    http://spendolini.blogspot.com/

  • CFQUERYPARAM tag not working in GROUP BY clause

    I am getting an error whenever I put a CFQUERYPARAM tag in a
    GROUP BY clause. I saw on another message board someone was having
    a similar problem with the ORDER BY clause
    Here is a sample of what my code might look like
    select x, y, z from abc
    group by <cfqueryparam value="x"
    cfsqltype="cf_sql_float">
    Here is the error I receive.
    Error Executing Database Query.
    [Macromedia][Oracle JDBC Driver][Oracle]ORA-00979: not a
    GROUP BY expression
    Any insight?

    The cachedwithin and cachedafter functions store the query
    results in the server's RAM. That means, while it's cached,
    whenever you run it, you get the cached result instead of going to
    the database to run it again. This increases speed of course, but
    if the data changes during the cache period, you have accuracy
    problems.
    It does not create memory issues. In the administrator you
    reserve a certain amount of memory for query caching. If you exceed
    that amount, the last query in pushes the first query out, or
    something like that.
    With regards to what you are trying to do about binding
    variables in your group by clause, that's not what cfqueryparam was
    designed for. It was designed for
    where clauses (where this = <cfqueryparam etc>
    or insert queries (insert into my table (field) values
    (<cfqueryparam>
    and things like that.
    You are trying to use it for something other than what it was
    designed for, which explains why it's not working for you.

  • Quick swipe not working on grouped tracks

    I've grouped two tracks together and in the group settings box I've checked 'Edit'. However when I swipe one track the other doesn't mirror it. I've always done this with drum tracks but can't figure why it's suddenly not working.

    I haven't had this happen in a while, but Logic's group feature used to work intermittently for me at times.
    If you haven't already, set up a key command for "group clutch". This will allow you to turn the grouping feature on and off. Try toggling it on and off a few times. That used to "wake it up" for me, when abnormalities like what you're experiencing occurred.
    You could also literally disable the groups on those tracks, and then re-enable them, or assign them to a different group altogether.
    I found the above solutions to always fix the weirdness when it happened. See if that helps...

  • Target Load order is not working properly in 11.2.0.2

    Hi,
    Mappings whihc are migrated from OWB10.2 version to 11.2 which contains multiple targets are not working in accordance with the target load order given in the mapping.
    The order in which targets are loaded changes between execution.
    To test is this a problem with migration we had created a smaple mapping containg 3 targets and mentioned loading order in each target table as well as in mapping property.
    The order in which the targets are loaded was random. But when we have 2 targets it seems to be working. But for migrated maps this is also not working.
    Is there any bug reported in 11.2.0.2 for this issue? Any help is highly appreciated.
    Thanks and Regards,
    Pnreddy

    Target load ordering is set to false by default in 11.2.
    You need to set it to true if you want your mapping to use it.

  • Printing an iframe with pdf using javascript is not working in IE8 and above

    I have a problem with printing and Iframe with PDF in IE 8 and above
    Following is my javascript:
    var urlValue="";//Path of the file to be printed
    var div = document.getElementById("printerDiv");
    div.innerHTML = '<iframe src="' + urlValue + '" id="frame" name="frame" style="width:100%;height:100%;"></iframe>';
    frame.focus();
    frame.print();
    This same thing is working fine in other browser but for IE is just not invoking the print dialog.
    Also I tried to get the frame.print(); on load of the frame but even that is not working exactly as that way it print the parent window in output.
    Few things I tried like:
    1) div.innerHTML = '<iframe src="' + urlValue + '"
    onload="this.contentWindow.print();"></iframe>';
    2) frame.contentWindow.focus();
    frame.contentWindow.print();
    3) window.document.getElementsByTagName('iframe')['frame'].onload = (function () {
    frame.focus();
    frame.print();
    I need to get the print of only the content which is in Iframe which I am binding in "printerDiv" by javascript.
    Any perfect/different solution from which I have tried then please post here?
    Thanks.

    PDF documents are hosted in an ActiveX or netscape plugin control which have their own printing functions.
    Start>Adobe Reader>Edit>Preferences - to adjust what functionality the PDF document viewer addon displays (menus etc).
    Tools>Manage Addons>Show all addons
    make sure you have both the x86 and x64 versions of your PDF reader Active X control installed and enabled. I would recommend also that you update to the latest version of the vendors' (Adobe?) plugin.
    Possibly you have disabled scripting of ActiveX controls in the IE security zone that your parent page maps to. Also there is an IE security zone feature that prevents navigation to a domain in a zone of lower integrity.
    Tools>Internet Options>Security tab, click "Reset all zones to default".
    when asking developer related questions it is helpful if you can include a link to your website.
    Rob^_^

  • New settlement parameters  in   sales order  does not  work

    Hi
    I have a    sales order for  service material.    It is invoiced.    I  have to settle it.    The  existing  settlement rule  is  wrong. So  I have created a new allocation structure and   changed   settlement  parameter  in     the  sales order.   I save the  sales order.
    But in VA88 the settlement does not work. I get error message ' receiver cost element not defined and thet cat. PSG not defined.'
    But the same allocation structure work good for new sales order.
    Pl advise how  I  can  do the settlement for  old   sales orders,  subsequently changed for  settlement parameter ie allocation structure. 
    Thanks
    kamala

    Hello Kamala
    Not an expert on this subject, but here is what I suggest, Try and see if it works.
    1) Firstly retract the changes you did in sales order and settle first with the wrong settlement parameter (Old data).
    2) Now change the existing allocation structure, don't create NEW ONE. If you change an allocation structure, the changes only affect future settlements.
    3) Then reverse the settlement.
    4) Now re-do the settlement.
    Let me know how it goes. Take care.

  • Sort Order Column not Working

    I have set a sort order column on one of A VARCHAR field, but the functionality is not working. The sorting is enabled in the table view and when I sort by the said column it still sorts based on the VARCHAR values of the column instead of the other INT column I want to sort by. The logical SQL and physical query never even includes the column to sort. Are there any exceptions for the 'Sort Order Column' setting? Is there a config setting or data connections setting that I need to check to make this work?
    Thank You!
    Edited by: VNC on Oct 3, 2011 9:08 AM

    hi,
    can you give me more detailes like some sample column data like below kind
    Like Ex: varchar month column it sould display based on month id
    month : Fev-2011,Dec-2011,jan-2011 and month id 1 to 12
    set your month id as sort order column of month name.
    double click month name ->In general tab set the sort order column as month id
    FYI...see the sample link
    http://www.biconsultinggroup.com/obiee-tips-and-tricks/setting-a-sort-order-column.html
    i hope helped you
    THanks
    Deva
    Edited by: Devarasu on Oct 4, 2011 12:39 AM

  • Hints FIRST_ROWS and order by not working together

    Hi,
    We are facing an issue like we are using hint FIRST_ROWS with a query which have a order by clause, if we are giving both together
    it is not working and if we remove either order by or hint it is working
    SELECT /*+FIRST_ROWS*/ * FROM (SELECT MYROWS.*,
    ROWNUM RN FROM (SELECT * FROM V_REPORT WHERE START_DATE &gt; '22-SEP-04'
    AND END_DATE &lt; '22-SEP-08' AND
    (GEO_ID in (select GEO_ID from loc where anc = 0))
    ORDER BY
    ENTITY,OPERATION,NAME
    MYROWS)
    A simliar query from other view is working fine.
    Please help me on the same.

    David_Aldridge wrote:
    Solomon Yakobson wrote:
    Well, ORDER BY implies all rows must be fetched first and then ordered. So yes, FIRST_ROWS does not make much sense in that situation, does it?.
    SY.Not in every case -- sometimes an index can be used by the optimizer to returen rows in the correct order without having identified the entire result set.
    FIRST_ROWS is deprecated in favour of FIRST_ROWS(n), by the way. http://download.oracle.com/docs/cd/B19306_01/server.102/b14223/usingpe.htm#i1009413
    And even if the result set needs to be ordered and no index can be used to avoid the sort operation Oracle offers for "top n" and "pagination" queries the "ORDER BY STOPKEY" optimization which only keeps the top n rows to sort (probably in memory if n is small enough) and eliminates the remaining ones which can make a huge difference if the volume to sort is large.
    I've written a note about issues like that recently.
    Regards,
    Randolf
    Oracle related stuff blog:
    http://oracle-randolf.blogspot.com/
    SQLTools++ for Oracle (Open source Oracle GUI for Windows):
    http://www.sqltools-plusplus.org:7676/
    http://sourceforge.net/projects/sqlt-pp/

  • Mobile sync not working for groups

    Hello guys,
       i've been playing with Mavericks Server and so far everything is working smoothly except for the mobility sync...
    i successfully created a Local Network Account and was able to successfully sync it to the Server using AFP and a specific folder...
    This is working awesome, but here comes the issue:
    i setup another Local Network Account and assigned it to a Group and used Workgroup Manager (on the same server) to setup the mobility sync for the group...
    Now, when i try to login, the mobile profile gets created on the computer but does not sync to the server, it syncs locally instead or i get the error "The sync could not complete because your network home at "(null)" does not allow writing...
    if i try Profile Manager websiteit does not work either...
    i know this works for a single user, but if i want to sync it using groups it fails....
    I've tried finding a possible answer and so far nothing...
    Im using OS X Server 3.1.2 and Workgroup Manager 10.9 (421)
    Can you please help me out?
    Thanks in advance...

    Anyone?

  • Help, my tab order will not work? Tried to troubleshoot, no luck!

    I created a form used the manual tab order and it would not work. I adjusted the hierarchy and erased all the traversal's in the XML. The tabbing order is now automatic but still out of order pretty badly. Can someone please guide me in the right direction. I really want this form to be over with.

    Hope you considered following point.....When you set the Tab order you set the order starting 1 to n with in each subform. Setting taborder across the subforms is not an option at least in LC 7 and 8. However there is workaround for this, using setFocus() method.... look more in the help.
    Example: xfa.host.setFocus("xfa.form.form1.TextField1");
    If you still have difficulty attach a copy of your template and explain in detail what you try to do.

  • Anchor links in HTML newsletters not working in iOS8 and above

    I used to receive daily HTML email newsletters with links anchor down to detailed content. The links were working fine in all the previous versions. After upgrading to iOS 8, the internal hyperlinks (anchor links - both named as well as id) are not working. It takes me to nowhere and shows an error message id. This seems to be very specific with iOS 8 and there is no HTML code support to overcome this issue.
    Can Apple fix this issue at the earliest as it is very difficult to scroll up and down every time to read the contents of the email newletters?

    I used to receive daily HTML email newsletters with links anchor down to detailed content. The links were working fine in all the previous versions. After upgrading to iOS 8, the internal hyperlinks (anchor links - both named as well as id) are not working. It takes me to nowhere and shows an error message id. This seems to be very specific with iOS 8 and there is no HTML code support to overcome this issue.
    Can Apple fix this issue at the earliest as it is very difficult to scroll up and down every time to read the contents of the email newletters?

  • Change in an LOV query of Sales Order Form not working

    Hi,
    I wish to change the the Order Type (in the Sales Header) displayed in the Sales Order Form when viewed from a particular Responsibility.(11i Instance)
    To be specific only certain order types should be displayed in the LOV when the User tries to create Order from that Responsibility.
    In that process I created an FP with Action --> Builtin -->Create Record Group From Query
    Then in Property-->Object Type-->LOV and Target Object -->ORDER_TYPE Value-->Name of my Query Group
    I downloaded the Sales Order Form and modified the Query of the Group keeping the columns selected and the view used same and added in the Group I created.
    But it didn't work out.
    I tried out by changing my Target Object to SRV_ORDER_TYPE and its corresponding query from the Oracle Form.
    But still it didn't work.
    Please tell me where I'm going wrong.
    Am I not choosing the correct target record group LOV?

    Hi Robert,
    I have successfully accessed a matrix using Visual Basic .Net. It has been quite a challenge while I was at it.
    One important thing to understand is that (unless you access the datasource) in order to access a particular control in a matrix object, this control needs to be visible and enabled. It is like simulating a user accessing the matrix via GUI... if a control is not enabled, you cannot access it (as said via control). That might explain question 1.
    Short sample on matrix handling is here:
    http://www.itwiki.net/ow.asp?SboHowToReadFromAndWriteIntoMatrix
    <b>Q2 - Cell count:</b>
    I have personally never used the Cells count method. It should always return the number of rows. My only guess here is that you are using an old reference on the matrix object in which the rows are not there yet.
    Dim oMatrix As SAPbouiCOM.Matrix
    Dim oColumn As SAPbouiCOM.Column
    Dim oEditText as SAPbouiCOM.EditText
      oMatrix=YourSboForm.Items.Item(38).Specific
      oColumn=oMatrix.columns.item(strColumnname).specific
      oEditText=oColumn.items.Item(1).specific
      Msgbox(oEditText.String)
    The above code should get you the first cell of the first row of the given matrix.
    HTH Lutz Morrien
    P.S.: If you need any more sample code, check with the SAP matrix sample or send me a mail (adress see Http://www.itwiki.net)

  • Custom IKM Knowledge Modules are not working with Group By Clause

    Hi All,
       I am facing an issue with custom IKM knowledge modules. Those are IKM Sql Incremental Update and IKM Sql Control Append.
    My Scenario is
    1. Created an interface with table on source and temporary datastore with some columns in target.
    2. In the Interface on the target i defined one column as UD1 and other column as UD2  for which group by to be implemented .
    3. Customized  IKM Sql Incremental Update  with " Group by " by making  modification in my IKM Sql Incremental Update
    detail step "Insert flow into I$ table"  i.e., i replaced like this whereever i find this <%=odiRef.getGrpBy()%> API
    Group By
    <%=snpRef.getColList("","[EXPRESSION]","","","UD1")%>,
    <%=snpRef.getColList("","[EXPRESSION]","","","UD2")%>
    Up to UD5.
    . Here in the place of [EXPRESSION] i passed column names for UD1 similarly other column name for [EXPRESSION] of UD2.
    4.Made all the proper mappings and also selected the KM's needed for that interface like CKM Sql ,IKM Sql Incremental Update.
    5. Executed the Interface with global context.
    Error i am getting in this case is :
    Caused By: java.sql.SQLSyntaxErrorException: ORA-00979: not a GROUP BY expression
      at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:462)
      at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:405)
      at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:931)
      at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:481)
      at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:205)
      at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:548)
      at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:217)
      at oracle.jdbc.driver.T4CPreparedStatement.executeForRows(T4CPreparedStatement.java:1115)
    Here the columns in the select clause are there in Group By also.
    I did the same scenario using IKM Sql to file append .In that case i am able to do it. But not with the above mentioned KM's. Please let me know if any one know it or tried with this, as it is
    high priority for me.
    Please help me out.
    Thanks,
    keerthi

    Hi Keerthi,
    If your are transfering data from Oracle to Oracle (I means source is oracle Db and target is also oracle DB) then use below KM's and group by will come automatically based on the key values you selected on interface target datastore
    1) CKM Oracle
    2) LKM Oracle to Oracle (DBLINK)
    3) IKM Oracle Incremental Update (MERGE)
    Hope this will helps to resolve your issue
    Regards,
    Phanikanth

  • Order Recommendations not working until run MRP Wizard?

    Hi,
    I have created a scenario using the MRP wizard. However, I find that after a new sales order is created, the items do not appear in the "order recommendations" until I re-run the mrp wizard through the scenario that I had already saved.
    Is this normal?
    Also, in order recommendations screen to create the purchase orders, it shows me all the items with a "create" tick box next to them. Each day we order hundreds of products and the issue for us here is
    1. The items are not grouped by supplier
    2. There is no select all box
    Is it possible to get the items grouped? Ideally would be Supplier which would drill down to the items.
    Edited by: Ricky Thomas on Mar 14, 2011 5:00 PM

    Hello Ricky - yes, that is normal that you must re-run the MRP wizard if new sales orders are created since you first ran the MRP.  Usual system processing...
    Regards - Zal

Maybe you are looking for

  • Help with an urgent application please

    algier please recommend me I need a web application that meets the characteristics of a forum system and database must be Oracle 10g or 11g I hope I'll be able to help many grasias pendiende and those who can help me

  • B&W Macbook startup problem - no solution suggested in forums has worked

    Hi there, I encountered a problem using Word on my white Macbook yesterday, so restarted (by selecting the 'restart' option from the apple menu) to try to fix it. It would not restart: it showed a white screen with the apple sign for ages, followed b

  • Compiler error  type of object in for (Class obj : Items) - why?

    Hi all, I'm new to Java generics and am in the process of converting some legacy code. I have encountered a particular error which I do not understand the reason for, since I think the compiler has enough information about the code to work out type i

  • How to Use Switch Statement with Exclusion Group (radio buttons)?

    Wouldn't you know, just when I though I'd really be making progress, I've come across another problem I can't solve. In a homeowners insurance application I am building, there is an exclusion group that needs to set the value of several variables I h

  • How to get soap message sent out

    Hi, I used a client proxy in ABAP to consume a web service. However I got errors saying there is 'Unexpected elemement' in SOAP message. To find out the root cause, i would like to get the soap message sent out from the proxy. Is there any way to do