> -Original Message-
> From: Ravi Kumar. [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, April 11, 2007 7:23 AM
> To: mysql@lists.mysql.com
> Subject: Join & update help
>
> Dear All,
>
> I have two tables T1 and T2.
>
> T1 has these columns: userid, passwo
Dear All,
I have two tables T1 and T2.
T1 has these columns: userid, password (userid is primary key)
T2 has these columns: sessionid, userid, logintime, logofftime
(sessionid is primary key)
I wish to add one column in T1 called last_login_time.
I want to populate this new column with max(
Hello.
Perhaps you have forgotten to add col_name=expr to the end of your
query. See:
http://dev.mysql.com/doc/refman/5.0/en/insert.html
Jonathan Mangin wrote:
> I'm trying to change a couple of replace statements to
> insert...on duplicate key update (using Perl/DBI).
>
> foreach my $key (k
I'm trying to change a couple of replace statements to
insert...on duplicate key update (using Perl/DBI).
foreach my $key (keys %e_items) {
my $sql = "insert table1
(id, date, time, uid, type, seq, value)
values
(?, ?, ?, ?, ?, ?, ?)
on du
Brendan Gogarty wrote:
> We are running mysql 3.23.58 and I want to do a query with joins >
from two tables and then insert the results into the column of a third.
[snip]
Shawn Green wrote:
> Start from here:
> http://dev.mysql.com/doc/mysql/en/update.html
>
> Updates *are* allowed to use J
Multi Table UPDATES are first supported in 4.0.x
-Original Message-
From: Brendan Gogarty [mailto:[EMAIL PROTECTED]
Sent: Tuesday, August 09, 2005 12:16 PM
To: [EMAIL PROTECTED]
Cc: mysql@lists.mysql.com
Subject: RE: JOIN QUERY -> UPDATE ... help?!
"Brendan Gogarty" <
Brendan Gogarty wrote:
> We are running mysql 3.23.58 and I want to do a query with joins
> from two tables and then insert the results into the column of a third.
Shawn Green wrote:
Start from here:
http://dev.mysql.com/doc/mysql/en/update.html
Updates *are* allowed to use JOINED tables a
"Brendan Gogarty" <[EMAIL PROTECTED]> wrote on 08/09/2005
05:30:51 AM:
> Hi,
> We are running mysql 3.23.58 and I want to do a query with joins
> from two tables and then insert the
> results into the column of a third. This appears to be harder than I
> realised with this version of mysql a
"Brendan Gogarty" <[EMAIL PROTECTED]> wrote on 08/09/2005
05:30:51 AM:
> Hi,
> We are running mysql 3.23.58 and I want to do a query with joins
> from two tables and then insert the
> results into the column of a third. This appears to be harder than I
> realised with this version of mysql a
Hi,
We are running mysql 3.23.58 and I want to do a query with joins
from two tables and then insert the
results into the column of a third. This appears to be harder than I
realised with this version of mysql and I am banging my head against a
wall. Please Help!
ok first query.
--
Check the REPLACE command...
http://www.mysql.com/doc/en/REPLACE.html
I think it suits your problem...
On Mon, 2003-01-20 at 08:14, Michael Watson wrote:
> This may be very simple, but the solution eludes me..
>
> I have two tables Products and NewProducts, The Products table contains a
> list
This may be very simple, but the solution eludes me..
I have two tables Products and NewProducts, The Products table contains a
list of all the current product line and prices Products.ProdCode,
Products.Price (amongst other details not relevent here). NewProducts
contains a list of changes to
You might want to try actually running the query.
mysql_query ($query);
or
mysql_query ($query,$db);
depending on your preference.
-Original Message-
From: Beauford [mailto:beauford.2003@;rogers.com]
Sent: Thursday, November 14, 2002 1:53 PM
To: [EMAIL PROTECTED]
Subject: Update help
Hi
Hi,
I'm trying to update a table from my webpage but not having much luck,
although it works from the command line. Obviously I am missing
something and would appreciate any help.
Also. Is there a good tutorial or help page for Mysql. I find the one at
www.mysql.com not very helpful.
TIA
The co
Steven,
Tuesday, September 24, 2002, 7:03:15 PM, you wrote:
SK> I am currently working on a table that has a column called state and a
SK> column called stateid. All 42,000 records in this table have a 2 Letter
SK> abbreviation for that state (NY, CA, NV, etc) however. To eliminate
SK> redunda
Greetings,
I am currently working on a table that has a column called state and a
column called stateid. All 42,000 records in this table have a 2 Letter
abbreviation for that state (NY, CA, NV, etc) however. To eliminate
redundancy, I have move the states to another table that contains an
AU
What happens if you put third TIMESTAMP column.?. Will that be
updated?. Just curios.
Nilesh
-Original Message-
From: Paul DuBois [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, July 03, 2002 12:42 PM
To: Paul Tomsic; [EMAIL PROTECTED]
Subject: Re: verification upon update, help, please
At 12:07 -0400 7/3/02, Paul Tomsic wrote:
>Does MySQL prevent updates from occurring when the values involved
>are the same as the database's current state.
I don't know if "prevent" is the word exactly. It doesn't bother to update
the row unless you actually change a value. The phenonenon you
Does MySQL prevent updates from occurring when the values involved are the
same as the database's current state.
For instance, if I've got a table
create table updater(
id int not null primary key auto_increment,
is_active int not null default 1
};
insert into updater(is_active) values (1);
in
19 matches
Mail list logo