asterixdb-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From AsterixDB Code Review <do-not-re...@asterix-gerrit.ics.uci.edu>
Subject Change in asterixdb[mad-hatter]: [ASTERIXDB-2817][FUN] Fix IndexOutOfBoundsException in get_object_fie...
Date Thu, 03 Jun 2021 11:58:24 GMT
>From Ali Alsuliman <ali.al.solaiman@gmail.com>:

Ali Alsuliman has uploaded this change for review. ( https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/11744 )


Change subject: [ASTERIXDB-2817][FUN] Fix IndexOutOfBoundsException in get_object_fields()
......................................................................

[ASTERIXDB-2817][FUN] Fix IndexOutOfBoundsException in get_object_fields()

- user model changes: no
- storage format changes: no
- interface changes: no

Details:
- Fix IndexOutOfBoundsException in get_object_fields()
- Add test case
- Enable some test case

Change-Id: I36d7915da1193ced12c9185831dc69e3da58517b
---
M asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/ObjectsQueries.xml
A asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.1.ddl.sqlpp
A asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.2.update.sqlpp
A asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.3.query.sqlpp
A asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.4.query.sqlpp
A asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/missing-fields/missing-fields.3.adm
A asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/missing-fields/missing-fields.4.adm
M asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.4.adm
M asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.5.adm
M asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.6.adm
M asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.7.adm
M asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.8.adm
M asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.9.adm
M asterixdb/asterix-om/src/main/java/org/apache/asterix/om/pointables/nonvisitor/ARecordPointable.java
M asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/evaluators/functions/records/RecordFieldsUtil.java
15 files changed, 199 insertions(+), 69 deletions(-)



  git pull ssh://asterix-gerrit.ics.uci.edu:29418/asterixdb refs/changes/44/11744/1

diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/ObjectsQueries.xml b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/ObjectsQueries.xml
index e8902b6..a53a15e 100644
--- a/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/ObjectsQueries.xml
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/ObjectsQueries.xml
@@ -57,11 +57,11 @@
       <output-dir compare="Text">documentation-example</output-dir>
     </compilation-unit>
   </test-case>
-  <!--test-case FilePath="objects/get-object-fields">
+  <test-case FilePath="objects/get-object-fields">
       <compilation-unit name="tiny-social-example">
           <output-dir compare="Text">tiny-social-example</output-dir>
       </compilation-unit>
-  </test-case!-->
+  </test-case>
   <test-case FilePath="objects/get-object-fields">
     <compilation-unit name="tiny-social-example-no-complex-types">
       <output-dir compare="Text">tiny-social-example-no-complex-types</output-dir>
@@ -77,6 +77,11 @@
       <output-dir compare="Text">tiny-social-example-only-records</output-dir>
     </compilation-unit>
   </test-case>
+  <test-case FilePath="objects/get-object-fields">
+    <compilation-unit name="missing-fields">
+      <output-dir compare="Text">missing-fields</output-dir>
+    </compilation-unit>
+  </test-case>
   <test-case FilePath="objects/get-object-field-value">
     <compilation-unit name="documentation-example">
       <output-dir compare="Text">documentation-example</output-dir>
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.1.ddl.sqlpp b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.1.ddl.sqlpp
new file mode 100644
index 0000000..4eeae30
--- /dev/null
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.1.ddl.sqlpp
@@ -0,0 +1,37 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+/*
+ * Description  : Testing get-object-fields where some schema (complex) fields are missing or null
+ */
+
+DROP DATAVERSE test IF EXISTS;
+CREATE DATAVERSE test;
+
+USE test;
+
+CREATE TYPE t1 AS {
+  inner_f: string
+};
+
+CREATE TYPE t2 AS {
+  id: int,
+  f: t1?
+};
+
+CREATE DATASET ds1(t2) PRIMARY KEY id;
\ No newline at end of file
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.2.update.sqlpp b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.2.update.sqlpp
new file mode 100644
index 0000000..93573bb
--- /dev/null
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.2.update.sqlpp
@@ -0,0 +1,26 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+USE test;
+
+INSERT INTO ds1([
+{"id": 1, "f": null },
+{"id": 2},
+{"id": 3, "f": {"inner_f": "foo", "inner_f2": {"f3": "bar"} } }
+]);
\ No newline at end of file
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.3.query.sqlpp b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.3.query.sqlpp
new file mode 100644
index 0000000..819f46a
--- /dev/null
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.3.query.sqlpp
@@ -0,0 +1,24 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+USE test;
+
+FROM ds1 AS t
+SELECT VALUE get_object_fields(t)
+ORDER BY t.id;
\ No newline at end of file
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.4.query.sqlpp b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.4.query.sqlpp
new file mode 100644
index 0000000..d56e1e1
--- /dev/null
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/objects/get-object-fields/missing-fields/missing-fields.4.query.sqlpp
@@ -0,0 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+FROM `Metadata`.`Dataset` d, get_object_fields(d) f
+WHERE f.`is-open` = false
+SELECT DISTINCT VALUE f.`field-name`
+ORDER BY f.`field-name`;
\ No newline at end of file
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/missing-fields/missing-fields.3.adm b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/missing-fields/missing-fields.3.adm
new file mode 100644
index 0000000..ea6f909
--- /dev/null
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/missing-fields/missing-fields.3.adm
@@ -0,0 +1,3 @@
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "f", "field-type": "object", "is-open": false } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "f", "field-type": "object", "is-open": false } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "f", "field-type": "object", "is-open": false, "nested": [ { "field-name": "inner_f", "field-type": "string", "is-open": false }, { "field-name": "inner_f2", "field-type": "object", "is-open": true, "nested": [ { "field-name": "f3", "field-type": "string", "is-open": true } ] } ] } ]
\ No newline at end of file
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/missing-fields/missing-fields.4.adm b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/missing-fields/missing-fields.4.adm
new file mode 100644
index 0000000..0b364b1
--- /dev/null
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/missing-fields/missing-fields.4.adm
@@ -0,0 +1,14 @@
+"CompactionPolicy"
+"CompactionPolicyProperties"
+"DatasetId"
+"DatasetName"
+"DatasetType"
+"DatatypeDataverseName"
+"DatatypeName"
+"DataverseName"
+"ExternalDetails"
+"GroupName"
+"Hints"
+"InternalDetails"
+"PendingOp"
+"Timestamp"
\ No newline at end of file
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.4.adm b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.4.adm
index 2938d8c..79f0217 100644
--- a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.4.adm
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.4.adm
@@ -1 +1 @@
-[ { "field-name": "id", "field-type": "INT64", "is-open": false }, { "field-name": "alias", "field-type": "STRING", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": false }, { "field-name": "user-since", "field-type": "DATETIME", "is-open": false }, { "field-name": "friend-ids", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "INT64" } ] }, { "field-name": "employment", "field-type": "ORDEREDLIST", "is-open": false, "list": [ { "field-type": "RECORD", "nested": [ { "field-name": "organization-name", "field-type": "STRING", "is-open": false }, { "field-name": "start-date", "field-type": "DATE", "is-open": false }, { "field-name": "end-date", "field-type": "DATE", "is-open": false } ] } ] } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "alias", "field-type": "string", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": false }, { "field-name": "user-since", "field-type": "datetime", "is-open": false }, { "field-name": "friend-ids", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "bigint" } ] }, { "field-name": "employment", "field-type": "array", "is-open": false, "list": [ { "field-type": "object", "nested": [ { "field-name": "organization-name", "field-type": "string", "is-open": false }, { "field-name": "start-date", "field-type": "date", "is-open": false }, { "field-name": "end-date", "field-type": "date", "is-open": false } ] } ] } ]
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.5.adm b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.5.adm
index 74d2d3f..f8e1f55 100644
--- a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.5.adm
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.5.adm
@@ -1,10 +1,10 @@
-[ { "field-name": "id", "field-type": "INT64", "is-open": false }, { "field-name": "alias", "field-type": "STRING", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": false }, { "field-name": "user-since", "field-type": "DATETIME", "is-open": false }, { "field-name": "friend-ids", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "INT64" }, { "field-type": "INT64" }, { "field-type": "INT64" }, { "field-type": "INT64" } ] }, { "field-name": "employment", "field-type": "ORDEREDLIST", "is-open": false, "list": [ { "field-type": "RECORD", "nested": [ { "field-name": "organization-name", "field-type": "STRING", "is-open": false }, { "field-name": "start-date", "field-type": "DATE", "is-open": false }, { "field-name": "end-date", "field-type": "DATE", "is-open": false } ] } ] } ]
-[ { "field-name": "id", "field-type": "INT64", "is-open": false }, { "field-name": "alias", "field-type": "STRING", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": false }, { "field-name": "user-since", "field-type": "DATETIME", "is-open": false }, { "field-name": "friend-ids", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "INT64" }, { "field-type": "INT64" } ] }, { "field-name": "employment", "field-type": "ORDEREDLIST", "is-open": false, "list": [ { "field-type": "RECORD", "nested": [ { "field-name": "organization-name", "field-type": "STRING", "is-open": false }, { "field-name": "start-date", "field-type": "DATE", "is-open": false }, { "field-name": "end-date", "field-type": "DATE", "is-open": false } ] } ] } ]
-[ { "field-name": "id", "field-type": "INT64", "is-open": false }, { "field-name": "alias", "field-type": "STRING", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": false }, { "field-name": "user-since", "field-type": "DATETIME", "is-open": false }, { "field-name": "friend-ids", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "INT64" }, { "field-type": "INT64" }, { "field-type": "INT64" }, { "field-type": "INT64" } ] }, { "field-name": "employment", "field-type": "ORDEREDLIST", "is-open": false, "list": [ { "field-type": "RECORD", "nested": [ { "field-name": "organization-name", "field-type": "STRING", "is-open": false }, { "field-name": "start-date", "field-type": "DATE", "is-open": false }, { "field-name": "end-date", "field-type": "DATE", "is-open": false } ] } ] } ]
-[ { "field-name": "id", "field-type": "INT64", "is-open": false }, { "field-name": "alias", "field-type": "STRING", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": false }, { "field-name": "user-since", "field-type": "DATETIME", "is-open": false }, { "field-name": "friend-ids", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "INT64" } ] }, { "field-name": "employment", "field-type": "ORDEREDLIST", "is-open": false, "list": [ { "field-type": "RECORD", "nested": [ { "field-name": "organization-name", "field-type": "STRING", "is-open": false }, { "field-name": "start-date", "field-type": "DATE", "is-open": false }, { "field-name": "end-date", "field-type": "DATE", "is-open": false } ] } ] } ]
-[ { "field-name": "id", "field-type": "INT64", "is-open": false }, { "field-name": "alias", "field-type": "STRING", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": false }, { "field-name": "user-since", "field-type": "DATETIME", "is-open": false }, { "field-name": "friend-ids", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "INT64" }, { "field-type": "INT64" }, { "field-type": "INT64" } ] }, { "field-name": "employment", "field-type": "ORDEREDLIST", "is-open": false, "list": [ { "field-type": "RECORD", "nested": [ { "field-name": "organization-name", "field-type": "STRING", "is-open": false }, { "field-name": "start-date", "field-type": "DATE", "is-open": false }, { "field-name": "end-date", "field-type": "DATE", "is-open": false } ] } ] } ]
-[ { "field-name": "id", "field-type": "INT64", "is-open": false }, { "field-name": "alias", "field-type": "STRING", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": false }, { "field-name": "user-since", "field-type": "DATETIME", "is-open": false }, { "field-name": "friend-ids", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "INT64" }, { "field-type": "INT64" }, { "field-type": "INT64" } ] }, { "field-name": "employment", "field-type": "ORDEREDLIST", "is-open": false, "list": [ { "field-type": "RECORD", "nested": [ { "field-name": "organization-name", "field-type": "STRING", "is-open": false }, { "field-name": "start-date", "field-type": "DATE", "is-open": false }, { "field-name": "end-date", "field-type": "DATE", "is-open": false } ] } ] } ]
-[ { "field-name": "id", "field-type": "INT64", "is-open": false }, { "field-name": "alias", "field-type": "STRING", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": false }, { "field-name": "user-since", "field-type": "DATETIME", "is-open": false }, { "field-name": "friend-ids", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "INT64" } ] }, { "field-name": "employment", "field-type": "ORDEREDLIST", "is-open": false, "list": [ { "field-type": "RECORD", "nested": [ { "field-name": "organization-name", "field-type": "STRING", "is-open": false }, { "field-name": "start-date", "field-type": "DATE", "is-open": false }, { "field-name": "end-date", "field-type": "DATE", "is-open": false } ] } ] } ]
-[ { "field-name": "id", "field-type": "INT64", "is-open": false }, { "field-name": "alias", "field-type": "STRING", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": false }, { "field-name": "user-since", "field-type": "DATETIME", "is-open": false }, { "field-name": "friend-ids", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "INT64" } ] }, { "field-name": "employment", "field-type": "ORDEREDLIST", "is-open": false, "list": [ { "field-type": "RECORD", "nested": [ { "field-name": "organization-name", "field-type": "STRING", "is-open": false }, { "field-name": "start-date", "field-type": "DATE", "is-open": false }, { "field-name": "end-date", "field-type": "DATE", "is-open": false } ] } ] } ]
-[ { "field-name": "id", "field-type": "INT64", "is-open": false }, { "field-name": "alias", "field-type": "STRING", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": false }, { "field-name": "user-since", "field-type": "DATETIME", "is-open": false }, { "field-name": "friend-ids", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "INT64" }, { "field-type": "INT64" } ] }, { "field-name": "employment", "field-type": "ORDEREDLIST", "is-open": false, "list": [ { "field-type": "RECORD", "nested": [ { "field-name": "organization-name", "field-type": "STRING", "is-open": false }, { "field-name": "start-date", "field-type": "DATE", "is-open": false }, { "field-name": "end-date", "field-type": "DATE", "is-open": false } ] } ] } ]
-[ { "field-name": "id", "field-type": "INT64", "is-open": false }, { "field-name": "alias", "field-type": "STRING", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": false }, { "field-name": "user-since", "field-type": "DATETIME", "is-open": false }, { "field-name": "friend-ids", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "INT64" }, { "field-type": "INT64" }, { "field-type": "INT64" } ] }, { "field-name": "employment", "field-type": "ORDEREDLIST", "is-open": false, "list": [ { "field-type": "RECORD", "nested": [ { "field-name": "organization-name", "field-type": "STRING", "is-open": false }, { "field-name": "start-date", "field-type": "DATE", "is-open": false }, { "field-name": "end-date", "field-type": "DATE", "is-open": false } ] } ] } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "alias", "field-type": "string", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": false }, { "field-name": "user-since", "field-type": "datetime", "is-open": false }, { "field-name": "friend-ids", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "bigint" }, { "field-type": "bigint" }, { "field-type": "bigint" }, { "field-type": "bigint" } ] }, { "field-name": "employment", "field-type": "array", "is-open": false, "list": [ { "field-type": "object", "nested": [ { "field-name": "organization-name", "field-type": "string", "is-open": false }, { "field-name": "start-date", "field-type": "date", "is-open": false }, { "field-name": "end-date", "field-type": "date", "is-open": false } ] } ] } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "alias", "field-type": "string", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": false }, { "field-name": "user-since", "field-type": "datetime", "is-open": false }, { "field-name": "friend-ids", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "bigint" }, { "field-type": "bigint" } ] }, { "field-name": "employment", "field-type": "array", "is-open": false, "list": [ { "field-type": "object", "nested": [ { "field-name": "organization-name", "field-type": "string", "is-open": false }, { "field-name": "start-date", "field-type": "date", "is-open": false }, { "field-name": "end-date", "field-type": "date", "is-open": false } ] } ] } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "alias", "field-type": "string", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": false }, { "field-name": "user-since", "field-type": "datetime", "is-open": false }, { "field-name": "friend-ids", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "bigint" }, { "field-type": "bigint" }, { "field-type": "bigint" }, { "field-type": "bigint" } ] }, { "field-name": "employment", "field-type": "array", "is-open": false, "list": [ { "field-type": "object", "nested": [ { "field-name": "organization-name", "field-type": "string", "is-open": false }, { "field-name": "start-date", "field-type": "date", "is-open": false }, { "field-name": "end-date", "field-type": "date", "is-open": false } ] } ] } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "alias", "field-type": "string", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": false }, { "field-name": "user-since", "field-type": "datetime", "is-open": false }, { "field-name": "friend-ids", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "bigint" } ] }, { "field-name": "employment", "field-type": "array", "is-open": false, "list": [ { "field-type": "object", "nested": [ { "field-name": "organization-name", "field-type": "string", "is-open": false }, { "field-name": "start-date", "field-type": "date", "is-open": false }, { "field-name": "end-date", "field-type": "date", "is-open": false } ] } ] } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "alias", "field-type": "string", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": false }, { "field-name": "user-since", "field-type": "datetime", "is-open": false }, { "field-name": "friend-ids", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "bigint" }, { "field-type": "bigint" }, { "field-type": "bigint" } ] }, { "field-name": "employment", "field-type": "array", "is-open": false, "list": [ { "field-type": "object", "nested": [ { "field-name": "organization-name", "field-type": "string", "is-open": false }, { "field-name": "start-date", "field-type": "date", "is-open": false }, { "field-name": "end-date", "field-type": "date", "is-open": false } ] } ] } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "alias", "field-type": "string", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": false }, { "field-name": "user-since", "field-type": "datetime", "is-open": false }, { "field-name": "friend-ids", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "bigint" }, { "field-type": "bigint" }, { "field-type": "bigint" } ] }, { "field-name": "employment", "field-type": "array", "is-open": false, "list": [ { "field-type": "object", "nested": [ { "field-name": "organization-name", "field-type": "string", "is-open": false }, { "field-name": "start-date", "field-type": "date", "is-open": false }, { "field-name": "end-date", "field-type": "date", "is-open": false } ] } ] } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "alias", "field-type": "string", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": false }, { "field-name": "user-since", "field-type": "datetime", "is-open": false }, { "field-name": "friend-ids", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "bigint" } ] }, { "field-name": "employment", "field-type": "array", "is-open": false, "list": [ { "field-type": "object", "nested": [ { "field-name": "organization-name", "field-type": "string", "is-open": false }, { "field-name": "start-date", "field-type": "date", "is-open": false }, { "field-name": "end-date", "field-type": "date", "is-open": false } ] } ] } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "alias", "field-type": "string", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": false }, { "field-name": "user-since", "field-type": "datetime", "is-open": false }, { "field-name": "friend-ids", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "bigint" } ] }, { "field-name": "employment", "field-type": "array", "is-open": false, "list": [ { "field-type": "object", "nested": [ { "field-name": "organization-name", "field-type": "string", "is-open": false }, { "field-name": "start-date", "field-type": "date", "is-open": false }, { "field-name": "end-date", "field-type": "date", "is-open": false } ] } ] } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "alias", "field-type": "string", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": false }, { "field-name": "user-since", "field-type": "datetime", "is-open": false }, { "field-name": "friend-ids", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "bigint" }, { "field-type": "bigint" } ] }, { "field-name": "employment", "field-type": "array", "is-open": false, "list": [ { "field-type": "object", "nested": [ { "field-name": "organization-name", "field-type": "string", "is-open": false }, { "field-name": "start-date", "field-type": "date", "is-open": false }, { "field-name": "end-date", "field-type": "date", "is-open": false } ] } ] } ]
+[ { "field-name": "id", "field-type": "bigint", "is-open": false }, { "field-name": "alias", "field-type": "string", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": false }, { "field-name": "user-since", "field-type": "datetime", "is-open": false }, { "field-name": "friend-ids", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "bigint" }, { "field-type": "bigint" }, { "field-type": "bigint" } ] }, { "field-name": "employment", "field-type": "array", "is-open": false, "list": [ { "field-type": "object", "nested": [ { "field-name": "organization-name", "field-type": "string", "is-open": false }, { "field-name": "start-date", "field-type": "date", "is-open": false }, { "field-name": "end-date", "field-type": "date", "is-open": false } ] } ] } ]
\ No newline at end of file
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.6.adm b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.6.adm
index 73bfe63..9a60421 100644
--- a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.6.adm
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.6.adm
@@ -1,15 +1,15 @@
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "message-id", "field-type": "INT64", "is-open": false }, { "field-name": "author-id", "field-type": "INT64", "is-open": false }, { "field-name": "in-response-to", "field-type": "INT64", "is-open": false }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "message", "field-type": "STRING", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
+[ { "field-name": "message-id", "field-type": "bigint", "is-open": false }, { "field-name": "author-id", "field-type": "bigint", "is-open": false }, { "field-name": "in-response-to", "field-type": "bigint", "is-open": false }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "message", "field-type": "string", "is-open": false } ]
\ No newline at end of file
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.7.adm b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.7.adm
index 429d522..d63f06f 100644
--- a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.7.adm
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.7.adm
@@ -1,4 +1,4 @@
-[ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ]
-[ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ]
-[ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ]
-[ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ]
+[ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ]
+[ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ]
+[ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ]
+[ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ]
\ No newline at end of file
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.8.adm b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.8.adm
index c31a69b..e84c545 100644
--- a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.8.adm
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.8.adm
@@ -1,12 +1,12 @@
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
-[ { "field-name": "tweetid", "field-type": "STRING", "is-open": false }, { "field-name": "user", "field-type": "RECORD", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "STRING", "is-open": false }, { "field-name": "lang", "field-type": "STRING", "is-open": false }, { "field-name": "friends_count", "field-type": "INT64", "is-open": false }, { "field-name": "statuses_count", "field-type": "INT64", "is-open": false }, { "field-name": "name", "field-type": "STRING", "is-open": true }, { "field-name": "followers_count", "field-type": "INT64", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "POINT", "is-open": false }, { "field-name": "send-time", "field-type": "DATETIME", "is-open": false }, { "field-name": "referred-topics", "field-type": "UNORDEREDLIST", "is-open": false, "list": [ { "field-type": "STRING" }, { "field-type": "STRING" } ] }, { "field-name": "message-text", "field-type": "STRING", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
+[ { "field-name": "tweetid", "field-type": "string", "is-open": false }, { "field-name": "user", "field-type": "object", "is-open": false, "nested": [ { "field-name": "screen-name", "field-type": "string", "is-open": false }, { "field-name": "lang", "field-type": "string", "is-open": false }, { "field-name": "friends_count", "field-type": "bigint", "is-open": false }, { "field-name": "statuses_count", "field-type": "bigint", "is-open": false }, { "field-name": "name", "field-type": "string", "is-open": true }, { "field-name": "followers_count", "field-type": "bigint", "is-open": true } ] }, { "field-name": "sender-location", "field-type": "point", "is-open": false }, { "field-name": "send-time", "field-type": "datetime", "is-open": false }, { "field-name": "referred-topics", "field-type": "multiset", "is-open": false, "list": [ { "field-type": "string" }, { "field-type": "string" } ] }, { "field-name": "message-text", "field-type": "string", "is-open": false } ]
\ No newline at end of file
diff --git a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.9.adm b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.9.adm
index 8693920..967135f 100644
--- a/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.9.adm
+++ b/asterixdb/asterix-app/src/test/resources/runtimets/results/objects/get-object-fields/tiny-social-example/tiny-social-example.9.adm
@@ -1,6 +1,6 @@
-{ "count": 12, "field-name": "message-text", "field-type": "STRING" }
-{ "count": 12, "field-name": "referred-topics", "field-type": "UNORDEREDLIST" }
-{ "count": 12, "field-name": "send-time", "field-type": "DATETIME" }
-{ "count": 12, "field-name": "sender-location", "field-type": "POINT" }
-{ "count": 12, "field-name": "tweetid", "field-type": "STRING" }
-{ "count": 12, "field-name": "user", "field-type": "RECORD" }
+{ "count": 12, "field-name": "message-text", "field-type": "string" }
+{ "count": 12, "field-name": "referred-topics", "field-type": "multiset" }
+{ "count": 12, "field-name": "send-time", "field-type": "datetime" }
+{ "count": 12, "field-name": "sender-location", "field-type": "point" }
+{ "count": 12, "field-name": "tweetid", "field-type": "string" }
+{ "count": 12, "field-name": "user", "field-type": "object" }
\ No newline at end of file
diff --git a/asterixdb/asterix-om/src/main/java/org/apache/asterix/om/pointables/nonvisitor/ARecordPointable.java b/asterixdb/asterix-om/src/main/java/org/apache/asterix/om/pointables/nonvisitor/ARecordPointable.java
index af8d5e6..cc3816c 100644
--- a/asterixdb/asterix-om/src/main/java/org/apache/asterix/om/pointables/nonvisitor/ARecordPointable.java
+++ b/asterixdb/asterix-om/src/main/java/org/apache/asterix/om/pointables/nonvisitor/ARecordPointable.java
@@ -152,7 +152,7 @@
                 && RecordUtil.isNull(bytes[getNullBitmapOffset(recordType) + fieldId / 4], fieldId);
     }
 
-    private boolean isClosedFieldMissing(ARecordType recordType, int fieldId) {
+    public boolean isClosedFieldMissing(ARecordType recordType, int fieldId) {
         return getNullBitmapSize(recordType) > 0
                 && RecordUtil.isMissing(bytes[getNullBitmapOffset(recordType) + fieldId / 4], fieldId);
     }
diff --git a/asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/evaluators/functions/records/RecordFieldsUtil.java b/asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/evaluators/functions/records/RecordFieldsUtil.java
index 0d85807..25dd73e 100644
--- a/asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/evaluators/functions/records/RecordFieldsUtil.java
+++ b/asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/evaluators/functions/records/RecordFieldsUtil.java
@@ -58,16 +58,15 @@
     private final static AString nestedName = new AString("nested");
     private final static AString listName = new AString("list");
 
-    private IObjectPool<IARecordBuilder, ATypeTag> recordBuilderPool =
-            new ListObjectPool<IARecordBuilder, ATypeTag>(new RecordBuilderFactory());
-    private IObjectPool<IAsterixListBuilder, ATypeTag> listBuilderPool =
-            new ListObjectPool<IAsterixListBuilder, ATypeTag>(new ListBuilderFactory());
-    private IObjectPool<IMutableValueStorage, ATypeTag> abvsBuilderPool =
-            new ListObjectPool<IMutableValueStorage, ATypeTag>(new AbvsBuilderFactory());
-    private IObjectPool<IPointable, ATypeTag> recordPointablePool =
-            new ListObjectPool<IPointable, ATypeTag>(ARecordPointable.ALLOCATOR);
-    private IObjectPool<IPointable, ATypeTag> listPointablePool =
-            new ListObjectPool<IPointable, ATypeTag>(AListPointable.ALLOCATOR);
+    private final IObjectPool<IARecordBuilder, ATypeTag> recordBuilderPool =
+            new ListObjectPool<>(new RecordBuilderFactory());
+    private final IObjectPool<IAsterixListBuilder, ATypeTag> listBuilderPool =
+            new ListObjectPool<>(new ListBuilderFactory());
+    private final IObjectPool<IMutableValueStorage, ATypeTag> abvsBuilderPool =
+            new ListObjectPool<>(new AbvsBuilderFactory());
+    private final IObjectPool<IPointable, ATypeTag> recordPointablePool =
+            new ListObjectPool<>(ARecordPointable.ALLOCATOR);
+    private final IObjectPool<IPointable, ATypeTag> listPointablePool = new ListObjectPool<>(AListPointable.ALLOCATOR);
 
     private final static AOrderedListType listType = new AOrderedListType(BuiltinType.ANY, "fields");
     //Better not be a static object.
@@ -114,15 +113,14 @@
             // write nested or list types
             if (tag == ATypeTag.SERIALIZED_RECORD_TYPE_TAG || tag == ATypeTag.SERIALIZED_ORDEREDLIST_TYPE_TAG
                     || tag == ATypeTag.SERIALIZED_UNORDEREDLIST_TYPE_TAG) {
-                if (!recordAccessor.isClosedFieldNull(recType, i)) {
+                if (!recordAccessor.isClosedFieldNull(recType, i) && !recordAccessor.isClosedFieldMissing(recType, i)) {
                     IAType fieldType = recordAccessor.getClosedFieldType(recType, i);
                     ArrayBackedValueStorage tmpValue = getTempBuffer();
                     tmpValue.reset();
                     recordAccessor.getClosedFieldValue(recType, i, tmpValue.getDataOutput());
                     if (tag == ATypeTag.SERIALIZED_RECORD_TYPE_TAG) {
                         addNestedField(tmpValue, fieldType, fieldRecordBuilder, level + 1);
-                    } else if (tag == ATypeTag.SERIALIZED_ORDEREDLIST_TYPE_TAG
-                            || tag == ATypeTag.SERIALIZED_UNORDEREDLIST_TYPE_TAG) {
+                    } else {
                         addListField(tmpValue, fieldType, fieldRecordBuilder, level + 1);
                     }
                 }
@@ -159,8 +157,7 @@
                 recordAccessor.getOpenFieldValue(recType, i, tmpValue.getDataOutput());
                 if (tag == ATypeTag.SERIALIZED_RECORD_TYPE_TAG) {
                     addNestedField(tmpValue, fieldType, fieldRecordBuilder, level + 1);
-                } else if (tag == ATypeTag.SERIALIZED_ORDEREDLIST_TYPE_TAG
-                        || tag == ATypeTag.SERIALIZED_UNORDEREDLIST_TYPE_TAG) {
+                } else {
                     addListField(tmpValue, fieldType, fieldRecordBuilder, level + 1);
                 }
             }
@@ -256,7 +253,7 @@
         ArrayBackedValueStorage itemValue = getTempBuffer();
         IARecordBuilder listRecordBuilder = getRecordBuilder();
 
-        AListPointable list = getListPointable();
+        AListPointable list = getListPointable(fieldType.getTypeTag());
         list.set(listArg);
 
         OrderedListBuilder innerListBuilder = getOrderedListBuilder();
@@ -274,6 +271,7 @@
 
             if (tagId == ATypeTag.SERIALIZED_RECORD_TYPE_TAG) {
                 ArrayBackedValueStorage tmpAbvs = getTempBuffer();
+                tmpAbvs.reset();
                 list.getItemValue(act, l, tmpAbvs.getDataOutput());
                 addNestedField(tmpAbvs, act.getItemType(), listRecordBuilder, level + 1);
             }
@@ -288,8 +286,8 @@
         return (ARecordPointable) recordPointablePool.allocate(ATypeTag.OBJECT);
     }
 
-    private AListPointable getListPointable() {
-        return (AListPointable) listPointablePool.allocate(ATypeTag.ARRAY);
+    private AListPointable getListPointable(ATypeTag tag) {
+        return (AListPointable) listPointablePool.allocate(tag);
     }
 
     private IARecordBuilder getRecordBuilder() {

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/11744
To unsubscribe, or for help writing mail filters, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-Project: asterixdb
Gerrit-Branch: mad-hatter
Gerrit-Change-Id: I36d7915da1193ced12c9185831dc69e3da58517b
Gerrit-Change-Number: 11744
Gerrit-PatchSet: 1
Gerrit-Owner: Ali Alsuliman <ali.al.solaiman@gmail.com>
Gerrit-MessageType: newchange

Mime
View raw message