Skip to content

Commit

Permalink
Merge pull request #45 from nevermore3/fix_3_7
Browse files Browse the repository at this point in the history
fix 3,7
  • Loading branch information
nevermore3 authored Nov 8, 2022
2 parents 0bf4c2a + 6b8188d commit b63c835
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
4 changes: 2 additions & 2 deletions nebula/queries/interactive-complex-3.ngql
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ WITH DISTINCT friend
MATCH (friend)<-[:POST_HAS_CREATOR|COMMENT_HAS_CREATOR]-(message)-[:IS_LOCATED_IN]->(country)
WHERE
CASE
WHEN message.`Comment`.creationDate < $durationDays AND message.`Comment`.creationDate >= $startDate AND (country.Place.name == $countryXName OR country.Place.name == $countryYName) THEN true
WHEN message.Post.creationDate < $durationDays AND message.Post.creationDate >= $startDate AND (country.Place.name == $countryXName OR country.Place.name == $countryYName) THEN true
WHEN message.`Comment`.creationDate < $startDate+Duration({days:$durationDays}) AND message.`Comment`.creationDate >= $startDate AND (country.Place.name == $countryXName OR country.Place.name == $countryYName) THEN true
WHEN message.Post.creationDate < $startDate+Duration({days:$durationDays}) AND message.Post.creationDate >= $startDate AND (country.Place.name == $countryXName OR country.Place.name == $countryYName) THEN true
ELSE false
END
WITH friend,
Expand Down
8 changes: 3 additions & 5 deletions nebula/queries/interactive-complex-7.ngql
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,9 @@ RETURN
liker.Person.lastName AS personLastName,
latestLike.likeTime AS likeCreationDate,
id(latestLike.msg) AS messageId,
CASE exists(latestLike.msg.message.content)
WHEN true THEN latestLike.msg.message.content
ELSE latestLike.msg.message.imageFile
END AS messageContent,
latestLike.msg.message.creationDate AS messageCreationDate,
CASE WHEN tags(latestLike.msg) == ["Post"] THEN latestLike.msg.imageFile
ELSE latestLike.msg.content END AS messageContent,
latestLike.msg.creationDate AS messageCreationDate,
p IS NULL AS isNew
ORDER BY
likeCreationDate DESC,
Expand Down

0 comments on commit b63c835

Please sign in to comment.