Jump to content

Sql Exfarts Ravali


Recommended Posts

Posted

vuncle .. 1 - tasty , 2 - average , 3 - bokaklaundi .

 

prioritize seyal .. 1 main priority ... lekapothe 2 .. then 2 lekapothe 3 . .. bye1

pmed chusko.. 

  • Replies 61
  • Created
  • Last Reply

Top Posters In This Topic

  • nenu_devudni

    22

  • mettastar

    8

  • 4Vikram

    7

  • andhravodu

    7

Top Posters In This Topic

Posted

select siken,
       mutton,
       keema,
       MIN(goat_curry)
  from (select siken,
               mutton,
               keema,
      CASE WHEN goat = 'Average' then 1
           when goat = 'Tasty' then 2
           when goat = 'Bokkalaundi' then 3
      END goat_curry
       from biskit,cream_biskit, salt_bisket
      where blah = blah
        and bluh = bluh)
     group by siken,
                   mutton,
                   keema;

 

 

esonti query run sesse .. oke record ravali nak matram rendu ossunay .. fix etla seyal seppandi kasta ..

 

Cropped%20Brahmi%20shock.gif?1350345175

 

primary key ento cheppuu.. e scenarios lo distinct records kavali?? specific ga cheppu requirment..

Posted

paina query try cheyi bro

painadi query pani chesinay unclce ... kani combination test chesi septay ... hhj14l.gif?1370039946

Posted

MIN vadite 2 vastunnayi ante, you're getting 2 same values dude. hack solution: inner select lo distinct padeyyi. performance slow avuddi kani, work avuddi

 

never use DISTINCT man.. it is wrong way to use distinct to remove a duplicate in your data.. instead you can use group by to do the same man... if you still think its fine, upto you man...

Posted

give the table structure and a couple of records and ask the output man... it will be much easier that way... this way it is just a guessing game...

Posted

etla unai thatha nu .. pelli petakul lev neku .. epudu aina ma uri ki osse seppa rad .. sandrakala endi dan akkai degara kuda podam .. bye1


Ella 10giru aa maa vorla kenche kotha vorlo vachi thipal padthunai...
Posted

never use DISTINCT man.. it is wrong way to use distinct to remove a duplicate in your data.. instead you can use group by to do the same man... if you still think its fine, upto you man...

 

nenu distinct vadanu man, analytical functions only ikkada. ee babu req meeda clarity lenappudu, inner lo duplicate rows vastunnayemo ani distinct vadamanna. hack solution ani cheppaga appude

Posted

Ella 10giru aa maa vorla kenche kotha vorlo vachi thipal padthunai...

Posted

nenu distinct vadanu man, analytical functions only ikkada. ee babu req meeda clarity lenappudu, inner lo duplicate rows vastunnayemo ani distinct vadamanna. hack solution ani cheppaga appude

 

telisi tappu cheyamani cheppadam tappu man...

Posted

give the table structure and a couple of records and ask the output man... it will be much easier that way... this way it is just a guessing game...

metta vuncle chepinatu  below query worked .. i have tried a couple of ways but this one works just fine .. 

 

with GoatCurry as  (select siken,
               mutton,
               keema,
      CASE WHEN goat = 'Average' then 1
           when goat = 'Tasty' then 2
           when goat = 'Bokkalaundi' then 3
      END goat_curry
       from biskit,cream_biskit, salt_bisket
      where blah = blah
        and bluh = bluh)

select siken,

       mutton,
       keema,
       goat_curry
  from GoatCurry where goat_curry = (select min(goat_curry) from GoatCurry )

Posted

give the table structure and a couple of records and ask the output man... it will be much easier that way... this way it is just a guessing game...

 

akkada vastundi

 

a, b, c, 1

d, e, f, 2
 

he wants a, b, c, 1. min vadite adi vastundi anukunnadu, kani min group chesi, bringing both rows.

 

column 4 lo 1,2 vachinappudu 1 ravali. 2,3 vachinapudu 2 ravali

 

simple answer ga outer query sort chesi, rownum <= 1 petti icha, adi work ayiddi

Posted

telisi tappu cheyamani cheppadam tappu man...

 

ee morality clauses endi adhyaksha? time ki mobile lo gif kooda ledu

Posted

ee morality clauses endi adhyaksha? time ki mobile lo gif kooda ledu

 

naaku coding standards follow avadam istam man, rest I dont care... 

Posted

naaku coding standards follow avadam istam man, rest I dont care... 

idisey uncle bye1 .. standards follow avali ante mundu coding sariga ravali kada amav2.gif?1368598266

Posted

Ella 10giru aa maa vorla kenche kotha vorlo vachi thipal padthunai...

×
×
  • Create New...