[PHP-users 2482] Re: value update for each field

BosProject T.Takeuchi php-users@php.gr.jp
Thu, 04 Oct 2001 18:25:07 +0900


����������

> ����������������������������������1����������������������������������
> ����������������? ����������������������������(integer) ��������������������
> ����, 0������������������������.

������������������������������������������������������������������
������������

create table sample(id int,count int);

��������������id��100������count��0������������count��1������������
������������������

update sample set count = count - 1 where id >= 100 and count > 0;

����������������������������where����������������������������������
��������(count > 0)����������������������������SQL����������������

�� ����SQL������������������������������������
�� ��SQL������������������������������������������������������������

*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
������������������������
������������webmaster@bos-project.com
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*