Google Docs Batch Update icon

Google Docs Batch Update

Build and send Google Docs batch update requests

Create Tables Request → Merge Table Cells

AI-generated

Summary

Merges a specified range of table cells into a single larger cell.

Inputs

  • index (required) — The zero-based index, in UTF-16 code units, of the start cell to merge. This index is relative to the beginning of the segment specified by segmentId.
  • rowIndex — The row index of the start cell.
  • columnIndex — The column index of the start cell.
  • rowSpan — The number of rows to merge, starting from the start cell.
  • columnSpan — The number of columns to merge, starting from the start cell.
  • segmentId — The ID of the header, footer, or footnote containing the table. An empty segment ID signifies the document's body.
  • tabId — The ID of the specific tab containing the table. If omitted, the request applies to the first tab.

Output shape

No body — success or failure only

Returns a success envelope if the batch request completes. The actual table cell merge is applied to the Google Doc; the node returns no data indicating the new cell size.

Examples

Example 1: Merge a 2x2 block of cells starting at the first row and column into one large cell

Set index to 0, rowIndex to 0, columnIndex to 0, rowSpan to 2, and columnSpan to 2.

Example 2: Merge a 1x3 horizontal block of cells in the second row

Set index to 2, rowIndex to 1, columnIndex to 0, and columnSpan to 3.

Links

Discussion