[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

7.8

Weird sorting problem. Good question.

Asked by mathieu_cupryk in PL / SQL, Oracle Database, Oracle 10.x

I have the following query that is not sort properly.

No.1 Canada Western Amber Durum Ac                                              
should come after

No.1 Canada Western Amber Durum Ac Strongfield      
Please see attached file.                          

Why does the following oracle statement does not order it properly.

PROCEDURE get_Grades          (cur_out                IN OUT      t_cursor,
                               p_price_list_hdr_id    IN          price_list_dtl.price_list_hdr_id%TYPE,
                               p_status               OUT NOCOPY  varchar2)

-- for the Grade Codes spreadsheet

IS

BEGIN
  p_status := 'Success';
  OPEN cur_out
    FOR
       -- ALL 4 GRAINS
       SELECT C.grade_pool_code, C.grain_class_name, C.grade_protein_pct, B.strght_price_amt - A.old_price_amt delta_price,
              D.strght_code, B.strght_price_amt, D.tough_code, D.damp_code, D.stone_code, D.tough_stone_code, D.damp_stone_code, G.sct_effctv_dtm,
              G.pool_part_code
              FROM   (select E.grade_code_dtl_id, max(e.strght_price_amt) old_price_amt
                             FROM     price_list_dtl E, price_list_hdr F
                             WHERE    F.price_list_hdr_id = F.price_list_hdr_id
                           --  AND      F.price_list_status_type_name = 'Approved'
                           --  AND      F.load_type_name in ('Initial','Adjustment')
                           --  and      e.price_list_hdr_id < p_price_list_hdr_id
                             and      e.price_list_hdr_id = p_price_list_hdr_id
                             GROUP BY e.grade_code_dtl_id) A, price_list_dtl B, grade_code_dtl C, price_list_hdr G,
              (Select grade_code_dtl_id,
                          max(CASE code_type_name when 'STRAIGHT' then disc_code else null end) as  Strght_Code,
                          max(CASE code_type_name when 'TOUGH' then disc_code else null end) as  Tough_Code,
                          max(CASE code_type_name when 'DAMP' then disc_code else null end) as  Damp_Code,
                          max(CASE code_type_name when 'STONE' then disc_code else null end) as  Stone_Code,
                          max(CASE code_type_name when 'TOUGH STONE' then disc_code else null end) as  Tough_Stone_Code,
                          max(CASE code_type_name when 'DAMP STONE' then disc_code else null end) as  Damp_Stone_Code
                          from grade_item
                          group by grade_code_dtl_id) D
              WHERE  B.price_list_hdr_id = p_price_list_hdr_id
              AND    C.grade_code_dtl_id = B.grade_code_dtl_id
              AND    A.grade_code_dtl_id = C.grade_code_dtl_id
              AND    D.grade_code_dtl_id = C.grade_code_dtl_id
              AND    G.price_list_hdr_id = b.price_list_hdr_id
      ORDER BY grade_pool_code,grade_name;
 

  EXCEPTION
    WHEN OTHERS THEN
         p_status := 'Failure: ' || SQLERRM;
END get_Grades;

Attachments:
 
Please look at output.
Please look at output.
 
[+][-]08/26/08 11:05 AM, ID: 22317535Accepted Solution

View this solution now by starting your 30-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

About this solution

Zones: PL / SQL, Oracle Database, Oracle 10.x
Sign Up Now!
Solution Provided By: sdstuber
Participating Experts: 3
Solution Grade: A
 
[+][-]08/25/08 11:49 AM, ID: 22308014Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/08 11:54 AM, ID: 22308059Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/25/08 12:06 PM, ID: 22308157Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/25/08 12:19 PM, ID: 22308270Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/25/08 12:24 PM, ID: 22308304Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/08 12:34 PM, ID: 22308405Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/08 12:36 PM, ID: 22308418Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/08 12:42 PM, ID: 22308497Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/25/08 12:54 PM, ID: 22308619Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/25/08 01:03 PM, ID: 22308709Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/08 01:14 PM, ID: 22308836Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/08 01:22 PM, ID: 22308911Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/25/08 01:23 PM, ID: 22308916Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/08 01:25 PM, ID: 22308937Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/08 04:13 PM, ID: 22310193Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/25/08 05:43 PM, ID: 22310646Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 06:20 AM, ID: 22314273Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/26/08 06:35 AM, ID: 22314434Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 07:18 AM, ID: 22314962Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/26/08 07:21 AM, ID: 22314993Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 07:24 AM, ID: 22315029Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 08:07 AM, ID: 22315595Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/26/08 08:25 AM, ID: 22315822Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/26/08 08:27 AM, ID: 22315851Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 10:54 AM, ID: 22317416Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 11:30 AM, ID: 22317804Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/26/08 11:34 AM, ID: 22317842Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 12:05 PM, ID: 22318206Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/26/08 12:16 PM, ID: 22318322Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 12:27 PM, ID: 22318440Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 12:28 PM, ID: 22318455Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 12:32 PM, ID: 22318499Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 12:36 PM, ID: 22318531Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 12:38 PM, ID: 22318547Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 12:42 PM, ID: 22318591Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 12:46 PM, ID: 22318637Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/08 12:59 PM, ID: 22318763Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091111-EE-VQP-92 / EE_QW_2_20070628