如何更新数据库中数据库的现有值 [英] how to update database existing values in database

查看:114
本文介绍了如何更新数据库中数据库的现有值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,我可以帮我解决这个问题,在保留现有值的同时,将使用哪种类型的查询来更新数据库中的值,我的意思是向现有值中添加新值



谢谢
imran

Hi guys can u help me sorting this issue , what type of query will be used to update values in database while perserving the existing values i mean adding new values to the existing values



thanks
imran

推荐答案

Um.我认为您可能会感到困惑,因为您的问题没有多大意义.您可以使用INSERT命令插入新行:
Um. I think you might be confused because your question does not make much sense. You can insert new rows with the INSERT command:
INSERT INTO myTable (id, username) VALUES ('3', 'John Smith')

或者您可以更改现有行的值:

Or you can change the value of existing rows:

UPDATE myTable SET username='Joe Bloggs' WHERE id=3

(如果不这样做)"掩盖了您想做什么,您想达到什么目的?

If this doesn''t cover what you want to do, what are you trying to achieve?


这篇关于如何更新数据库中数据库的现有值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆