繁体   English   中英

SQL:根据条件过滤

[英]SQL: Filter based on criteria

我正在使用Yahoo的YQL检索有关我的梦幻足球联赛的数据。 YQL与SQL非常相似。

是`的输出

select * 
from fantasysports.leagues.standings 
where league_key='331.l.777399'

如果提供team_id,我该如何过滤以仅显示团队的“ points_for”

我以为会

select * 
from fantasysports.leagues.standings 
where league_key='331.l.777399' 
and standings.teams.team.%.team_id='2'

但这没有用。

你可以尝试这样的事情

select points_for
from fantasysports.leagues.standings
where league_key='331.l.777399'
and standings.teams.team.%.team_id='2'

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM