作者热门文章
- r - 以节省内存的方式增长 data.frame
- ruby-on-rails - ruby/ruby on rails 内存泄漏检测
- android - 无法解析导入android.support.v7.app
- UNIX 域套接字与共享内存(映射文件)
我目前正在经营一家电子商务商店,大约有 300 种产品的字段名为“product_url”
这些字段包含我需要完全删除的旧 url。
我如何创建一个查询,将所有“product_url”字段中的数据替换为空值?
最佳答案
这会将每个 product_url 设置为 NULL,当前不为空。
UPDATE table_name
SET product_url = NULL
WHERE product_url is not null;
关于MySQL 查询需要 : I need to delete all data from a single column,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4958260/
我是一名优秀的程序员,十分优秀!