Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要帮助更新我的数据库,我在表“问题”中有一个名为“问题链接”的列,其中包含图像的名称,(image1.jpg,image2.jpg,image3.jpg)有 100 张图像,我有以 .png 扩展名重新命名...
我首先尝试使用此查询显示记录,这与解决方案相去甚远。
SELECT * FROM question WHERE "questionLink" LIKE '%.jpg%'
任何帮助都会得到帮助。谢谢
你在寻找这样的东西吗?
UPDATE question SET questionLink = REPLACE(questionLink, '.jpg', '.png');
这是SQLFiddle演示
进一步阅读REPLACE()
REPLACE()