Syncing Array Fields Values to Google Sheets showing [Ljava.lang.Object;@......]
See original GitHub issueMinimal Code to Reproduce the Problem
const allDocuments = allDocumentsWithMetadata.map(function(documentWithMetadata) {
const document = documentWithMetadata.obj
return document;
});
const firstDocument = allDocuments[0];
const columns = Object.keys(firstDocument).sort();
Logger.log(columns);
Logger.log(firstDocument);
const sheet = SpreadsheetApp.getActiveSheet();
sheet.appendRow(columns);
allDocuments.forEach(function(document) {
const row = columns.map(function(column) {
return document[column];
});
sheet.appendRow(row);
});
Explain the Problem in Detail
Firestore Documents have array fields like this

But in Google Sheets, getting results like this

Other Comments
Library Version: 33
Issue Analytics
- State:
- Created 3 years ago
- Comments:5
Top Results From Across the Web
What does "[Ljava.lang.Object;@" mean?
lang..... represents object notation in Java to indicate any object such as Array,JSON in GAS.To get actual value try toString() (or) JSON.
Read more >Using arrays in Google Sheets - Google Docs Editors Help
An array is a table (consisting of rows and columns) of values. If you want to group the values of your cells together...
Read more >Synchronization of ArrayList in Java
There are two ways to create a Synchronized ArrayList. 1. Collections.synchronizedList() method. 2. Using CopyOnWriteArrayList. Method 1: Using ...
Read more >Collections (Java Platform SE 7 )
Returns an array list containing the elements returned by the specified enumeration in the order they are returned by the enumeration.
Read more >ArrayTable (Guava: Google Core Libraries for Java 19.0 API)
Fixed-size Table implementation backed by a two-dimensional array. The allowed row and column keys must be supplied when the table is created.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Here’s your hint
Surprise inside!
Please use StackOverflow for other questions as these issues are not related to this library.
I want product name array values to be appeared into one cell and separated by pipe