> ## 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.

# delete

<div className="kinetica-pydoc">
  <div className="dl py method">
    <div className="dt sig sig-object py" id="gpudb.GPUdb.delete"> <span className="sig-name descname"><span className="pre">delete</span></span><span className="sig-paren">(</span><span className="em sig-param"><span className="keyword-only-separator o"><span title="Keyword-only parameters separator (PEP 3102)" className="abbr"><span className="pre">\*</span></span></span></span>, <span className="em sig-param"><span className="n"><span className="pre">table\_name</span></span><span className="o"><span className="pre">=</span></span><span className="default_value"><span className="pre">None</span></span></span>, <span className="em sig-param"><span className="n"><span className="pre">expression</span></span><span className="o"><span className="pre">=</span></span><span className="default_value"><span className="pre">None</span></span></span><span className="sig-paren">)</span><a href="https://github.com/kineticadb/kinetica-api-python/blob/master/gpudb/gpudb.py#L10846"><span className="viewcode-link"><span className="pre">\[source]</span></span></a></div>

    <div className="dd">
      <p>Deletes the record matching the provided criterion from the given table. The record selection criteria can be a single input parameter <span className="em">expression</span> (matching multiple records) 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><strong>Parameters</strong></p>

      <div className="blockquote">
        <div>
          <div className="dl simple">
            <div className="dt">table\_name (<span className="em">str</span>) –</div>

            <div className="dd">
              <p>Name of the table from which to delete records, in \[schema\_name.]table\_name format, using standard <a className="reference external" href="/content/concepts/tables/#table-name-resolution">name resolution rules</a>. Must contain the name of an existing table; not applicable to views.</p>
            </div>

            <div className="dt">expression (<span className="em">str</span>) –</div>

            <div className="dd">
              <p>The actual predicate, to be used by the delete operation; format should follow the guidelines provided <a className="reference external" href="/content/concepts/expressions/">here</a>. Specifying an input parameter <span className="em">expression</span> is mutually exclusive to specifying <span className="em">record\_id</span> in the input parameter <span className="em">options</span>. The user can provide a single element (which will be automatically promoted to a list internally) or a list having a single element.</p>
            </div>
          </div>
        </div>
      </div>

      <p><strong>Returns</strong></p>

      <div className="blockquote">
        <div>
          <p>A dict with the following entries if successful–</p>

          <div className="dl simple">
            <div className="dt">count\_deleted (<span className="em">long</span>) –</div>

            <div className="dd">
              <p>Total number of records deleted across all expressions.</p>
            </div>

            <div className="dt">In case of error it returns a dict - {"{"}‘status’ –</div>

            <div className="dd">
              <p>‘ERROR’, ‘message’: ‘Some error message’{"}"}</p>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</div>
