当任意两个表的结构相同时,Cosmos db中的多个JOIN返回重复的值

时间:2019-06-20 15:38:28

标签: azure-cosmosdb azure-cosmosdb-sqlapi

Because of Select in query I was getting duplicates. I even used the Distinct keyword.我正在尝试使用image中所示的过滤器来获取学生。它分别与文凭学位和普通学位一起加入。希望您能理解我要发布并解决的查询。

  

选择DISTINCT c.userPrivateDetails.email,c.id,c.emailVerified,   c.createdOn,c.nboardVerified,c.userPrivateDetails.mobileNumber,   c.userBasicDetails.firstName,ed.degree程度,ed.branch   ed.acadamicInstitution acadamicInstitution分支,ed.yearOfPassing   从C的yearOfPassing加入inter IN c.educationDetails加入ssc IN   c.educationDetails加入ed in c.educationDetails,其中ed.degreeType   ='highestOrPursuing'且udf.stringToNumber(ed.percentage)> = 20且udf.stringToNumber(inter.percentage)> = 20且   udf.stringToNumber(ssc.percentage)> = 20

波斯菊

  

选择DISTINCT c.userPrivateDetails.email,c.id,c.emailVerified,   c.createdOn,c.nboardVerified,c.userPrivateDetails.mobileNumber,   c.userBasicDetails.firstName,ed.degree程度,ed.branch   ed.acadamicInstitution acadamicInstitution分支,ed.yearOfPassing   从C的yearOfPassing加入inter IN c.educationDetails加入ssc IN   c.educationDetails加入ed in c.educationDetails,其中ed.degreeType   ='highestOrPursuing'且udf.stringToNumber(ed.percentage)> = 20且udf.stringToNumber(inter.percentage)> = 20且   udf.stringToNumber(ssc.percentage)> = 20

仅拥有ed学位而没有内部或ssc的想要的学生

谁能说出如何从cosmos db中的子文档数组中进行选择

0 个答案:

没有答案