Вы находитесь на странице: 1из 2

select index_ticker_id,index_ticker,sedol,exchange,open_price from index_constit

uent where SEDOL='0457963' and exchange='LSE' and index_ticker_id in (select ind


ex_ticker_id from index_ticker where release_date_time='2010-12-20');
select index_ticker_id,index_ticker,sedol,exchange,open_price from index_constit
uent
where id_type=(select distinct id from corporate_actions where action_code ='ADD
' and exdate='2010-12-20' and index_ticker='FTSE100')
and exchange=(select distinct id_type,id,exchange from corporate_actions where a
ction_code ='ADD' and exdate='2010-12-20' and index_ticker='FTSE100')
and index_ticker_id in (select index_ticker_id from index_ticker where release_d
ate_time='2010-12-20')
select index_ticker_id,index_ticker,sedol,exchange,open_price from index_constit
uent
where SEDOL=(select distinct id from corporate_actions where action_code ='ADD'
and exdate='2010-12-20' and index_ticker='FTSE100')
and exchange=(select distinct id_type,id,exchange from corporate_actions where a
ction_code ='ADD' and exdate='2010-12-20' and index_ticker='FTSE100')
and index_ticker_id in (select index_ticker_id from index_ticker where release_d
ate_time='2010-12-20')
select index_ticker_id,index_ticker,sedol,exchange,open_price from index_constit
uent
where SEDOL=(select distinct id from corporate_actions where action_code ='ADD'
and exdate='2010-12-20' and index_ticker='FTSE100')
and exchange=(select distinct exchange from corporate_actions where action_code
='ADD' and exdate='2010-12-20' and index_ticker='FTSE100')
and index_ticker_id in (select index_ticker_id from index_ticker where release_d
ate_time='2010-12-20')
select index_ticker_id,index_ticker,sedol,exchange,open_price from index_constit
uent
where SEDOL=(select distinct id from corporate_actions where action_code ='ADD'
and exdate='2010-12-20' and index_ticker='FTSE100')
or CUSIP=(select distinct id from corporate_actions where action_code ='ADD' and
exdate='2010-12-20' and index_ticker='FTSE100')
or ISIN=(select distinct id from corporate_actions where action_code ='ADD' and
exdate='2010-12-20' and index_ticker='FTSE100')
and exchange=(select distinct id_type,id,exchange from corporate_actions where a
ction_code ='ADD' and exdate='2010-12-20' and index_ticker='FTSE100')
and index_ticker_id in (select index_ticker_id from index_ticker where release_d
ate_time='2010-12-20')
mysql> SELECT index_ticker_id, index_ticker, sedol, EXCHANGE, open_price
-> FROM index_constituent
-> WHERE (id_type =(SELECT DISTINCT ID
-> FROM corporate_actions
-> WHERE action_code = 'ADD'
-> AND exdate = '2010-12-20'
-> AND index_ticker = 'FTSE100')
-> or
-> ISIN =(SELECT DISTINCT ID
-> FROM corporate_actions
-> WHERE action_code = 'ADD'
-> AND exdate = '2010-12-20'
-> AND index_ticker = 'FTSE100')
-> or
-> CUSIP =(SELECT DISTINCT ID
-> FROM corporate_actions
-> WHERE action_code = 'ADD'
-> AND exdate = '2010-12-20'
-> AND index_ticker = 'FTSE100'))
-> AND EXCHANGE =
-> (SELECT DISTINCT id_type, ID, EXCHANGE
-> FROM corporate_actions
-> WHERE action_code = 'ADD'
-> AND exdate = '2010-12-20'
-> AND index_ticker = 'FTSE100')
-> AND index_ticker_id IN (SELECT index_ticker_id
-> FROM index_ticker
-> WHERE release_date_time = '2010-12-20')
-> ;
ERROR 1241 (21000): Operand should contain 1 column(s)

Похожие интересы