运行 Cypher 脚本文件

运行文件中的每条语句 / 每个文件,所有语句以分号分隔

这些过程可用于运行通常由 cypher-shell 执行的文件。它们会自动跳过 :begin/:commit/:rollback 操作,因为它们在每个文件单个事务中执行。

过程概述

下表描述了可用的过程和函数

限定名称 类型 版本

apoc.cypher.runFileReadOnly

apoc.cypher.runFileReadOnly(file or url,[{timeout:10,parameters:{}}]) - 运行文件中的每条 READ 语句,所有语句以分号分隔

过程

Apoc Extended

apoc.cypher.runFilesReadOnly

apoc.cypher.runFilesReadOnly([files or urls],[{timeout:10,parameters:{}}])) - 运行文件中的每条 READ 语句,所有语句以分号分隔

过程

Apoc Extended

apoc.cypher.runFile

apoc.cypher.runFile(file or url,[{statistics:true,timeout:10,parameters:{}}]) - 运行文件中的每条语句,所有语句以分号分隔

过程

Apoc Extended

apoc.cypher.runFiles

apoc.cypher.runFiles([files or urls],[{statistics:true,timeout:10,parameters:{}}])) - 运行文件中的每条语句,所有语句以分号分隔

过程

Apoc Extended

apoc.cypher.runSchemaFile

apoc.cypher.runSchemaFile(file or url,[{statistics:true,timeout:10}]) - 仅允许模式操作,运行文件中的每条模式语句,所有语句以分号分隔

过程

Apoc Extended

apoc.cypher.runSchemaFiles

apoc.cypher.runSchemaFiles([files or urls],{statistics:true,timeout:10}) - 仅允许模式操作,运行文件中的每条模式语句,所有语句以分号分隔

过程

Apoc Extended

仅读取操作

  • apoc.cypher.runFileReadOnly(file or url,[{config}])

  • apoc.cypher.runFilesReadOnly([files or urls],[{config})])

仅数据操作

  • apoc.cypher.runFile(file or url,[{config}])

  • apoc.cypher.runFiles([files or urls],[{config})])

apoc.cypher.run*File(s) 过程具有一些可选配置

  • {statistics:true/false} 用于输出每条语句的更新统计信息行,默认为 true

  • {timeout:1 or 10} 用于流等待新数据的时长,默认为 10

仅模式操作

  • apoc.cypher.runSchemaFile(file or url,[{config}])

  • apoc.cypher.runSchemaFiles([files or urls],[{config})])

© . This site is unofficial and not affiliated with Neo4j, Inc.