{"id":10192,"date":"2015-06-04T16:15:40","date_gmt":"2015-06-04T07:15:40","guid":{"rendered":"http:\/\/www.creationline.com\/?p=10192"},"modified":"2022-12-13T15:48:27","modified_gmt":"2022-12-13T06:48:27","slug":"cypher-query%e6%bc%94%e7%bf%92%e7%94%a8%e3%81%ae%e3%82%b0%e3%83%a9%e3%83%95%e3%83%87%e3%83%bc%e3%82%bf%e3%83%99%e3%83%bc%e3%82%b9s1","status":"publish","type":"post","link":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192","title":{"rendered":"Cypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9 #neo4j"},"content":{"rendered":"<p><strong>\u3053\u306e\u8a18\u4e8b\u306f\u3001Neo4j v4.0(2020-01)\u306b\u5408\u308f\u305b\u3066\u66f4\u65b0\u3057\u3066\u3044\u307e\u3059\uff01<\/strong><\/p>\n<p>Neo4j\u306e\u30af\u30a8\u30ea\u8a00\u8a9e\u3067\u3042\u308bCypher\u304c\u306a\u304b\u306a\u304b\u4e0a\u9054\u3057\u306a\u3044\u3068\u3044\u3046\u60a9\u307f\u3092\u805e\u304f\u3068\u3001\u7b46\u8005\u306f\u300c\u30b0\u30e9\u30d5\u3092\u5fd8\u308c\u3066\u601d\u3044\u5207\u308aRDB\u7684\u306a\u4e8b\u3092\u3084\u3063\u3066\u307f\u305f\u3089\u3069\u3046\u3067\u3059\u304b\u300d\u3068\u7b54\u3048\u307e\u3059\u3002\u5927\u6982\u3001Cypher\u306b\u5341\u5206\u6163\u308c\u3066\u3044\u306a\u3044\u5185\u306b\u3001\u30d1\u30bf\u30fc\u30f3\u30de\u30c3\u30c1\u306e\u3088\u3046\u306a\u65b0\u3057\u3044\u6982\u5ff5\u306b\u53d6\u308a\u7d44\u3093\u3067\u3044\u308b\u304b\u3089\u3067\u3059\u3002<\/p>\n<p>\u305d\u306e\u6f14\u7fd2\u7528\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3068\u3057\u3066\u958b\u767a\u3057\u305f\u306e\u304c\u3001\u300cCypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u300d\u3067\u3059\u3002\u4e2d\u8eab\u306f\u3001\u67b6\u7a7a\u306eEC\u30b5\u30a4\u30c8\u306e\u8ca9\u58f2\u5c65\u6b74\u3067\u3059\u3002<\/p>\n<p>\u6b21\u306e\u66f8\u7c4d\u306f\u3001\u8272\u3005\u8a66\u3057\u3066\u307f\u305f\u3053\u3068\u3092\u307e\u3068\u3081\u305f\u7d50\u679c\u3067\u3059\u3002<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/qiita-image-store.s3.amazonaws.com\/0\/69832\/9050eb1c-afc1-76aa-7490-e5fc36def246.jpeg\" alt=\"\" \/><\/p>\n<blockquote><p>\u30bb\u30c3\u30c8\u3067\u958b\u767a\u3057\u305fCypher Query\u306a\u3069\u306f\u30012015\u5e7410\u670829\u65e5\u3001\u300eCypher\u30af\u30a8\u30ea\u30fc\u8a00\u8a9e\u306e\u4e8b\u4f8b\u3067\u5b66\u3076\u30b0\u30e9\u30d6\u30c6\u30fc\u30bf\u30d9\u30fc\u30b9Neo4j\u300f\uff08\u8457\u8005\uff1a\u674e \u660c\u6853\u3001\u76e3\u4fee\uff1a\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3\u682a\u5f0f\u4f1a\u793e\u3001\u767a\u520a:\u682a\u5f0f\u4f1a\u793e\u30a4\u30f3\u30d7\u30ec\u30b9R&amp;D)\u306e\u3088\u3046\u306b\u30ea\u30ea\u30fc\u30b9\u3055\u308c\u307e\u3057\u305f\u3002<\/p><\/blockquote>\n<p><strong>\u8457\u4f5c\u6a29\u306b\u3064\u3044\u3066<\/strong><br \/>\n\u8ca9\u58f2\u5c65\u6b74\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306e\u8457\u4f5c\u6a29\u306f\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3\u793e\u306b\u3042\u308a\u307e\u3059\u304c\u3001\u3054\u5229\u7528\u306b\u304a\u3044\u3066\u7279\u306b\u5236\u9650\u306f\u3042\u308a\u307e\u305b\u3093\u3002\u3054\u81ea\u7531\u306b\u5229\u7528\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<h2>\u30b0\u30e9\u30d5DB\u306e\u30b9\u30ad\u30fc\u30de<\/h2>\n<p>\u30b0\u30e9\u30d5DB\u3067\u306f\u3001\u30b9\u30ad\u30fc\u30de\u3092\u307f\u308c\u3070\u3001\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306e\u69cb\u6210\u304c\u4e00\u76ee\u77ad\u7136\u306b\u628a\u63e1\u3067\u304d\u307e\u3059\u3002<br \/>\n<img loading=\"lazy\" decoding=\"async\" src=\"\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/sales.db_.graph_.png\" alt=\"\" width=\"519\" height=\"262\" class=\"alignnone size-full wp-image-33112\" srcset=\"https:\/\/www.creationline.com\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/sales.db_.graph_.png 519w, https:\/\/www.creationline.com\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/sales.db_.graph_-360x182.png 360w\" sizes=\"auto, (max-width: 519px) 100vw, 519px\" \/><\/p>\n<h2>\u8ca9\u58f2\u5c65\u6b74\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306e\u69cb\u7bc9<\/h2>\n<p>\u8ca9\u58f2\u5c65\u6b74\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306f\u3001\u6b21\u306e\u30ea\u30f3\u30af\u304b\u3089\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3067\u304d\u307e\u3059\u3002<\/p>\n<p><a href=\"\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/create.salesdb.csv.zip\">\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9<\/a><\/p>\n<p>\u30d5\u30a1\u30a4\u30eb\u3092\u89e3\u51cd\u3057\u3001\u5185\u5bb9\u3092\u78ba\u8a8d\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002LOAD CSV\u3067\u300cMy\u8ca9\u58f2\u5c65\u6b74\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u300d\u304c\u4f5c\u308c\u308b\u3088\u3046\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\ncreate-salesdb-ddl.txt # LOAD CSV\u3067\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3092\u69cb\u7bc9\u3059\u308b\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\r\ncsv\/ec-users-10000.csv # \u30e6\u30fc\u30b6\u30fc\u30c7\u30fc\u30bf\r\ncsv\/ec-goods-10000.csv # \u5546\u54c1\u30c7\u30fc\u30bf\r\ncsv\/ec-sales-10000.csv # \u8ca9\u58f2\u5c65\u6b74\u30c7\u30fc\u30bf\r\n<\/pre>\n<ul>\n<li>CSV\u30d5\u30a1\u30a4\u30eb\u3092${NEO4J_HOME}\/import\u914d\u4e0b\u306b\u30b3\u30d4\u30fc<\/li>\n<li>Neo4j\u30b5\u30fc\u30d0\u30fc\u3092\u8d77\u52d5<\/li>\n<li>create-salesdb-ddl\u3092\u53c2\u8003\u306b\u3057\u3066\u5b9f\u884c<\/li>\n<\/ul>\n<h2>\u8ca9\u58f2\u5c65\u6b74\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306e\u69cb\u7bc9\u958b\u59cb<\/h2>\n<p>Neo4j\u30d6\u30e9\u30a6\u30b6\u30fc\u304b\u3089\u3001\u6b21\u306e\u3088\u3046\u306b\u5b9f\u884c\u3057\u307e\u3059\u3002<\/p>\n<p><strong>\u5236\u7d04\u53ca\u3073\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u4f5c\u6210<\/strong><br \/>\n\u5f8c\u7d9a\u306eCypher\u306b\u30a4\u30f3\u30c7\u30af\u30b9\u304c\u5fc5\u8981\u306a\u3082\u306e\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\nCREATE CONSTRAINT cnt_uid ON (u:User) ASSERT u.uid IS UNIQUE;\r\n<\/pre>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\nCREATE CONSTRAINT cnt_gid ON (g:Goods) ASSERT g.gid IS UNIQUE;\r\n<\/pre>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\nCREATE CONSTRAINT cnt_oid ON (o:Order) ASSERT o.oid IS UNIQUE;\r\n<\/pre>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\nCREATE INDEX idx_day FOR (d:Day) ON (d.day);\r\n<\/pre>\n<p><strong>\u30e6\u30fc\u30b6\u30fc\u30ce\u30fc\u30c9\u306e\u4f5c\u6210<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\nLOAD CSV WITH HEADERS FROM &quot;file:\/\/\/ec-users-10000.csv&quot; AS line\r\nCREATE (u:User { uid:line.uid, born:toInteger(line.born), gender:line.gender })\r\n<\/pre>\n<p><strong>\u5546\u54c1\u30ce\u30fc\u30c9\u306e\u4f5c\u6210<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\nLOAD CSV WITH HEADERS FROM &quot;file:\/\/\/ec-goods-10000.csv&quot; AS line\r\nCREATE (g:Goods { gid:line.gid, color:line.color })\r\n<\/pre>\n<p><strong>\u8ca9\u58f2\u5c65\u6b74\u30ce\u30fc\u30c9\u306e\u4f5c\u6210<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\n\/\/USING PERIODIC COMMIT 500\r\nLOAD CSV WITH HEADERS FROM &quot;file:\/\/\/ec-sales-10000.csv&quot; AS line\r\nCREATE (o:Order{oid:line.oid, number:toInteger(line.number), \r\n        price:toInteger(line.price),\r\n        date:substring(line.datetime,0,10),\r\n        datetime:line.datetime})\r\n<\/pre>\n<p><strong>\u30e6\u30fc\u30b6\u30fc\u3068\u8ca9\u58f2\u5c65\u6b74\u9593\u306e\u95a2\u4fc2\u6027\u306e\u4f5c\u6210<\/strong><br \/>\n\u6b86\u3069\u306e\u30b0\u30e9\u30d5DB\u3067\u306f\u3001RDB\u3068\u306f\u9055\u3063\u3066\u30c7\u30fc\u30bf\u306e\u7d50\u5408\u95a2\u4fc2\u3092\u6c38\u7d9a\u5316\u3057\u307e\u3059\u3002<br \/>\n\u5185\u90e8\u7684\u306b\u30ea\u30ec\u30fc\u30b7\u30e7\u30f3\u30b7\u30c3\u30d7(PLACED)\u306e\u524d\u5f8c\u306b\u59cb\u70b9\u3068\u7d42\u70b9\u306eID\u3092\u6301\u3061\u307e\u3059\u3002<\/p>\n<p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\n\/\/USING PERIODIC COMMIT 500\r\nLOAD CSV WITH HEADERS FROM &quot;file:\/\/\/ec-sales-10000.csv&quot; AS line \r\nMATCH (u:User { uid:line.uid }), (o:Order { oid:line.oid})\r\nCREATE (u)-[:PLACED]-&gt;(o)\r\n<\/pre>\n<\/p>\n<p><strong>\u8ca9\u58f2\u5c65\u6b74\u3068\u5546\u54c1\u9593\u306e\u95a2\u4fc2\u6027\u306e\u4f5c\u6210<\/strong><\/p>\n<p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\n\/\/USING PERIODIC COMMIT 500\r\nLOAD CSV WITH HEADERS FROM &quot;file:\/\/\/ec-sales-10000.csv&quot; AS line \r\nMATCH (o:Order { oid: line.oid}), (g:Goods { gid:line.gid})\r\nCREATE  (o)-[:CONTAINS]-&gt;(g)\r\n<\/pre>\n<\/p>\n<p><strong>\u5e74\u6708\u65e5\u6642\u9593\u30ce\u30fc\u30c9\u306e\u4f5c\u6210<\/strong><\/p>\n<p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\nWITH range(9,11) AS months, range(0,23) AS hours\r\nFOREACH(month IN months |\r\n  CREATE (y:Year {year: 2014})\r\n  CREATE (m:Month {month: month})\r\n  MERGE (y)-[:HAS_MONTH]-&gt;(m)\r\n  FOREACH(day IN (CASE\r\n                      WHEN month IN [1,3,5,7,8,10,12] THEN range(1,31)\r\n                      WHEN month = 2 THEN\r\n                        CASE\r\n                          WHEN y.year % 4 &lt;&gt; 0 THEN range(1,28)\r\n                          WHEN y.year % 100 &lt;&gt; 0 THEN range(1,29)\r\n                          WHEN y.year % 400 &lt;&gt; 0 THEN range(1,28)\r\n                          ELSE range(1,29)\r\n                        END\r\n                      ELSE range(1,30)\r\n                    END) |\r\n      CREATE (d:Day {day: day})\r\n      MERGE (m)-[:HAS_DAY]-&gt;(d) \r\n      FOREACH( hour IN hours |\r\n         CREATE (h:Hour {hour: hour})\r\n\u3000\u3000\u3000\u3000 MERGE (d)-[:HAS_HOUR]-&gt;(h))))\r\n<\/pre>\n<\/p>\n<p><strong>\u5e74\u6708\u65e5\u6642\u9593\u3068\u8ca9\u58f2\u5c65\u6b74\u9593\u306e\u95a2\u4fc2\u6027\u306e\u4f5c\u6210<\/strong><\/p>\n<p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\n\/\/USING PERIODIC COMMIT 500\r\nLOAD CSV WITH HEADERS FROM &quot;file:\/\/\/ec-sales-10000.csv&quot; AS l\r\nMATCH (y:Year { year:toInteger(substring(l.datetime,0,4))})--&gt;(m:Month { month:toInteger(substring(l.datetime,5,2))})--&gt;(d:Day { day:toInteger(substring(l. datetime,8,2))})--&gt;(h:Hour {hour:toInteger(substring(l.datetime,11,2))})\r\nMATCH (o:Order { oid:l.oid } ) \r\nCREATE (h)-[r:HAS_ORDER]-&gt;(o)\r\n<\/pre>\n<\/p>\n<p><strong>\u30e6\u30fc\u30b6\u30fc\u306e\u6700\u65b0\u306e\u8ca9\u58f2\u5c65\u6b74\u3068\u904e\u53bb\u306e\u8ca9\u58f2\u5c65\u6b74\u9593\u306e\u95a2\u4fc2\u6027\u306e\u4f5c\u6210<\/strong><\/p>\n<p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\n\/\/2\u3064\u4ee5\u4e0a\u306e\u8ca9\u58f2\u5c65\u6b74\u3092\u6301\u3064\u30e6\u30fc\u30b6\u30fc\r\nMATCH (u:User)--&gt;(o)\r\nWITH u.uid AS uname, count(o.oid) AS ocnt\r\nWHERE ocnt &gt; 1\r\n\/\/\u8ca9\u58f2\u5c65\u6b74\u3092\u6607\u9806\u306b\u4e26\u3079\u308b\r\nMATCH (u:User { uid:uname})--&gt;(o)\r\nWITH u.uid AS uname, o.oid AS oname\r\nORDER BY uname, oname\r\n\/\/\u30e6\u30fc\u30b6\u30fc\u6bce\u306b\u30aa\u30fc\u30c0\u30fc\u756a\u53f7\u30ea\u30b9\u30c8\u3092\u4f5c\u6210\r\nWITH uname, collect(oname) AS oname\r\n\/\/RETURN  uname, collect(oname) AS oname\r\n\/\/foreach\u306e\u5229\u7528\u3057\u3001\u540c\u30e6\u30fc\u30b6\u30fc\u306e\u3059\u3079\u306e\u8ca9\u58f2\u5c65\u6b74\u306e\u95a2\u4fc2\u6027\u3092\u4f5c\u6210\r\nFOREACH(i IN RANGE(0, size(oname)-2) |\r\n    FOREACH(order1 IN [oname[i]] |\r\n        FOREACH(order2 IN [oname[i+1]] |\r\n            MERGE (o1:Order {oid:order1})\r\n            MERGE (o2:Order {oid:order2})\r\n            MERGE (o1)&lt;-[:PREVIOUS]-(o2))))\r\n<\/pre>\n<\/p>\n<p><strong>Neo4j\u30d6\u30e9\u30a6\u30b6\u30fc\u304b\u3089\u63a5\u7d9a\u3057\u3001\u6b21\u306eCypher\u69cb\u6587\u3067\u30b0\u30e9\u30d5\u3092\u51fa\u529b\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/strong><br \/>\nCypher\u306b\u304a\u3044\u3066\u3001\u30a2\u30b9\u30ad\u30fc\u30a2\u30fc\u30c8\u306e\u7dda\u306fRDB\u3067\u8a00\u3048\u3070\u30b8\u30e7\u30a4\u30f3\uff08\u7d50\u5408\uff09\u3092\u610f\u5473\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\nMATCH (y:Year {year:2014})--&gt;(m:Month {month:9})--&gt;(d:Day {day:22})--&gt;(h)--&gt;(o)--(all)\r\nRETURN *\r\nLIMIT 25\r\n<\/pre>\n<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" src=\"\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/sales_graph_history.png\" alt=\"\" width=\"886\" height=\"673\" class=\"alignnone size-full wp-image-33114\" srcset=\"\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/sales_graph_history.png 886w, \/wp-content\/uploads\/2015\/06\/sales_graph_history-360x273.png 360w, \/wp-content\/uploads\/2015\/06\/sales_graph_history-768x583.png 768w\" sizes=\"auto, (max-width: 886px) 100vw, 886px\"\/><\/p>\n<p><strong>\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306e\u30b9\u30ad\u30fc\u30de\u3092\u51fa\u529b\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/strong><\/p>\n<p>Neo4j v3.x<\/p>\n<p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\ncall db.schema\r\n<\/pre>\n<\/p>\n<p>Neo4j v4.x<\/p>\n<p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\ncall db.schema.visualization\r\n<\/pre>\n<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" src=\"\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/sales-db-schema.png\" alt=\"\" width=\"1461\" height=\"650\" class=\"alignnone size-full wp-image-33122\" srcset=\"\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/sales-db-schema.png 1461w, \/wp-content\/uploads\/2015\/06\/sales-db-schema-360x160.png 360w, \/wp-content\/uploads\/2015\/06\/sales-db-schema-1024x456.png 1024w, \/wp-content\/uploads\/2015\/06\/sales-db-schema-768x342.png 768w\" sizes=\"auto, (max-width: 1461px) 100vw, 1461px\"\/><\/p>\n<h2>\u8ca9\u58f2\u5c65\u6b74\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306e\u5229\u7528\u65b9\u6cd5<\/h2>\n<p>\u30d1\u30bf\u30fc\u30f3\u30de\u30c3\u30c1\u3092\u610f\u8b58\u305b\u305a\u3001\u521d\u6b69\u7684\u306a\u30c7\u30fc\u30bf\u8868\u793a\u3001\u96c6\u8a08\u3001\u30af\u30ed\u30b9\u96c6\u8a08\u306a\u3069SQL\u3092\u66f8\u304f\u3088\u3046\u306a\u611f\u899a\u3067\u3001\u8272\u3005Cypher\u3092\u66f8\u3044\u3066\u307f\u308b\u3053\u3068\u3067\u3059\u3002<\/p>\n<p>Cypher\u306f\u3001\u6c4e\u7528\u7684\u306a\u30af\u30a8\u30ea\u8a00\u8a9e\u3067\u3059\u3002<\/p>\n<p><strong>2014\u5e749\u6708\u306e\u7dcf\u58f2\u4e0a\u91d1\u984d<\/strong><\/p>\n<p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\nMATCH (y:Year{year:2014})--&gt;(m:Month{month:9})--&gt;(d)--&gt;(h)--&gt;(o)\r\nRETURN sum(o.number * o.price)  AS \u91d1\u984d\r\n\u91d1\u984d\r\n106485340\r\n<\/pre>\n<\/p>\n<p><strong>2014\u5e749\u6708\u306e\u91d1\u66dc\u65e5\u306e\u300c22\u6642\u304b\u3089\u7fcc\u65e501\u6642\u300d\u307e\u3067\u306e\u58f2\u4e0a\u91d1\u984d<\/strong><\/p>\n<p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\nMATCH \r\n(y:Year{year:2014})--&gt;(m:Month{month:9})--&gt;(d)--&gt;(h)--&gt;(o)\r\nWHERE \r\n(d.day IN [5,12,19,26] AND h.hour IN [22,23]) OR \r\n(d.day IN [6,13,20,27] AND h.hour=0)\r\nWITH y.year AS tyear, m.month AS tmonth, d.day AS tday, h.hour AS thour, sum(o.number * o.price) AS total\r\nORDER BY tday, thour\r\nRETURN \r\ntyear+&quot;-&quot;+tmonth+&quot;-&quot;+tday+&quot; &quot;+thour+&quot;h&quot; AS \u65e5\u6642, \r\ntotal AS\u3000\u91d1\u984d\r\n\u65e5\u6642\t\u91d1\u984d\r\n&quot;2014-9-5 22h&quot;\t182824\r\n&quot;2014-9-5 23h&quot;\t223862\r\n&quot;2014-9-6 0h&quot;\t249152\r\n&quot;2014-9-12 22h&quot;\t91454\r\n&quot;2014-9-12 23h&quot;\t203124\r\n&quot;2014-9-13 0h&quot;\t122270\r\n&quot;2014-9-19 22h&quot;\t39428\r\n&quot;2014-9-19 23h&quot;\t36708\r\n&quot;2014-9-20 0h&quot;\t83610\r\n&quot;2014-9-26 22h&quot;\t138828\r\n&quot;2014-9-26 23h&quot;\t152066\r\n&quot;2014-9-27 0h&quot;\t160288\r\n<\/pre>\n<\/p>\n<p><strong>2014\u5e749\u6708\u306e\u5e74\u9f62\u5225\u7537\u5973\u5225\u306e\u58f2\u4e0a\u91d1\u984d<\/strong><br \/>\n\u304b\u306a\u308a\u8907\u96d1\u306a\u30af\u30ed\u30b9\u96c6\u8a08\u304c\u7c21\u5358\u306b\u66f8\u3051\u3066\u307e\u3059\u3002<br \/>\n\u30b0\u30e9\u30d5DB\u306f\u7d50\u5408\u6e08\u307f\u306e\u30c7\u30fc\u30bf\u304b\u3089\u51e6\u7406\u3092\u958b\u59cb\u3057\u307e\u3059\u3002SQL\u306e\u3088\u3046\u306b\u7d50\u5408\u95a2\u4fc2\u3092\u7d10\u89e3\u304f\u5fc5\u8981\u304c\u3042\u308a\u307e\u305b\u3093\u3002<br \/>\n\u3060\u304b\u3089\u3053\u305d\u3001\u8907\u96d1\u306a\u51e6\u7406\u3092\u9ad8\u901f\u306b\u884c\u3046\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"html\">\r\nMATCH (y:Year {year:2014})--&gt;(m:Month {month:9})--&gt;(d)--&gt;(h)--&gt;(o)&lt;-[:PLACED]-(u)\r\nWITH u, sum(o.number * o.price) AS total\r\nWITH\r\nCASE WHEN u.born &gt; 1994 AND u.gender=&quot;man&quot; THEN sum(total) END AS lt20m,\r\nCASE WHEN u.born &gt; 1994 AND u.gender=&quot;woman&quot; THEN sum(total) END AS lt20w,\r\nCASE WHEN u.born &gt; 1984 AND u.born &lt;= 1994 AND u.gender=&quot;man&quot; THEN sum(total) END AS lt30m,\r\nCASE WHEN u.born &gt; 1984 AND u.born &lt;= 1994 AND u.gender=&quot;woman&quot; THEN sum(total) END AS lt30w,\r\nCASE WHEN u.born &gt; 1974 AND u.born &lt;= 1984 AND u.gender=&quot;man&quot; THEN sum(total) END AS lt40m,\r\nCASE WHEN u.born &gt; 1974 AND u.born &lt;= 1984 AND u.gender=&quot;woman&quot; THEN sum(total) END AS lt40w,\r\nCASE WHEN u.born &gt; 1964 AND u.born &lt;= 1974 AND u.gender=&quot;man&quot; THEN sum(total) END AS lt50m,\r\nCASE WHEN u.born &gt; 1964 AND u.born &lt;= 1974 AND u.gender=&quot;woman&quot; THEN sum(total) END AS lt50w,\r\nCASE WHEN u.born &gt; 1954 AND u.born &lt;= 1964 AND u.gender=&quot;man&quot; THEN sum(total) END AS lt60m,\r\nCASE WHEN u.born &gt; 1954 AND u.born &lt;= 1964 AND u.gender=&quot;woman&quot; THEN sum(total) END AS lt60w,\r\nCASE WHEN u.born &lt;= 1954 AND u.gender=&quot;man&quot; THEN sum(total) END AS gt60m,\r\nCASE WHEN u.born &lt;= 1954 AND u.gender=&quot;woman&quot; THEN sum(total) END AS gt60w\r\nWITH collect(lt20m) AS lt20am,\r\n     collect(lt20w) AS lt20aw,\r\n     collect(lt30m) AS lt30am,\r\n     collect(lt30w) AS lt30aw,\r\n     collect(lt40m) AS lt40am,\r\n     collect(lt40w) AS lt40aw,\r\n     collect(lt50m) AS lt50am,\r\n     collect(lt50w) AS lt50aw,\r\n     collect(lt60m) AS lt60am,\r\n     collect(lt60w) AS lt60aw,\r\n     collect(gt60m) AS gt60am,\r\n     collect(gt60w) AS gt60aw\r\nRETURN \r\n     head(lt20am) AS \u7537\u5e74\u9f6220\u4ee5\u4e0b,\r\n     head(lt20aw) AS \u5973\u5e74\u9f6220\u4ee5\u4e0b,\r\n     head(lt30am) AS \u7537\u5e74\u9f6230\u4ee5\u4e0b,\r\n     head(lt30aw) AS \u5973\u5e74\u9f6230\u4ee5\u4e0b,\r\n     head(lt40am) AS \u7537\u5e74\u9f6240\u4ee5\u4e0b,\r\n     head(lt40aw) AS \u5973\u5e74\u9f6240\u4ee5\u4e0b,\r\n     head(lt50am) AS \u7537\u5e74\u9f6250\u4ee5\u4e0b,\r\n     head(lt50aw) AS \u5973\u5e74\u9f6250\u4ee5\u4e0b,\r\n     head(lt60am) AS \u7537\u5e74\u9f6260\u4ee5\u4e0b,\r\n     head(lt60aw) AS \u5973\u5e74\u9f6260\u4ee5\u4e0b,\r\n     head(gt60am) AS \u7537\u5e74\u9f6260\u4e0a,\r\n     head(gt60aw) AS \u5973\u5e74\u9f6260\u4e0a\r\n\u7537\u5e74\u9f6220\u4ee5\u4e0b\t\u5973\u5e74\u9f6220\u4ee5\u4e0b\t\u7537\u5e74\u9f6230\u4ee5\u4e0b\t\u5973\u5e74\u9f6230\u4ee5\u4e0b\t\u7537\u5e74\u9f6240\u4ee5\u4e0b\t\u5973\u5e74\u9f6240\u4ee5\u4e0b\t\u7537\u5e74\u9f6250\u4ee5\u4e0b\t\u5973\u5e74\u9f6250\u4ee5\u4e0b\t\u7537\u5e74\u9f6260\u4ee5\u4e0b\t\u5973\u5e74\u9f6260\u4ee5\u4e0b\t\u7537\u5e74\u9f6260\u4e0a\t\u5973\u5e74\u9f6260\u4e0a\r\n2,697,130\t3,381,830\t5,130,839\t5,522,689\t5,471,666\t3,766,844\t5,734,831\t4,794,380\t5,682,058\t4,630,580\t3,285,838\t3,143,985\r\n<\/pre>\n<\/p>\n<p>&gt;\u4e0a\u8a18\u306eCypher\u306f\u3001\u300cCypher\u30af\u30a8\u30ea\u30fc\u8a00\u8a9e\u306e\u4e8b\u4f8b\u3067\u5b66\u3076 \u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9Neo4j\u300d\u304b\u3089\u629c\u7c8b\u3057\u3066\u3044\u307e\u3059<\/p>\n<p># \u307e\u3068\u3081<br \/>\nCypher\u306f\u3001\u6c4e\u7528\u6027\u304c\u9ad8\u3044\u30af\u30a8\u30ea\u8a00\u8a9e\u3067\u3059\u3002\u8ad6\u7406\u69cb\u6210\u529b\u304c\u512a\u308c\u3066\u3044\u308b\u305f\u3081\u306b\u3001\u7c21\u6f54\u306a\u69cb\u6587\u3067\u8272\u3093\u306a\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<br \/>\n\u8272\u3005\u30b7\u30ca\u30ea\u30aa\u3092\u4f5c\u308a\u3001\u30c1\u30e3\u30ec\u30f3\u30b8\u3057\u3066\u307f\u305f\u304f\u3060\u3055\u3044\uff01<\/p>\n<blockquote class=\"wp-embedded-content\" data-secret=\"pDGUFWhWGt\">\n<p><a href=\"https:\/\/neo4j.com\/\">Neo4j Graph Platform \u2013 The Leader in Graph Databases <!-- 3.4 Home Update --><\/a><\/p>\n<\/blockquote>\n<p><iframe title=\"\u201cNeo4j Graph Platform \u2013 The Leader in Graph Databases <!-- 3.4 Home Update -->\u201d \u2014 Neo4j Graph Database Platform\" class=\"wp-embedded-content\" sandbox=\"allow-scripts\" security=\"restricted\" style=\"position: absolute; clip: rect(1px, 1px, 1px, 1px);\" src=\"https:\/\/neo4j.com\/embed\/#?secret=pDGUFWhWGt\" data-secret=\"pDGUFWhWGt\" width=\"500\" height=\"282\" frameborder=\"0\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\"><\/iframe><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3053\u306e\u8a18\u4e8b\u306f\u3001Neo4j v4.0(2020-01)\u306b\u5408\u308f\u305b\u3066\u66f4\u65b0\u3057\u3066\u3044\u307e\u3059\uff01 Neo4j\u306e\u30af\u30a8\u30ea\u8a00\u8a9e\u3067\u3042\u308bCypher\u304c\u306a\u304b\u306a\u304b\u4e0a\u9054\u3057\u306a\u3044\u3068\u3044\u3046\u60a9\u307f\u3092\u805e\u304f\u3068\u3001\u7b46\u8005\u306f\u300c\u30b0\u30e9\u30d5\u3092\u5fd8\u308c\u3066\u601d\u3044\u5207\u308aRDB\u7684\u306a\u4e8b\u3092\u3084\u3063\u3066\u307f\u305f\u3089\u3069\u3046\u3067 [&#8230;]<\/p>\n","protected":false},"author":13,"featured_media":12646,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"content-type":"","footnotes":""},"categories":[61,37],"tags":[46],"class_list":["post-10192","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-lee","category-neo4j","tag-neo4j"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Cypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9 #neo4j - Tech Blog\uff5c\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3<\/title>\n<meta name=\"description\" content=\"lee, Neo4j |\u3053\u306e\u8a18\u4e8b\u306f\u3001Neo4j v4.0(2020-01)\u306b\u5408\u308f\u305b\u3066\u66f4\u65b0\u3057\u3066\u3044\u307e\u3059\uff01\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192\" \/>\n<meta property=\"og:locale\" content=\"ja_JP\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Cypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9 #neo4j - Tech Blog\uff5c\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3\" \/>\n<meta property=\"og:description\" content=\"lee, Neo4j |\u3053\u306e\u8a18\u4e8b\u306f\u3001Neo4j v4.0(2020-01)\u306b\u5408\u308f\u305b\u3066\u66f4\u65b0\u3057\u3066\u3044\u307e\u3059\uff01\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192\" \/>\n<meta property=\"og:site_name\" content=\"Tech Blog\uff5c\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/creationline\" \/>\n<meta property=\"article:published_time\" content=\"2015-06-04T07:15:40+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-12-13T06:48:27+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.creationline.com\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/9050eb1c-afc1-76aa-7490-e5fc36def246.jpeg\" \/>\n\t<meta property=\"og:image:width\" content=\"208\" \/>\n\t<meta property=\"og:image:height\" content=\"293\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"lee\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@awk256\" \/>\n<meta name=\"twitter:site\" content=\"@creationline\" \/>\n<meta name=\"twitter:label1\" content=\"\u57f7\u7b46\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"lee\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593\" \/>\n\t<meta name=\"twitter:data2\" content=\"6\u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192\"},\"author\":{\"name\":\"lee\",\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/#\\\/schema\\\/person\\\/7a9c09b6fc036bd56d9a7f7264389616\"},\"headline\":\"Cypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9 #neo4j\",\"datePublished\":\"2015-06-04T07:15:40+00:00\",\"dateModified\":\"2022-12-13T06:48:27+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192\"},\"wordCount\":244,\"image\":{\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/cms_x3GWkuX\\\/wp-content\\\/uploads\\\/2015\\\/06\\\/9050eb1c-afc1-76aa-7490-e5fc36def246.jpeg\",\"keywords\":[\"neo4j\"],\"articleSection\":[\"lee\",\"Neo4j\"],\"inLanguage\":\"ja\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192\",\"url\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192\",\"name\":\"Cypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9 #neo4j - Tech Blog\uff5c\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/cms_x3GWkuX\\\/wp-content\\\/uploads\\\/2015\\\/06\\\/9050eb1c-afc1-76aa-7490-e5fc36def246.jpeg\",\"datePublished\":\"2015-06-04T07:15:40+00:00\",\"dateModified\":\"2022-12-13T06:48:27+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/#\\\/schema\\\/person\\\/7a9c09b6fc036bd56d9a7f7264389616\"},\"description\":\"lee, Neo4j |\u3053\u306e\u8a18\u4e8b\u306f\u3001Neo4j v4.0(2020-01)\u306b\u5408\u308f\u305b\u3066\u66f4\u65b0\u3057\u3066\u3044\u307e\u3059\uff01\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192#breadcrumb\"},\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192#primaryimage\",\"url\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/cms_x3GWkuX\\\/wp-content\\\/uploads\\\/2015\\\/06\\\/9050eb1c-afc1-76aa-7490-e5fc36def246.jpeg\",\"contentUrl\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/cms_x3GWkuX\\\/wp-content\\\/uploads\\\/2015\\\/06\\\/9050eb1c-afc1-76aa-7490-e5fc36def246.jpeg\",\"width\":208,\"height\":293},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\\\/10192#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"HOME\",\"item\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u30c7\u30fc\u30bf\u200b\u200b\u30de\u30cd\u30b8\u30e1\u30f3\u30c8\",\"item\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Neo4j\",\"item\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/data-management\\\/neo4j\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Cypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9 #neo4j\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/#website\",\"url\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/\",\"name\":\"Tech Blog\uff5c\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3\",\"description\":\"\u30a2\u30b8\u30e3\u30a4\u30eb\uff06DevOps\u3001\u30af\u30e9\u30a6\u30c9\u30cd\u30a4\u30c6\u30a3\u30d6\u3001AI\uff06LLM\u306e\u5148\u7aef\u6280\u8853\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"ja\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/#\\\/schema\\\/person\\\/7a9c09b6fc036bd56d9a7f7264389616\",\"name\":\"lee\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/278a9c7ed6393635496209225c69f2d6caf4f4b360cf0c2a80ada723070d4f94?s=96&d=wp_user_avatar&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/278a9c7ed6393635496209225c69f2d6caf4f4b360cf0c2a80ada723070d4f94?s=96&d=wp_user_avatar&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/278a9c7ed6393635496209225c69f2d6caf4f4b360cf0c2a80ada723070d4f94?s=96&d=wp_user_avatar&r=g\",\"caption\":\"lee\"},\"description\":\"\u30e2\u30c0\u30f3\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3\u30fc\u57fa\u76e4\u306e\u30bd\u30ea\u30e5\u30fc\u30b7\u30e7\u30f3\u30a2\u30fc\u30ad\u30c6\u30af\u30c8\u3068\u3057\u3066\u6d3b\u52d5\u3057\u3066\u3044\u307e\u3059\u3002 [\u8457\u66f8] \u30fbAmazon Cloud\u30c6\u30af\u30cb\u30ab\u30eb\u30ac\u30a4\u30c9\u2015EC2\\\/S3\u304b\u3089VPC\u307e\u3067\u5fb9\u5e95\u89e3\u6790 \u30fbAmazon Elastic MapReduce\u30c6\u30af\u30cb\u30ab\u30eb\u30ac\u30a4\u30c9 \u2015\u30af\u30e9\u30a6\u30c9\u578bHadoop\u3067\u5b9f\u73fe\u3059\u308b\u5927\u898f\u6a21\u5206\u6563\u51e6\u7406 \u30fbCypher\u30af\u30a8\u30ea\u30fc\u8a00\u8a9e\u306e\u4e8b\u4f8b\u3067\u5b66\u3076\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9Neo4j \u30fbNeo4j\u3092\u4f7f\u3046\u30b0\u30e9\u30d5\u578b\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u5165\u9580(\u5171\u8457) \u30fbRDB\u6280\u8853\u8005\u306e\u305f\u3081\u306eNoSQL\u30ac\u30a4\u30c9(\u5171\u8457)\",\"sameAs\":[\"https:\\\/\\\/x.com\\\/@awk256\"],\"url\":\"https:\\\/\\\/www.creationline.com\\\/tech-blog\\\/author\\\/lee\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Cypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9 #neo4j - Tech Blog\uff5c\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3","description":"lee, Neo4j |\u3053\u306e\u8a18\u4e8b\u306f\u3001Neo4j v4.0(2020-01)\u306b\u5408\u308f\u305b\u3066\u66f4\u65b0\u3057\u3066\u3044\u307e\u3059\uff01","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192","og_locale":"ja_JP","og_type":"article","og_title":"Cypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9 #neo4j - Tech Blog\uff5c\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3","og_description":"lee, Neo4j |\u3053\u306e\u8a18\u4e8b\u306f\u3001Neo4j v4.0(2020-01)\u306b\u5408\u308f\u305b\u3066\u66f4\u65b0\u3057\u3066\u3044\u307e\u3059\uff01","og_url":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192","og_site_name":"Tech Blog\uff5c\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3","article_publisher":"https:\/\/www.facebook.com\/creationline","article_published_time":"2015-06-04T07:15:40+00:00","article_modified_time":"2022-12-13T06:48:27+00:00","og_image":[{"width":208,"height":293,"url":"https:\/\/www.creationline.com\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/9050eb1c-afc1-76aa-7490-e5fc36def246.jpeg","type":"image\/jpeg"}],"author":"lee","twitter_card":"summary_large_image","twitter_creator":"@awk256","twitter_site":"@creationline","twitter_misc":{"\u57f7\u7b46\u8005":"lee","\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593":"6\u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192#article","isPartOf":{"@id":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192"},"author":{"name":"lee","@id":"https:\/\/www.creationline.com\/tech-blog\/#\/schema\/person\/7a9c09b6fc036bd56d9a7f7264389616"},"headline":"Cypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9 #neo4j","datePublished":"2015-06-04T07:15:40+00:00","dateModified":"2022-12-13T06:48:27+00:00","mainEntityOfPage":{"@id":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192"},"wordCount":244,"image":{"@id":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192#primaryimage"},"thumbnailUrl":"https:\/\/www.creationline.com\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/9050eb1c-afc1-76aa-7490-e5fc36def246.jpeg","keywords":["neo4j"],"articleSection":["lee","Neo4j"],"inLanguage":"ja"},{"@type":"WebPage","@id":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192","url":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192","name":"Cypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9 #neo4j - Tech Blog\uff5c\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3","isPartOf":{"@id":"https:\/\/www.creationline.com\/tech-blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192#primaryimage"},"image":{"@id":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192#primaryimage"},"thumbnailUrl":"https:\/\/www.creationline.com\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/9050eb1c-afc1-76aa-7490-e5fc36def246.jpeg","datePublished":"2015-06-04T07:15:40+00:00","dateModified":"2022-12-13T06:48:27+00:00","author":{"@id":"https:\/\/www.creationline.com\/tech-blog\/#\/schema\/person\/7a9c09b6fc036bd56d9a7f7264389616"},"description":"lee, Neo4j |\u3053\u306e\u8a18\u4e8b\u306f\u3001Neo4j v4.0(2020-01)\u306b\u5408\u308f\u305b\u3066\u66f4\u65b0\u3057\u3066\u3044\u307e\u3059\uff01","breadcrumb":{"@id":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192#breadcrumb"},"inLanguage":"ja","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192"]}]},{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192#primaryimage","url":"https:\/\/www.creationline.com\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/9050eb1c-afc1-76aa-7490-e5fc36def246.jpeg","contentUrl":"https:\/\/www.creationline.com\/tech-blog\/cms_x3GWkuX\/wp-content\/uploads\/2015\/06\/9050eb1c-afc1-76aa-7490-e5fc36def246.jpeg","width":208,"height":293},{"@type":"BreadcrumbList","@id":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j\/10192#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"HOME","item":"https:\/\/www.creationline.com\/tech-blog"},{"@type":"ListItem","position":2,"name":"\u30c7\u30fc\u30bf\u200b\u200b\u30de\u30cd\u30b8\u30e1\u30f3\u30c8","item":"https:\/\/www.creationline.com\/tech-blog\/data-management"},{"@type":"ListItem","position":3,"name":"Neo4j","item":"https:\/\/www.creationline.com\/tech-blog\/data-management\/neo4j"},{"@type":"ListItem","position":4,"name":"Cypher Query\u6f14\u7fd2\u7528\u306e\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9 #neo4j"}]},{"@type":"WebSite","@id":"https:\/\/www.creationline.com\/tech-blog\/#website","url":"https:\/\/www.creationline.com\/tech-blog\/","name":"Tech Blog\uff5c\u30af\u30ea\u30a8\u30fc\u30b7\u30e7\u30f3\u30e9\u30a4\u30f3","description":"\u30a2\u30b8\u30e3\u30a4\u30eb\uff06DevOps\u3001\u30af\u30e9\u30a6\u30c9\u30cd\u30a4\u30c6\u30a3\u30d6\u3001AI\uff06LLM\u306e\u5148\u7aef\u6280\u8853","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.creationline.com\/tech-blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"ja"},{"@type":"Person","@id":"https:\/\/www.creationline.com\/tech-blog\/#\/schema\/person\/7a9c09b6fc036bd56d9a7f7264389616","name":"lee","image":{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/secure.gravatar.com\/avatar\/278a9c7ed6393635496209225c69f2d6caf4f4b360cf0c2a80ada723070d4f94?s=96&d=wp_user_avatar&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/278a9c7ed6393635496209225c69f2d6caf4f4b360cf0c2a80ada723070d4f94?s=96&d=wp_user_avatar&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/278a9c7ed6393635496209225c69f2d6caf4f4b360cf0c2a80ada723070d4f94?s=96&d=wp_user_avatar&r=g","caption":"lee"},"description":"\u30e2\u30c0\u30f3\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3\u30fc\u57fa\u76e4\u306e\u30bd\u30ea\u30e5\u30fc\u30b7\u30e7\u30f3\u30a2\u30fc\u30ad\u30c6\u30af\u30c8\u3068\u3057\u3066\u6d3b\u52d5\u3057\u3066\u3044\u307e\u3059\u3002 [\u8457\u66f8] \u30fbAmazon Cloud\u30c6\u30af\u30cb\u30ab\u30eb\u30ac\u30a4\u30c9\u2015EC2\/S3\u304b\u3089VPC\u307e\u3067\u5fb9\u5e95\u89e3\u6790 \u30fbAmazon Elastic MapReduce\u30c6\u30af\u30cb\u30ab\u30eb\u30ac\u30a4\u30c9 \u2015\u30af\u30e9\u30a6\u30c9\u578bHadoop\u3067\u5b9f\u73fe\u3059\u308b\u5927\u898f\u6a21\u5206\u6563\u51e6\u7406 \u30fbCypher\u30af\u30a8\u30ea\u30fc\u8a00\u8a9e\u306e\u4e8b\u4f8b\u3067\u5b66\u3076\u30b0\u30e9\u30d5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9Neo4j \u30fbNeo4j\u3092\u4f7f\u3046\u30b0\u30e9\u30d5\u578b\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u5165\u9580(\u5171\u8457) \u30fbRDB\u6280\u8853\u8005\u306e\u305f\u3081\u306eNoSQL\u30ac\u30a4\u30c9(\u5171\u8457)","sameAs":["https:\/\/x.com\/@awk256"],"url":"https:\/\/www.creationline.com\/tech-blog\/author\/lee"}]}},"_links":{"self":[{"href":"https:\/\/www.creationline.com\/tech-blog\/wp-json\/wp\/v2\/posts\/10192","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.creationline.com\/tech-blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.creationline.com\/tech-blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.creationline.com\/tech-blog\/wp-json\/wp\/v2\/users\/13"}],"replies":[{"embeddable":true,"href":"https:\/\/www.creationline.com\/tech-blog\/wp-json\/wp\/v2\/comments?post=10192"}],"version-history":[{"count":25,"href":"https:\/\/www.creationline.com\/tech-blog\/wp-json\/wp\/v2\/posts\/10192\/revisions"}],"predecessor-version":[{"id":57647,"href":"https:\/\/www.creationline.com\/tech-blog\/wp-json\/wp\/v2\/posts\/10192\/revisions\/57647"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.creationline.com\/tech-blog\/wp-json\/wp\/v2\/media\/12646"}],"wp:attachment":[{"href":"https:\/\/www.creationline.com\/tech-blog\/wp-json\/wp\/v2\/media?parent=10192"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.creationline.com\/tech-blog\/wp-json\/wp\/v2\/categories?post=10192"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.creationline.com\/tech-blog\/wp-json\/wp\/v2\/tags?post=10192"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}