Sure, but only what you pass in one WITH is available from there on. So you would have to change your query:
MATCH (genre:Genre)-[:HAS_CHANNEL]->(channel:Channel)-[:HAS_ PROGRAM]->(program:Program)-[:HAS_GENDER]->(gender:Gender) WHERE channelName IN ["chowtime on","bollywood on"] AND (channel.date >= "2013-12-01" AND channel.date <= "2014-12-01") *RETURN DISTINCT channel.name <http://channel.name/> AS channelName, gender.reach as reach, channel.date AS date;* On Mon, Dec 1, 2014 at 10:50 AM, Sukaant Chaudhary < [email protected]> wrote: > Hi, > Can we use *WITH* and *WITH DISTINCT* in the same query. > Please help me to modify this query accordingly: > > MATCH > (genre:Genre)-[:HAS_CHANNEL]->(channel:Channel)-[:HAS_PROGRAM]->(program:Program)-[:HAS_GENDER]->(gender:Gender) > > > *WITH DISTINCT channel.name <http://channel.name> AS channelName, > gender.reach as reach WITH channel.date AS date * > WHERE channelName IN ["chowtime on","bollywood on"] > AND (date >= "2013-12-01" AND date <= "2014-12-01") > RETURN date, reach, channelName; > > -Sukaant Chaudhary > <http://in.linkedin.com/pub/sukaant-chaudhary/33/ba8/479> > > -- > You received this message because you are subscribed to the Google Groups > "Neo4j" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Neo4j" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
