删除字段中的Word [英] Delete Word in Field

查看:89
本文介绍了删除字段中的Word的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法只删除数据库中一列的一个单词。现在我正在用''''代替。但它不是最好的选择


**编辑**

这篇文章来自带内连接的Sql插入

is there a way to delete just one word in a column in a database. right now i''m using replace with ''''. but it''s not the greatest option

** Edit **
This post moved from Sql insert with inner join.

推荐答案

你的意思是从一个字段中的文本中删除每一个单词,或者你的意思是删除每个等于那个单词的条目吗?


删除,你的意思是删除该字段的内容,或者您​​的意思是删除符合条件的每条记录?
Do you mean to remove every occurrence of the word from within text in a field, or do you mean delete each entry which equals that word?

By delete, do you mean just delete the contents of the field, or do you mean delete each record that matches the criteria?


此列是关键字列表。连接到特定产品的每个关键字都是唯一的。此列中其他位置的任何内容都不会在列中的其他位置找到。我想删除用户选择的单词 - 所以它只会被删除一次。例如,我的专栏是,再见,你好吗,好吧,

用户选择删除,再见, - 该词只出现一次。我希望专栏说,你好吗。
this column is a list of keywords. each keyword connected to a specific product is unique. whatever is between two commas in this column will not be found elsewhere in the column. I want to delete the word(s) the user selected - so it would only be once. for example my column is ,bye,how are you,fine,
The user chooses to delete ,bye, - that word will only show up once. i want the column to say ,how are you,fine.


我可以使用它。好多了。


你找到的,使用替换,是关于你可能想出的最好的方法。我不太确定这是在表单上还是在UPDATE查询中。我会从你的问题猜测后者,但确认(或者其他方面仍然可以帮助)。


如果我们正在处理表格,那么一次只能记录一条记录并显示当前记录在表单上,​​然后当选择(或输入)一个单词时,然后从相关控件中删除它的代码将是:
I can work with that. Much better.

What you have found, to use Replace, is about the best approach you could have come up with. I''m not quite sure if this is on a form or in an UPDATE query. I would guess the latter from your question, but confirmation (or otherwise could still help).

If we were working on a form, so one record at a time and the current record shown on the form, then when a word was selected (or entered) then code to remove it from the relevant control would be :
展开 | < span class =codeLinkonclick =selectAll(this);>选择 | Wrap | 行号


这篇关于删除字段中的Word的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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