Neo4j

Neo4j 密碼查詢錯誤:無效輸入“Q”:預期“t/T”

  • April 30, 2018

在 Neo4j 中執行匹配的密碼查詢時出現錯誤(無效的輸入“Q”:預期的“t/T”)。

MATCH (company:COMPANY {name:'`X'SQUIRE COMMUNICATIONS PRIVATE LIMITED'}), 
     (cin:CORPORATE_IDENTIFICATION_NUMBER {number:'U64202TN2001PTC048084'}) 
CREATE (company)-[:IDENTIFIED_BY]-> (cin)

問題是數據中的單引號 (’)。要解決使用雙引號而不是單引號(“)。

MATCH (company:COMPANY {name:"`X'SQUIRE COMMUNICATIONS PRIVATE LIMITED"}), 
     (cin:CORPORATE_IDENTIFICATION_NUMBER {number:'U64202TN2001PTC048084'}) 
CREATE (company)-[:IDENTIFIED_BY]-> (cin)

引用自:https://dba.stackexchange.com/questions/157990