FiscalYears
Retrieve a list of all fiscal years.
テーブル固有の情報
Select
本製品 はSAP Concur API を使用して、Id、UserName、およびExternalId を参照するフィルタを処理します。本製品 はクライアント側で本製品 内で他のフィルタを処理します。
例えば、本製品 はSAP Concur API に次のクエリの処理をオフロードします。
SELECT * FROM FiscalYears WHERE IncludeRemoved = 'True' SELECT * FROM FiscalYears WHERE LastModified > '2024-02-20 09:51:20.0' SELECT * FROM FiscalPeriod WHERE fiscalYearId = '7af8977c-d996-4ca7-834a-a8e5b719fa95'
Insert
会計年度を作成するには、次のカラムが必要です:Name、StartDate、EndDate、Status およびMonthlyFiscalPeriods。
MonthlyFiscalPeriods には、会計期間の完全なリストを含む集計オブジェクト、または一時テーブルの名前を指定します。
一時テーブルを使用した挿入:
INSERT INTO FiscalPeriod#TEMP (Name, PeriodType,StartDate,EndDate,Status) VALUES ('JAN', 'MONTHLY', '2023-01-01', '2023-01-31', 'OPEN')
INSERT INTO FiscalPeriod#TEMP (Name, PeriodType,StartDate,EndDate,Status) VALUES ('FEB', 'MONTHLY', '2023-02-01', '2023-02-28', 'OPEN')
INSERT INTO FiscalPeriod#TEMP (Name, PeriodType,StartDate,EndDate,Status) VALUES ('MAR', 'MONTHLY', '2023-03-01', '2023-03-31', 'OPEN')
INSERT INTO FiscalYears (name, startDate, endDate,Status, MonthlyFiscalPeriods) VALUES ('NewPeriod', '2023-01-01', '2023-03-31', 'OPEN', 'FiscalPeriod#TEMP')
JSON 集計を使用した挿入:
INSERT INTO FiscalYears (name, startDate, endDate,Status, MonthlyFiscalPeriods) VALUES ('NewPeriod', '2023-01-01', '2023-03-31', 'OPEN', '[{"name": "JAN","periodType": "MONTHLY","startDate": "2023-01-01","endDate": "2023-01-31","fiscalPeriodStatus": "OPEN"}]')
Update
API は更新操作を置換として扱います。フローはINSERT 操作と同じですが、更新する会計年度のId をクエリで指定する必要がある点が異なります。
INSERT INTO FiscalPeriod#TEMP (Name, PeriodType,StartDate,EndDate,Status) VALUES ('JAN', 'MONTHLY', '2023-01-01', '2023-01-31', 'OPEN')
INSERT INTO FiscalPeriod#TEMP (Name, PeriodType,StartDate,EndDate,Status) VALUES ('FEB', 'MONTHLY', '2023-02-01', '2023-02-28', 'OPEN')
INSERT INTO FiscalPeriod#TEMP (Name, PeriodType,StartDate,EndDate,Status) VALUES ('MAR', 'MONTHLY', '2023-03-01', '2023-03-31', 'OPEN')
UPDATE FiscalYears SET startDate = '2023-01-01', endDate = '2023-03-31', Status = 'OPEN', Name = 'TEST' , MonthlyFiscalPeriods = 'FiscalPeriod#TEMP' WHERE id = 'c891b0fb-ae64-45dc-84e4-a43d2adf4332'
Delete
会計年度の削除には、Id が必要です。クエリで会計年度Id を指定できます。それ以外の場合、本製品 が基準を処理することによって内部的にId を解決します。
Id が指定されていない場合、name = 'TEST' を持つすべての会計年度のId を検索するための追加リクエストが発行されます。
DELETE FROM fiscalYears WHERE name = 'TEST'
Id がクエリで指定された場合、本製品 は追加の処理なしで直接DELETE リクエストを発行します。
DELETE FROM fiscalYears WHERE Id = 'c891b0fb-ae64-45dc-84e4-a43d2adf4332'
Columns
| Name | Type | ReadOnly | References | Description |
| Id [KEY] | String | False |
The budget service's key for this object. | |
| Name | String | False |
The name of this fiscal year. Must be unique for this entity. | |
| Status | String | False |
The status of this fiscal year. Supported values: OPEN, CLOSED, REMOVED | |
| StartDate | Date | False |
The start date for this fiscal year. The distance between start date and end date may not be more than two years. | |
| EndDate | Date | False |
The end date for this fiscal year. The distance between start date and end date may not be more than two years. | |
| CurrentYear | Boolean | False |
True if this the current fiscal year based on the current date and time, False otherwise. | |
| LastModified | Datetime | False |
The UTC date and time when this object was last changed. | |
| DisplayName | String | False |
Display name for fiscal year. For date range budget item we use this field to display. | |
| MonthlyFiscalPeriods | String | False |
If true, the service will return all Fiscal Years, including those that were previously removed. If not supplied, this field defaults to false. |
Pseudo-Columns
SELECT ステートメントのWHERE 句では、疑似カラムフィールドを使用して、データソースから返されるタプルを詳細に制御することができます。
| Name | Type | Description |
| IncludeRemoved | Boolean |
If true, the service will return all Fiscal Years, including those that were previously removed. If not supplied, this field defaults to false. |