重新发布请帮助处理mysql中的元组值 [英] Reposting please help- dealing with tuple values in mysql
本文介绍了重新发布请帮助处理mysql中的元组值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我的桌子
Custno ---型号---金额
1010 ---- - 诺基亚--- 9500
1020 -----三星 - 3200
1030 -----诺基亚 - 1200
1040 -----索尼---- 8200
1050 ----- LG ------ 2000
现在我想 显示价格高于三星的手机。
我该怎么做?请帮助
提前感谢。
My table
Custno---Model---Amount
1010-----Nokia---9500
1020-----Samsung--3200
1030-----Nokia--1200
1040-----Sony----8200
1050-----LG------2000
now i want to display cellphones which has higher price than samsung.
how do i do it ? please help
thanks in advance.
推荐答案
这是微不足道的,研究http://www.w3schools.com/sql/sql_where.asp [ ^ ]你应该构建满足你需要的sql语句。
一个模板会有所帮助:
This is trivial, study http://www.w3schools.com/sql/sql_where.asp[^] and you should be to construct the sql statement that meets your need.
A template will help:
select columns from table1 where pricecolumn >
(select pricecolumn from table1 where namecolumn = "modelname")
>
这篇关于重新发布请帮助处理mysql中的元组值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文