鲜明请找到下面给出的查询:使用SQL查询
SELECT DISTINCT
reco_index_content_code,
reco_index_content_name,
reco_index_content_url
FROM tbl_reco_index_contents
WHERE
reco_index_user_action_at_select = 1
AND user_profile_number = 1
,我需要选择reco_index_content_name
截然不同。
上面的查询应该如何修改,为了达到这个目的,使得没有重复的reco_index_content_name
行?
你会用下列'reco_index_content_code'吗?例如,只选择最低的代码? –
如果有重复项,您希望返回哪一行。请注意,“不关心”往往表明设计不佳。 – Strawberry
@Strawberry - 我明白了,但是我正在为演示做一个临时修复。它可以是任何行。 – user264953