Returns the number of rows in a reference or array.
ฟังก์ชันนี้ทำงานใน Google Sheets เหมือนกับใน Excel — ไวยากรณ์และอาร์กิวเมนต์เดียวกัน
ROWS(array)The ROWS function counts the total number of rows contained within a specified range or array. It is commonly used to determine the size of a dataset or to create dynamic ranges in complex formulas.
=ROWS(A1:B5)ผลลัพธ์: 5
Calculates the number of rows in the range A1 through B5.
=ROWS({1,2;3,4;5,6})ผลลัพธ์: 3
Calculates the number of rows in the provided constant array.
Yes, ROWS counts the physical number of rows in the range regardless of whether the cells contain data or are empty.