Re: [sqlite] Math Update with two tables

2008-12-23 Thread Igor Tandetnik
"Dusan Gibarac" wrote in message news:4951940f@cbsits.com > There are tables t1( f11, f12) and table t2(f21, f22) and one > has to update field t1.f12 with values t2.f22 where t1.f11 = t2.f21. update t1 set f12 = (select f22 from t2 where f11 = f21); Igor Tandetnik

Re: [sqlite] Math Update with two tables

2008-12-23 Thread Dusan Gibarac
There are tables t1( f11, f12) and table t2(f21, f22) and one has to update field t1.f12 with values t2.f22 where t1.f11 = t2.f21. Mysql sample: 1. UPDATE t1, t2 2. SET t1.f12 = t2.f22 3. WHERE t1.f11 = t2.f21 He needs SQLite syntax. Dusan. Igor Tandetnik wrote: >

Re: [sqlite] Math Update with two tables

2008-12-23 Thread Igor Tandetnik
Dusan Gibarac wrote: > Igor Tandetnik wrote: >> "aj" wrote in >> message >> news:95d3c7350812201131l1cd87998k55595f77fecc0...@mail.gmail.com >> >>> UPDATE Records,Table2 >>> SET Factors= (Factors * Potential Table2.Field23) >>> >> >> This last

Re: [sqlite] Math Update with two tables

2008-12-23 Thread Dusan Gibarac
He wants to update table Records using data from table Table2. Dusan. Igor Tandetnik wrote: > "aj" wrote in > message > news:95d3c7350812201131l1cd87998k55595f77fecc0...@mail.gmail.com > >> I would like to use math with more then one table, for example >> I know how

Re: [sqlite] confusing with how to to this in sqlite

2008-12-23 Thread Simon Davies
2008/12/23 Rachmat Febfauza : > = > > thanks to Simon. it works. but i have some question. i hope u can help me > to explain these : > > 1. is it necessary or not to specify min(awal1.begin). No. "Begin" is part of the 'group by' clause. Each distinct

Re: [sqlite] UPDATE a ROW based on an UPDATE of a different ROW

2008-12-23 Thread jose isaias cabrera
"Igor Tandetnik" wrote... >> As you can see, this UPDATE, >> >> UPDATE foo SET bdate = (SELECT f2.edate FROM foo f1 JOIN foo >> f2 ON f1.PID = f2.PID AND f1.lang = f2.lang WHERE f1.job = 'val' AND >> f2.job = 'trans' AND f1.id = foo.id AND f1.bdate < f2.edate) >> WHERE foo.job = 'val'; >> >>

Re: [sqlite] INVALID COMMAND NAME sqlite3_soft_heap_limit

2008-12-23 Thread mkrajachandru
Hello All, Thank U V V V much Dan & Shane Harrelson ... Its working fine So we are going for a party I am inviting u guys also for the party. Thanks and regards Chandru On Tue, Dec 23, 2008 at 10:24 AM, Shane Harrelson