Max number of fields in document

I want to insert a bunch of data into the data field so the output will be like this

        Obj(
            "name", Value("Some value"),
            "name", Value("Some value"),
            "name", Value("Some value"),
            "name", Value("Some value"),
            "name", Value("Some value"),
            "name", Value("Some value"),
            "name", Value("Some value"),
            "name", Value("Some value"),
            "name", Value("Some value"),
            "name", Value("Some value"),
            "name", Value("Some value"),
            "name", Value("Some value"),
            "name", Value("Some value")
        );

But this is not possible in Java it seems, there is no method to insert more than 5 fields. even when i try to do insert more than 5 fields in the GUI only the first 5 are actually saved. I’m I doing something wrong? How do I get around this?

Hello @Developer_Account and welcome! :wave:

Passing keys and values directly is provided as a convenience. If you need more than 5 fields, then you should provide a Map instance to Obj.

From our driver documentation, hosted on github:


public static Expr Obj​(Map<String,​? extends Expr> values)

Creates a new object wrapping the Map provided. For convenience, the following helpers are available:


Driver documentation: Language

Source: faunadb-jvm/Language.java at 606cc80fa987e754b9189732d0f7447e84efa574 · fauna/faunadb-jvm · GitHub

1 Like

Amazing thanks! This works

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.