开发者

Doesn't Equal in SQL

I am wondering if there is some way to do a doesn't equal command in MYSQL. In other words, can you do a command like this: "SELECT * FROM someTitle WHERE someLabel != 'something'"? My code is returning an error 开发者_C百科when I attempt this.

Thanks for any help!


try this

SELECT * FROM someTitle WHERE someLabel <> 'something'


Try <> instead of !=


In SQL, like VB, <> is used instead of !=.

You can therefore write the following:

SELECT * FROM someTitle WHERE someLabel <> 'something'

I'm not sure how <> can mean inequality; can anyone explain?


Use someLabel <> 'something' instead.


Replace != with <>

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜