时代周刊 影响力:“除了某一列以外所有列的查询语句”如何写

来源:百度文库 编辑:高考问答 时间:2024/05/08 01:39:08
我想问的是
表 A
列:a,b,c,d
实现的查询
select b,c,d from A
但是我现在不列举 b,c,d那么如何实现“select b,c,d from A”这个查询

怎么找到那列啊?
比如说id=100,或者name='hehe'。
select * from mytable where id<>100

select * from mytable where name<>'hehe'

也可以在where后写个子查询

给你举个例子: 有个TABLE表,里面有字段A,B,C,D4个字段名.

如果想查除B列以外的所有列的数据就是这样写:
select a,c,d from table

这就是你想要的查询语句

列名前 加 NO 看看

头是晕的, 是哪一列?满足条件的一列,还是不满足?