REST Resource: spreadsheets.values
컬렉션을 사용해 정리하기
내 환경설정을 기준으로 콘텐츠를 저장하고 분류하세요.
리소스: ValueRange
JSON 표현 |
{
"range": string,
"majorDimension": enum (Dimension ),
"values": [
array
]
} |
필드 |
range |
string
값이 적용되는 범위(A1 표기법)입니다. 출력의 경우 이 범위는 값에서 마지막 행과 열이 제외되더라도 요청된 전체 범위를 나타냅니다. 값을 추가할 때 이 필드는 테이블을 검색할 범위를 나타내며, 그 후 값이 추가됩니다.
|
majorDimension |
enum (Dimension )
값의 주요 측정기준입니다. 출력의 경우 스프레드시트 데이터가 A1=1,B1=2,A2=3,B2=4 이면 range=A1:B2,majorDimension=ROWS 를 요청하면 [[1,2],[3,4]] 가 반환되고 range=A1:B2,majorDimension=COLUMNS 를 요청하면 [[1,3],[2,4]] 가 반환됩니다. 입력의 경우 range=A1:B2,majorDimension=ROWS 를 사용하면 [[1,2],[3,4]] 이 A1=1,B1=2,A2=3,B2=4 를 설정합니다. range=A1:B2,majorDimension=COLUMNS 이면 [[1,2],[3,4]] 이 A1=1,B1=3,A2=2,B2=4 를 설정합니다. 쓰기 시 이 필드가 설정되지 않으면 기본값은 ROWS입니다.
|
values[] |
array (ListValue format)
읽거나 쓸 데이터입니다. 배열의 배열로, 외부 배열은 모든 데이터를 나타내고 각 내부 배열은 주요 측정기준을 나타냅니다. 내부 배열의 각 항목은 하나의 셀에 해당합니다. 출력의 경우 후행하는 빈 행과 열은 포함되지 않습니다. 입력의 경우 지원되는 값 유형은 불리언, 문자열, double입니다. null 값은 건너뜁니다. 셀을 빈 값으로 설정하려면 문자열 값을 빈 문자열로 설정합니다.
|
메서드 |
|
스프레드시트에 값을 추가합니다. |
|
스프레드시트에서 하나 이상의 값 범위를 지웁니다. |
|
스프레드시트에서 하나 이상의 값 범위를 지웁니다. |
|
스프레드시트에서 하나 이상의 값 범위를 반환합니다. |
|
지정된 데이터 필터와 일치하는 값 범위를 하나 이상 반환합니다. |
|
스프레드시트의 하나 이상의 범위에 값을 설정합니다. |
|
스프레드시트의 하나 이상의 범위에 값을 설정합니다. |
|
스프레드시트에서 값을 삭제합니다. |
|
스프레드시트에서 값 범위를 반환합니다. |
|
스프레드시트의 범위에 값을 설정합니다. |
달리 명시되지 않는 한 이 페이지의 콘텐츠에는 Creative Commons Attribution 4.0 라이선스에 따라 라이선스가 부여되며, 코드 샘플에는 Apache 2.0 라이선스에 따라 라이선스가 부여됩니다. 자세한 내용은 Google Developers 사이트 정책을 참조하세요. 자바는 Oracle 및/또는 Oracle 계열사의 등록 상표입니다.
최종 업데이트: 2025-03-22(UTC)
[null,null,["최종 업데이트: 2025-03-22(UTC)"],[],[],null,["# REST Resource: spreadsheets.values\n\n- [Resource: ValueRange](#ValueRange)\n - [JSON representation](#ValueRange.SCHEMA_REPRESENTATION)\n- [Methods](#METHODS_SUMMARY)\n\nResource: ValueRange\n--------------------\n\nData within a range of the spreadsheet.\n\n| JSON representation |\n|------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"range\": string, \"majorDimension\": enum (/workspace/sheets/api/reference/rest/v4/Dimension), \"values\": [ array ] } ``` |\n\n| Fields ||\n|------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `range` | `string` The range the values cover, in [A1 notation](https://developers.google.com/workspace/sheets/api/guides/concepts#cell). For output, this range indicates the entire requested range, even though the values will exclude trailing rows and columns. When appending values, this field represents the range to search for a table, after which values will be appended. |\n| `majorDimension` | `enum (`[Dimension](/workspace/sheets/api/reference/rest/v4/Dimension)`)` The major dimension of the values. For output, if the spreadsheet data is: `A1=1,B1=2,A2=3,B2=4`, then requesting `range=A1:B2,majorDimension=ROWS` will return `[[1,2],[3,4]]`, whereas requesting `range=A1:B2,majorDimension=COLUMNS` will return `[[1,3],[2,4]]`. For input, with `range=A1:B2,majorDimension=ROWS` then `[[1,2],[3,4]]` will set `A1=1,B1=2,A2=3,B2=4`. With `range=A1:B2,majorDimension=COLUMNS` then `[[1,2],[3,4]]` will set `A1=1,B1=3,A2=2,B2=4`. When writing, if this field is not set, it defaults to ROWS. |\n| `values[]` | `array (`[ListValue](https://protobuf.dev/reference/protobuf/google.protobuf/#list-value)` format)` The data that was read or to be written. This is an array of arrays, the outer array representing all the data and each inner array representing a major dimension. Each item in the inner array corresponds with one cell. For output, empty trailing rows and columns will not be included. For input, supported value types are: bool, string, and double. Null values will be skipped. To set a cell to an empty value, set the string value to an empty string. |\n\n| Methods ------- ||\n|--------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------|\n| ### [append](/workspace/sheets/api/reference/rest/v4/spreadsheets.values/append) | Appends values to a spreadsheet. |\n| ### [batchClear](/workspace/sheets/api/reference/rest/v4/spreadsheets.values/batchClear) | Clears one or more ranges of values from a spreadsheet. |\n| ### [batchClearByDataFilter](/workspace/sheets/api/reference/rest/v4/spreadsheets.values/batchClearByDataFilter) | Clears one or more ranges of values from a spreadsheet. |\n| ### [batchGet](/workspace/sheets/api/reference/rest/v4/spreadsheets.values/batchGet) | Returns one or more ranges of values from a spreadsheet. |\n| ### [batchGetByDataFilter](/workspace/sheets/api/reference/rest/v4/spreadsheets.values/batchGetByDataFilter) | Returns one or more ranges of values that match the specified data filters. |\n| ### [batchUpdate](/workspace/sheets/api/reference/rest/v4/spreadsheets.values/batchUpdate) | Sets values in one or more ranges of a spreadsheet. |\n| ### [batchUpdateByDataFilter](/workspace/sheets/api/reference/rest/v4/spreadsheets.values/batchUpdateByDataFilter) | Sets values in one or more ranges of a spreadsheet. |\n| ### [clear](/workspace/sheets/api/reference/rest/v4/spreadsheets.values/clear) | Clears values from a spreadsheet. |\n| ### [get](/workspace/sheets/api/reference/rest/v4/spreadsheets.values/get) | Returns a range of values from a spreadsheet. |\n| ### [update](/workspace/sheets/api/reference/rest/v4/spreadsheets.values/update) | Sets values in a range of a spreadsheet. |"]]