1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

  2. Anuncie Aqui ! Entre em contato fdantas@4each.com.br

[SQL] Oracle most repeating value and count

Discussão em 'Outras Linguagens' iniciado por Stack, Agosto 2, 2021.

  1. Stack

    Stack Membro Participativo

    Please could you help how can I create query based on the following source data and result? (primarily without subquery)

    Source data:

    Item | Quantity
    Crankshaft | 200
    Crankshaft | 100
    Crankshaft | 200
    Crankshaft | 50
    Crankshaft | 200
    Gear | 400
    Gear | 200
    Gear | 300
    Gear | 400
    Housing | 120
    Housing | 50
    Housing | 50


    Result:

    Item | Most Frequent Quantity | Count
    Crankshaft | 200 | 3
    Gear | 400 | 2
    Housing | 50 | 2


    Thank you in advance for your help.

    Continue reading...

Compartilhe esta Página