查詢1: SELECT cid,
dl
FROM chal
WHERE cid IN (
SELECT cid
FROM c_users
WHERE uid = 636587
);
問題2: SELECT chal.cid AS cid,
chal.dl AS dl
FROM chal,
c_users
我有一個查詢,看起來像這樣: select
id
, int1
, int2
, (select count(*) from big_table_with_millions_of_rows
where id between t.int1 and t.int2)
from myTable t
where
....
這個select返回一行。內嵌選擇中使用的id是索引列(主