[英]How can I insert column values in a particular row separately?
I have a table with columns {a, b, c} and for row x I want to add a value for a, then a value for b, then a value for c all in separate activities as the user progresses through my app (for another user, values for a, b, and c would be added separately to a row y). 我有一个带有列{a,b,c}的表,对于x行,我想为a添加一个值,然后为b添加一个值,然后为c添加一个值,这些都在用户通过我的应用程序进行逐步移动时进行(对于另一个用户,a,b和c的值将分别添加到行y)。 How can I do this?
我怎样才能做到这一点?
可以插入a,然后b和c必须是该行的更新
i think you need to add a primary key to your table {a,b,c,key_column} 我认为您需要向表{a,b,c,key_column}添加主键
and then you can use below.. 然后您可以在下面使用
To update a:- 更新:-
UPDATE table_name
SET a=valueA
WHERE key_colum=key_value;
To update b:- 更新b:-
UPDATE table_name
SET b=valueB
WHERE key_colum=key_value;
To update c:- 更新c:-
UPDATE table_name
SET c=valueC
WHERE key_colum=key_value;
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.