Jump to content

Database Side Pani Chese Vaallu Itu Randi Vayya..urgent Help Kaavali


Recommended Posts

Posted

All Miyyas

Naa daggara 3 tables unnayi

Table1 and Table 2 ni join chesi oka result set teesukostunna...

ippudu aa result set ni Table 3 lo unna dates tho compare cheyyali...

Result set lo customer_ids untaayi.. Table 3 lo customer_ids untaayi...also oka date column undi table 3 lo (ee dates puraathana kaalam nundi future kaalam varaku untaayi)

naa question entante nenu result set ni table 3 tho ye join cheyyali to pull only active customers..

  • Replies 38
  • Created
  • Last Reply

Top Posters In This Topic

  • deals2buy

    15

  • Terminator II

    3

  • ARYA

    3

  • Desamudhuru

    3

Popular Days

Top Posters In This Topic

Posted

[quote name='iTeachSAP' timestamp='1352309547' post='1302758324']
table structure veyi ikkada
[/quote]

which table structure?

Table 3 structure ila untundi

ID
Name
Manufacture_Date
Expiration_Date



Result Set lo only Customer_ID ni pull chestunna

Posted

[quote name='padmasri123' timestamp='1352309970' post='1302758396']
Active customers ee basis meeda cheptav..
[/quote]

Table 3 lo unna Expiration_Date base cheskoni mama.. I mean vallu ivaala date kante ekkuva unte vaallu active ani chepta

Posted

[quote name='deals2buy' timestamp='1352310094' post='1302758416']

Table 3 lo unna Expiration_Date base cheskoni mama.. I mean vallu ivaala date kante ekkuva unte vaallu active ani chepta
[/quote]

Result set query and table 3 join chesi condition pettu

Posted

[quote name='eela' timestamp='1352310251' post='1302758434']

Result set query and table 3 join chesi condition pettu
[/quote]

aa join ey what kind of join (inner, left, right, outer) ani asking vayya [img]https://lh5.googleusercontent.com/--1eXCwfWU4o/Taogt3bzcfI/AAAAAAAACvo/z8k9Ehdgrtg/s140/Bemmi-7.gif[/img]

Posted

[quote name='deals2buy' timestamp='1352310380' post='1302758446']

aa join ey what kind of join (inner, left, right, outer) ani asking vayya [img]https://lh5.googleusercontent.com/--1eXCwfWU4o/Taogt3bzcfI/AAAAAAAACvo/z8k9Ehdgrtg/s140/Bemmi-7.gif[/img]
[/quote]

normal

Posted

[quote name='kevkekaa' timestamp='1352310524' post='1302758461']

normal
[/quote]
u mean equi join?

Posted

u mean first Table 3 lo vuna active members ni thisukoni valla customer_id tho result table ni compare chesi ....... Validate iyina vallavi kavala ??

Posted

[quote name='Desamudhuru' timestamp='1352310627' post='1302758477']
u mean first Table 3 lo vuna active members ni thisukoni valla customer_id tho result table ni compare chesi ....... Validate iyina vallavi kavala ??
[/quote]
Yes

Posted

[quote name='deals2buy' timestamp='1352310549' post='1302758464']
u mean equi join?
[/quote]

only active members ni pull cheyyali annav kada.. so inner join vadali anukunta.. ideal ga nee table 3 lo motham dataset vundali.. so inner join on table 3 should be ok.. but let others also conpirm

Posted

[quote name='deals2buy' timestamp='1352310380' post='1302758446']

aa join ey what kind of join (inner, left, right, outer) ani asking vayya [img]https://lh5.googleusercontent.com/--1eXCwfWU4o/Taogt3bzcfI/AAAAAAAACvo/z8k9Ehdgrtg/s140/Bemmi-7.gif[/img]
[/quote]
inner join

Posted

baaa its my opinion tho chepthuna correct kaka pothe i'm sorry

select * from resulttable
where customer_id =
(
select customer_id from table3 where Date >= @date
)



ela try cheyi coding lo nenu anta perfect kadu so niku emaina logic help ithadi ani vesanu

Posted

select table3.datecol from table, table2, table3
where table1.col = table2.col
and table2.colcol = table2.colcol


col is the common column in table1 and table 2
colcol is the common column in table2 and table 3

×
×
  • Create New...