> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kinetica.com/llms.txt
> Use this file to discover all available pages before exploring further.

# gpudb::DeleteRecordsRequest

> gpudb::DeleteRecordsRequest — Kinetica C++ API

<div className="kinetica-doxygen">
  <div className="contents">
    <p>A set of parameters for <a className="el" href="/content/api/cpp/classgpudb_1_1GPUdb#a737a76b0c9fdd8d091dc6d02e9fcac78">GPUdb::deleteRecords</a>. <a href="#details">More...</a></p>
    <p><code>#include \<<a className="el" href="/content/api/cpp/delete__records_8h_source">gpudb/protocol/delete\_records.h</a>></code></p>

    <table className="memberdecls">
      <tr className="heading">
        <td colSpan="2">
          <h2 className="groupheader"> Public Member Functions</h2>
        </td>
      </tr>

      <tr className="memitem:ac74c28359ffd03a5677b9eba6650db06" id="r_ac74c28359ffd03a5677b9eba6650db06">
        <td className="memItemLeft" align="right" valign="top"> </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#ac74c28359ffd03a5677b9eba6650db06">DeleteRecordsRequest</a> ()</td>
      </tr>

      <tr className="memdesc:ac74c28359ffd03a5677b9eba6650db06">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">Constructs a <a className="el" href="/content/api/cpp/structgpudb_1_1DeleteRecordsRequest" title="A set of parameters for GPUdb::deleteRecords.">DeleteRecordsRequest</a> object with default parameters. <br /></td>
      </tr>

      <tr className="separator:ac74c28359ffd03a5677b9eba6650db06">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>

      <tr className="memitem:a3ca6874182ca9b5f32b5f4a04a93e86e" id="r_a3ca6874182ca9b5f32b5f4a04a93e86e">
        <td className="memItemLeft" align="right" valign="top"> </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#a3ca6874182ca9b5f32b5f4a04a93e86e">DeleteRecordsRequest</a> (const std::string \&tableName\_, const std::vector\< std::string > \&expressions\_, const std::map\< std::string, std::string > \&options\_)</td>
      </tr>

      <tr className="memdesc:a3ca6874182ca9b5f32b5f4a04a93e86e">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">Constructs a <a className="el" href="/content/api/cpp/structgpudb_1_1DeleteRecordsRequest" title="A set of parameters for GPUdb::deleteRecords.">DeleteRecordsRequest</a> object with the specified parameters. <br /></td>
      </tr>

      <tr className="separator:a3ca6874182ca9b5f32b5f4a04a93e86e">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>
    </table>

    <table className="memberdecls">
      <tr className="heading">
        <td colSpan="2">
          <h2 className="groupheader"> Public Attributes</h2>
        </td>
      </tr>

      <tr className="memitem:add3ae0eeac32915e704d24ce527272ac" id="r_add3ae0eeac32915e704d24ce527272ac">
        <td className="memItemLeft" align="right" valign="top">std::string </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#add3ae0eeac32915e704d24ce527272ac">tableName</a></td>
      </tr>

      <tr className="memdesc:add3ae0eeac32915e704d24ce527272ac">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">Name of the table from which to delete records, in \[ schema\_name. <br /></td>
      </tr>

      <tr className="separator:add3ae0eeac32915e704d24ce527272ac">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>

      <tr className="memitem:a337a4aedda81f8ff2ceb4080cde1ea07" id="r_a337a4aedda81f8ff2ceb4080cde1ea07">
        <td className="memItemLeft" align="right" valign="top">std::vector\< std::string > </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#a337a4aedda81f8ff2ceb4080cde1ea07">expressions</a></td>
      </tr>

      <tr className="memdesc:a337a4aedda81f8ff2ceb4080cde1ea07">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">A list of the actual predicates, one for each select; format should follow the guidelines provided <a href="/content/concepts/expressions/" target="_top">here</a>. <br /></td>
      </tr>

      <tr className="separator:a337a4aedda81f8ff2ceb4080cde1ea07">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>

      <tr className="memitem:a335d5a4a2b1b89c7eb785566155304d6" id="r_a335d5a4a2b1b89c7eb785566155304d6">
        <td className="memItemLeft" align="right" valign="top">std::map\< std::string, std::string > </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#a335d5a4a2b1b89c7eb785566155304d6">options</a></td>
      </tr>

      <tr className="memdesc:a335d5a4a2b1b89c7eb785566155304d6">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">Optional parameters. <br /></td>
      </tr>

      <tr className="separator:a335d5a4a2b1b89c7eb785566155304d6">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>
    </table>

    <h2 className="groupheader">Detailed Description</h2>

    <div className="textblock">
      <p>A set of parameters for <a className="el" href="/content/api/cpp/classgpudb_1_1GPUdb#a737a76b0c9fdd8d091dc6d02e9fcac78">GPUdb::deleteRecords</a>. </p>
      <p>Deletes record(s) matching the provided criteria from the given table. The record selection criteria can either be one or more <a className="el" href="#a337a4aedda81f8ff2ceb4080cde1ea07">expressions</a> (matching multiple records), a single record identified by <a className="el" href="/content/api/cpp/namespacegpudb#ad42fcb5679c9c0432a46547e529eef7b">record\_id</a> options, or all records when using <a className="el" href="/content/api/cpp/namespacegpudb#a038cecdc7ab035a6642a3790f9ffa1a6">delete\_all\_records</a>. Note that the three selection criteria are mutually exclusive. This operation cannot be run on a view. The operation is synchronous meaning that a response will not be available until the request is completely processed and all the matching records are deleted. </p>
      <p className="definition">Definition at line <a className="el" href="/content/api/cpp/delete__records_8h_source#l00027">27</a> of file <a className="el" href="/content/api/cpp/delete__records_8h_source">delete\_records.h</a>.</p>
    </div>

    <h2 className="groupheader">Constructor & Destructor Documentation</h2>
    <h2 className="memtitle"><span className="permalink"><a href="#ac74c28359ffd03a5677b9eba6650db06">◆ </a></span>DeleteRecordsRequest() <span className="overload">\[1/2]</span></h2>

    <div className="memitem">
      <div className="memproto">
        <table className="mlabels">
          <tr>
            <td className="mlabels-left">
              <table className="memname">
                <tr>
                  <td className="memname">gpudb::DeleteRecordsRequest::DeleteRecordsRequest </td>
                  <td>(</td>

                  <td className="paramname">
                    <span className="paramname">
                      <span className="em" />
                    </span>
                  </td>

                  <td>)</td>

                  <td />
                </tr>
              </table>
            </td>

            <td className="mlabels-right"> <span className="mlabels"><span className="mlabel inline">inline</span></span> </td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>Constructs a <a className="el" href="/content/api/cpp/structgpudb_1_1DeleteRecordsRequest" title="A set of parameters for GPUdb::deleteRecords.">DeleteRecordsRequest</a> object with default parameters. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/delete__records_8h_source#l00032">32</a> of file <a className="el" href="/content/api/cpp/delete__records_8h_source">delete\_records.h</a>.</p>
      </div>
    </div>

    <h2 className="memtitle"><span className="permalink"><a href="#a3ca6874182ca9b5f32b5f4a04a93e86e">◆ </a></span>DeleteRecordsRequest() <span className="overload">\[2/2]</span></h2>

    <div className="memitem">
      <div className="memproto">
        <table className="mlabels">
          <tr>
            <td className="mlabels-left">
              <table className="memname">
                <tr>
                  <td className="memname">gpudb::DeleteRecordsRequest::DeleteRecordsRequest </td>
                  <td>(</td>
                  <td className="paramtype">const std::string &</td>
                  <td className="paramname"><span className="paramname"><span className="em">tableName\_</span></span>, </td>
                </tr>

                <tr>
                  <td className="paramkey" />

                  <td />

                  <td className="paramtype">const std::vector\< std::string > &</td>
                  <td className="paramname"><span className="paramname"><span className="em">expressions\_</span></span>, </td>
                </tr>

                <tr>
                  <td className="paramkey" />

                  <td />

                  <td className="paramtype">const std::map\< std::string, std::string > &</td>
                  <td className="paramname"><span className="paramname"><span className="em">options\_</span></span> )</td>
                </tr>
              </table>
            </td>

            <td className="mlabels-right"> <span className="mlabels"><span className="mlabel inline">inline</span></span> </td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>Constructs a <a className="el" href="/content/api/cpp/structgpudb_1_1DeleteRecordsRequest" title="A set of parameters for GPUdb::deleteRecords.">DeleteRecordsRequest</a> object with the specified parameters. </p>

        <div className="dl params">
          <div className="dt">Parameters</div>

          <div className="dd">
            <table className="params">
              <tr>
                <td className="paramdir">\[in]</td>
                <td className="paramname">tableName\_</td>
                <td>Name of the table from which to delete records, in \[schema\_name.]table\_name format, using standard <a href="/content/concepts/tables/#table-name-resolution" target="_top">name resolution rules</a>. Must contain the name of an existing table; not applicable to views. </td>
              </tr>

              <tr>
                <td className="paramdir">\[in]</td>
                <td className="paramname">expressions\_</td>
                <td>A list of the actual predicates, one for each select; format should follow the guidelines provided <a href="/content/concepts/expressions/" target="_top">here</a>. Specifying one or more <span className="em arg">expressions\_</span> is mutually exclusive to specifying <a className="el" href="/content/api/cpp/namespacegpudb#ad42fcb5679c9c0432a46547e529eef7b">record\_id</a> in the <span className="em arg">options\_</span>. </td>
              </tr>

              <tr>
                <td className="paramdir">\[in]</td>
                <td className="paramname">options\_</td>

                <td>
                  Optional parameters.

                  <ul>
                    <li> <a className="el" href="/content/api/cpp/namespacegpudb#a3cb9ea12e7c065a082118bbe7bdf07b3">delete\_records\_global\_expression</a>: An optional global expression to reduce the search space of the <span className="em arg">expressions\_</span>. The default value is ''. </li>
                    <li> <a className="el" href="/content/api/cpp/namespacegpudb#ad42fcb5679c9c0432a46547e529eef7b">delete\_records\_record\_id</a>: A record ID identifying a single record, obtained at the time of <a className="el" href="/content/api/cpp/classgpudb_1_1GPUdb#ab6ab327611452cc777c159d202146997">insertion of the record</a> or by calling <a className="el" href="/content/api/cpp/classgpudb_1_1GPUdb#ae32bea3bdbfef60b21d2fb7506439ca5">GPUdb::getRecordsFromCollection</a> with the <span className="em">return\_record\_ids</span> option. This option cannot be used to delete records from <a href="/content/concepts/tables/#replication" target="_top">replicated</a> tables. </li>

                    <li>
                      <a className="el" href="/content/api/cpp/namespacegpudb#a038cecdc7ab035a6642a3790f9ffa1a6">delete\_records\_delete\_all\_records</a>: If set to <a className="el" href="/content/api/cpp/namespacegpudb#a36d198ecdf41447d55b480f6cc34774e">true</a>, all records in the table will be deleted. If set to <a className="el" href="/content/api/cpp/namespacegpudb#aad2dc74761b7204b93fe896e7ae0f0fd">false</a>, then the option is effectively ignored. Supported values:

                      <ul>
                        <li> <a className="el" href="/content/api/cpp/namespacegpudb#a36d198ecdf41447d55b480f6cc34774e">delete\_records\_true</a> </li>
                        <li> <a className="el" href="/content/api/cpp/namespacegpudb#aad2dc74761b7204b93fe896e7ae0f0fd">delete\_records\_false</a> </li>
                      </ul>

                      The default value is <a className="el" href="/content/api/cpp/namespacegpudb#aad2dc74761b7204b93fe896e7ae0f0fd">delete\_records\_false</a>.
                    </li>
                  </ul>

                  The default value is an empty map.
                </td>
              </tr>
            </table>
          </div>
        </div>

        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/delete__records_8h_source#l00103">103</a> of file <a className="el" href="/content/api/cpp/delete__records_8h_source">delete\_records.h</a>.</p>
      </div>
    </div>

    <h2 className="groupheader">Member Data Documentation</h2>
    <h2 className="memtitle"><span className="permalink"><a href="#a337a4aedda81f8ff2ceb4080cde1ea07">◆ </a></span>expressions</h2>

    <div className="memitem">
      <div className="memproto">
        <table className="memname">
          <tr>
            <td className="memname">std::vector\<std::string> gpudb::DeleteRecordsRequest::expressions</td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>A list of the actual predicates, one for each select; format should follow the guidelines provided <a href="/content/concepts/expressions/" target="_top">here</a>. </p>
        <p>Specifying one or more <a className="el" href="#a337a4aedda81f8ff2ceb4080cde1ea07">expressions</a> is mutually exclusive to specifying <a className="el" href="/content/api/cpp/namespacegpudb#ad42fcb5679c9c0432a46547e529eef7b">record\_id</a> in the <a className="el" href="#a335d5a4a2b1b89c7eb785566155304d6">options</a>. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/delete__records_8h_source#l00127">127</a> of file <a className="el" href="/content/api/cpp/delete__records_8h_source">delete\_records.h</a>.</p>
      </div>
    </div>

    <h2 className="memtitle"><span className="permalink"><a href="#a335d5a4a2b1b89c7eb785566155304d6">◆ </a></span>options</h2>

    <div className="memitem">
      <div className="memproto">
        <table className="memname">
          <tr>
            <td className="memname">std::map\<std::string, std::string> gpudb::DeleteRecordsRequest::options</td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>Optional parameters. </p>

        <ul>
          <li> <a className="el" href="/content/api/cpp/namespacegpudb#a3cb9ea12e7c065a082118bbe7bdf07b3">delete\_records\_global\_expression</a>: An optional global expression to reduce the search space of the <a className="el" href="#a337a4aedda81f8ff2ceb4080cde1ea07">expressions</a>. The default value is ''. </li>
          <li> <a className="el" href="/content/api/cpp/namespacegpudb#ad42fcb5679c9c0432a46547e529eef7b">delete\_records\_record\_id</a>: A record ID identifying a single record, obtained at the time of <a className="el" href="/content/api/cpp/classgpudb_1_1GPUdb#ab6ab327611452cc777c159d202146997">insertion of the record</a> or by calling <a className="el" href="/content/api/cpp/classgpudb_1_1GPUdb#ae32bea3bdbfef60b21d2fb7506439ca5">GPUdb::getRecordsFromCollection</a> with the <span className="em">return\_record\_ids</span> option. This option cannot be used to delete records from <a href="/content/concepts/tables/#replication" target="_top">replicated</a> tables. </li>

          <li>
            <a className="el" href="/content/api/cpp/namespacegpudb#a038cecdc7ab035a6642a3790f9ffa1a6">delete\_records\_delete\_all\_records</a>: If set to <a className="el" href="/content/api/cpp/namespacegpudb#a36d198ecdf41447d55b480f6cc34774e">true</a>, all records in the table will be deleted. If set to <a className="el" href="/content/api/cpp/namespacegpudb#aad2dc74761b7204b93fe896e7ae0f0fd">false</a>, then the option is effectively ignored. Supported values:

            <ul>
              <li> <a className="el" href="/content/api/cpp/namespacegpudb#a36d198ecdf41447d55b480f6cc34774e">delete\_records\_true</a> </li>
              <li> <a className="el" href="/content/api/cpp/namespacegpudb#aad2dc74761b7204b93fe896e7ae0f0fd">delete\_records\_false</a> </li>
            </ul>

            The default value is <a className="el" href="/content/api/cpp/namespacegpudb#aad2dc74761b7204b93fe896e7ae0f0fd">delete\_records\_false</a>.
          </li>
        </ul>

        <p>The default value is an empty map. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/delete__records_8h_source#l00164">164</a> of file <a className="el" href="/content/api/cpp/delete__records_8h_source">delete\_records.h</a>.</p>
      </div>
    </div>

    <h2 className="memtitle"><span className="permalink"><a href="#add3ae0eeac32915e704d24ce527272ac">◆ </a></span>tableName</h2>

    <div className="memitem">
      <div className="memproto">
        <table className="memname">
          <tr>
            <td className="memname">std::string gpudb::DeleteRecordsRequest::tableName</td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>Name of the table from which to delete records, in \[ schema\_name. </p>
        <p>\ ]table\_name format, using standard <a href="/content/concepts/tables/#table-name-resolution" target="_top">name resolution rules</a>. Must contain the name of an existing table; not applicable to views. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/delete__records_8h_source#l00117">117</a> of file <a className="el" href="/content/api/cpp/delete__records_8h_source">delete\_records.h</a>.</p>
      </div>
    </div>

    <hr />

    The documentation for this struct was generated from the following file:

    <ul>
      <li>gpudb/protocol/<a className="el" href="/content/api/cpp/delete__records_8h_source">delete\_records.h</a></li>
    </ul>
  </div>
</div>
