我需要什么:
这是我的Api
metadata: {},
user_id: 142517,
linkedinId: null,
facebookId: "https:m",
linkedinProfile: null,
profile: null,
edition: "current",
social: "1"
我的查询
(case
when (TRIM(user.linkedinProfile) <>'' or TRIM(user.profile)<>'') and user.country= '$country_code'
then 1
when
TRIM(user.linkedinProfile) <>'' or TRIM(user.profile)<>''
then 2
when user.country='$country_code'
then 3
else 4 end) social
输出:
social in Api should 2, 3 else but not to be 1 as per my sql condition.
请告诉我我的查询错误。