Author |
Message |
Ravanabrahma
Kurra Bewarse Username: Ravanabrahma
Post Number: 878 Registered: 06-2004 Posted From: 24.136.161.233
| Posted on Tuesday, January 16, 2007 - 6:53 pm: | |
|
Thodakottu
Bewarse ke Bewarse! Username: Thodakottu
Post Number: 15500 Registered: 03-2004 Posted From: 69.253.232.56
| Posted on Tuesday, January 16, 2007 - 6:53 pm: | |
antha EP ayaru gaa shshshshhhh.......Hearing is Going On, No Roaring in Between.. |
Ravanabrahma
Kurra Bewarse Username: Ravanabrahma
Post Number: 877 Registered: 06-2004 Posted From: 24.136.161.233
| Posted on Tuesday, January 16, 2007 - 6:18 pm: | |
ne yanks, navvakehe, malla sepparu adigithe. |
Babu
Desanike Pedda Bewarse Username: Babu
Post Number: 10816 Registered: 06-2004 Posted From: 65.208.22.25
| Posted on Tuesday, January 16, 2007 - 6:00 pm: | |
hemu ga |
Gochi
Bewarse ke Bewarse! Username: Gochi
Post Number: 35610 Registered: 07-2004 Posted From: 71.234.246.234
| Posted on Tuesday, January 16, 2007 - 4:20 pm: | |
|
Ravanabrahma
Kurra Bewarse Username: Ravanabrahma
Post Number: 873 Registered: 06-2004 Posted From: 57.68.10.185
| Posted on Tuesday, January 16, 2007 - 4:11 pm: | |
sorry mamalu, edo meeting ki poyicha. requirment complete ga maripoyindi. malla septha kothadi. kiki. Thanks mamalu andariki. |
J2ee
Vooriki Bewarse Username: J2ee
Post Number: 5280 Registered: 08-2004 Posted From: 198.203.175.175
| Posted on Tuesday, January 16, 2007 - 2:57 pm: | |
rendu unique mamalu. sare malla chostha aagandi 1st query if unique the first query should be good enough. check if u r getting multiple records error for the inner query. |
Gochi
Bewarse ke Bewarse! Username: Gochi
Post Number: 35600 Registered: 07-2004 Posted From: 71.234.246.234
| Posted on Tuesday, January 16, 2007 - 2:53 pm: | |
|
420
Pilla Bewarse Username: 420
Post Number: 365 Registered: 12-2006 Posted From: 85.144.114.14
| Posted on Tuesday, January 16, 2007 - 2:52 pm: | |
voreee .. when i started typing . i saw only Hemu's post .. and when posted already thread 20 koteeindee AA = 6 pack and 6 layers of face pack ! |
Beer
Bewarse Username: Beer
Post Number: 2156 Registered: 09-2006 Posted From: 208.204.155.241
| Posted on Tuesday, January 16, 2007 - 2:51 pm: | |
update x x set inv_num = (select inv_num from y y where x.inv_num is null and X.barcode = Y.barcode) Beauty lies in the eye of the beer holder |
Ravanabrahma
Kurra Bewarse Username: Ravanabrahma
Post Number: 872 Registered: 06-2004 Posted From: 57.68.10.185
| Posted on Tuesday, January 16, 2007 - 2:51 pm: | |
rendu unique mamalu. sare malla chostha aagandi 1st query |
420
Pilla Bewarse Username: 420
Post Number: 364 Registered: 12-2006 Posted From: 85.144.114.14
| Posted on Tuesday, January 16, 2007 - 2:50 pm: | |
UPDATE x set inv_num = (Select Y.INV_NUM from Y where Y.barcode= x.barcode) where x.inv_num is null ; I hope inner select does not return multiple rows .. hoping barcode is unique AA = 6 pack and 6 layers of face pack ! |
Rediff
Desanike Pedda Bewarse Username: Rediff
Post Number: 6278 Registered: 03-2004 Posted From: 151.151.21.101
| Posted on Tuesday, January 16, 2007 - 2:50 pm: | |
>>if the barcode is unique in both the tables first query will work if not write a pl/sql procedure yeah .. |
J2ee
Vooriki Bewarse Username: J2ee
Post Number: 5279 Registered: 08-2004 Posted From: 198.203.175.175
| Posted on Tuesday, January 16, 2007 - 2:50 pm: | |
inv num cannot be primary key as it has nulls so i think barcode must be unique and primary key |
Rediff
Desanike Pedda Bewarse Username: Rediff
Post Number: 6277 Registered: 03-2004 Posted From: 151.151.21.101
| Posted on Tuesday, January 16, 2007 - 2:49 pm: | |
>>inv_num + barcode Idi unique aa rendu tables lo .. nullability enti ee columns .. aa details ivvu
quote:create table X ( inv_num number(10), barcode number(10)); create table Y ( inv_num number(10), barcode number(10)); commit; insert into X values (NULL, 10); insert into X values (NULL, 11); insert into X values (100, 12); insert into X values (200, 13); commit; insert into y values (21, 10); insert into y values (22, 11); insert into y values (100, 12); insert into y values (200, 13); commit; UPDATE x SET x.inv_num = (SELECT y.inv_num FROM y WHERE x.barcode = y.barcode) WHERE x.inv_num IS NULL select * from x;
idi test chesaa nenu |
J2ee
Vooriki Bewarse Username: J2ee
Post Number: 5278 Registered: 08-2004 Posted From: 198.203.175.175
| Posted on Tuesday, January 16, 2007 - 2:48 pm: | |
if the barcode is unique in both the tables first query will work if not write a pl/sql procedure |
Rediff
Desanike Pedda Bewarse Username: Rediff
Post Number: 6276 Registered: 03-2004 Posted From: 151.151.21.101
| Posted on Tuesday, January 16, 2007 - 2:48 pm: | |
inv_num + barcode combination unique ayite in both tables .. first query work avuthundi .. ippude test chesaa |
Ravanabrahma
Kurra Bewarse Username: Ravanabrahma
Post Number: 871 Registered: 06-2004 Posted From: 57.68.10.185
| Posted on Tuesday, January 16, 2007 - 2:45 pm: | |
|
Chonga
Vooriki Bewarse Username: Chonga
Post Number: 2805 Registered: 12-2004 Posted From: 71.85.144.192
| Posted on Tuesday, January 16, 2007 - 2:45 pm: | |
>>oops .. rendoo banda boothulu
|
Ravanabrahma
Kurra Bewarse Username: Ravanabrahma
Post Number: 870 Registered: 06-2004 Posted From: 57.68.10.185
| Posted on Tuesday, January 16, 2007 - 2:45 pm: | |
1st di error vasthundi mama. 2nd di try chestha aagu mama. is null anakunda = ' ' anali mama appudu aa select multiple rows isthundi. so left side oke value assign chesthundi. so error vasthundi mama. 2nd di try chestha. |
Rediff
Desanike Pedda Bewarse Username: Rediff
Post Number: 6275 Registered: 03-2004 Posted From: 151.151.73.163
| Posted on Tuesday, January 16, 2007 - 2:43 pm: | |
oops .. rendoo banda boothulu |
Rediff
Desanike Pedda Bewarse Username: Rediff
Post Number: 6274 Registered: 03-2004 Posted From: 151.151.73.163
| Posted on Tuesday, January 16, 2007 - 2:42 pm: | |
idi try chey .. UPDATE x SET x.inv_num = (SELECT y.inv_num FROM y WHERE x.barcode = y.barcode) WHERE x.inv_num IS NULL ----OR idi -------- UPDATE x SET x.inv_num = (SELECT y.inv_num FROM y WHERE x.barcode = y.barcode) WHERE x.inv_num IS NULL AND x.barcode IN (SELECT x1.barcode FROM x x1, y y1 WHERE x1.inv_num IS NULL AND x1.barcode = y1.barcode) |
Ravanabrahma
Kurra Bewarse Username: Ravanabrahma
Post Number: 869 Registered: 06-2004 Posted From: 57.68.10.185
| Posted on Tuesday, January 16, 2007 - 2:23 pm: | |
mamalu, ippudu idi paristhithi naa daggara 2 tables unnayi. X, Y tables. renditlo common inv_num and barcode. aithe nenu X table lo unna inv_num ni update cheyyli with Y table inv_num if X table inv_num NULL ayithe and X.barcode = Y.barcode ayithe query ela rayali?? |