0

我有两个 txt 文件,其中包含 Linux 系统中可用的 Json 数据。我在 Oracle NoSql 中为这两个文件创建了相应的表。现在,我想将此数据加载到 Oracle NoSql 数据库中创建的表中。

Syntax:
put table -name <name> [if-absent | -if-present ]
[-json <string>] [-file <file>] [-exact] [-update] 

Explanation:
Put a row into the named table. The table name is a dot-separated name with the format table[.childTableName]*.

where:

-if-absent

Indicates to put a row only if the row does not exist.

-if-present

Indicates to put a row only if the row already exists.

-json

Indicates that the value is a JSON string.

-file

Can be used to load JSON strings from a file.

-exact

Indicates that the input JSON string or file must contain values for all columns in the table and cannot contain extraneous fields.

-update

Can be used to partially update the existing record.

现在,我正在使用以下命令加载:

kv-> put table -name tablename -file /path-to-folder/file.txt
Error handling command put table -name tablename -file /path-to-folder/file.txt: Illegal value for numeric field predicted_probability: 0.0. Expected FLOAT, is DOUBLE
kv-> 

我无法找到原因。各位高手,请帮忙。

感谢您的帮助。

4

1 回答 1

0

是的,我解决了。实际上,表数据类型和 json 字符串数据类型之间存在冲突。后来我意识到了这一点。

谢谢

于 2018-05-04T06:52:39.363 回答