---
sourceDocument: オーストラリア API リファレンス
sourceDocumentLink: https://servicenow-prod.fluidtopics.net/r/ja-JP/api-reference

 Release :

    - australia

ft:locale :

    - ja-JP

ft:publication_title :

    - オーストラリア API リファレンス

ft:clusterId :

    - crapiref

bundleId :

    - crapiref

workflow :

    - Creator


---

# レコードを取得

# レコードを取得 {#ariaid-title1}

* リリースバージョン: Australia
* 
* 更新日 2026年03月12日
* 
* ![](https://www.servicenow.com/docs/portal-asset/ico-clock) 所要時間：4分

サンプル値でターゲットテーブルをクエリし、一致するすべてのレコードとそのフィールドを返します。

## 入力フィールド

ターゲットテーブルの任意のフィールド値。

## 出力フィールド

getRecordResponse 要素には、クエリに一致するレコードのフィールド値を表す要素をカプセル化する 1 つ以上の getRecordsResult 要素を含めることができます。

## サンプル SOAP メッセージ

サンプル SOAP 要求  

    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:inc="http://www.service-now.com/incident">
       <soapenv:Header/>
       <soapenv:Body>
          <inc:getRecords>
             <number>INC0000002</number>
          </inc:getRecords>
       </soapenv:Body>
    </soapenv:Envelope>

インシデント番号がINC0000001またはINC0000002の エンコードされたクエリを使用した SOAP 要求のサンプル  

    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:inc="http://www.service-now.com/incident">
       <soapenv:Header/>
       <soapenv:Body>
          <inc:getRecords>
             <__encoded_query>number=INC0000001^ORnumber=INC0000002</__encoded_query>
          </inc:getRecords>
       </soapenv:Body>
    </soapenv:Envelope>

1 つのレコードを含むサンプル SOAP 応答  

    <soapenv:Envelope xmlns:inc="http://www.service-now.com/incident" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
       <soapenv:Header/>
       <soapenv:Body>
          <getRecordsResponse>
             <getRecordsResult>
                <caller_id>5137153cc611227c000bbd1bd8cd2007</caller_id>
                <caller_id.email>david.loo@service-now.com</caller_id.email>
                <closed_at/>
                <number>INC0000002</number>
                <opened_at>2009-12-14 23:07:12</opened_at>
                <short_description>Can't get to network file shares</short_description>
             </getRecordsResult>
          </getRecordsResponse>
       </soapenv:Body>
    </soapenv:Envelope>

複数のレコードを含むサンプル SOAP 応答  

    <soapenv:Envelope xmlns:inc="http://www.service-now.com/incident" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
       <soapenv:Header/>
       <soapenv:Body>
          <getRecordsResponse>
             <getRecordsResult>
                <caller_id>5137153cc611227c000bbd1bd8cd2006</caller_id>
                <caller_id.email>rick.berzle@yourcompany.com</caller_id.email>
                <closed_at>2009-12-17 22:55:16</closed_at>
                <number>INC0000009</number>
                <opened_at>2009-12-16 22:50:23</opened_at>
                <short_description>Reset my password</short_description>
             </getRecordsResult>
             <getRecordsResult>
                <caller_id>5137153cc611227c000bbd1bd8cd2005</caller_id>
                <caller_id.email>fred.luddy@yourcompany.com</caller_id.email>
                <closed_at>2009-12-15 22:54:55</closed_at>
                <number>INC0000010</number>
                <opened_at>2009-12-10 22:53:02</opened_at>
                <short_description>Need Oracle 10GR2 installed</short_description>
             </getRecordsResult>
          </getRecordsResponse>
       </soapenv:Body>
    </soapenv:Envelope>

## 言語固有のサンプルメッセージ

言語固有の getRecords のサンプルについては、次のトピックを参照してください。

[Perl SOAP::Lite](https://servicenow-prod.fluidtopics.net/vShsFvUdwjqxSSnMyrENrg#c_PerlWebServicesClientExamples__getRecords)

[Java Apache Axis2](https://servicenow-prod.fluidtopics.net/CJdcsPP_WSrF8mW9sMnmVA "getKeys 関数を呼び出して、カテゴリが Hardware であるすべてのインシデントをクエリする Axis クライアントプログラムの例。")

[Python](https://servicenow-prod.fluidtopics.net/PjVqq9E3C58xehX5HlAkWQ#c_PythonWebServicesClientExamples__getRecords)

