> ## 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::LockTableRequest

> gpudb::LockTableRequest — 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#ae6ac44ea2b9603bbad231212560ab451">GPUdb::lockTable</a>. <a href="#details">More...</a></p>
    <p><code>#include \<<a className="el" href="/content/api/cpp/lock__table_8h_source">gpudb/protocol/lock\_table.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:a96e944f27a8d7a7f1878ccc83488e08e" id="r_a96e944f27a8d7a7f1878ccc83488e08e">
        <td className="memItemLeft" align="right" valign="top"> </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#a96e944f27a8d7a7f1878ccc83488e08e">LockTableRequest</a> ()</td>
      </tr>

      <tr className="memdesc:a96e944f27a8d7a7f1878ccc83488e08e">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">Constructs a <a className="el" href="/content/api/cpp/structgpudb_1_1LockTableRequest" title="A set of parameters for GPUdb::lockTable.">LockTableRequest</a> object with default parameters. <br /></td>
      </tr>

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

      <tr className="memitem:ada93d41c525ab1545011241eba41b417" id="r_ada93d41c525ab1545011241eba41b417">
        <td className="memItemLeft" align="right" valign="top"> </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#ada93d41c525ab1545011241eba41b417">LockTableRequest</a> (const std::string \&tableName\_, const std::string \&lockType\_, const std::map\< std::string, std::string > \&options\_)</td>
      </tr>

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

      <tr className="separator:ada93d41c525ab1545011241eba41b417">
        <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:a5b7ab7a78a3994a37b1c9bdc08761c57" id="r_a5b7ab7a78a3994a37b1c9bdc08761c57">
        <td className="memItemLeft" align="right" valign="top">std::string </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#a5b7ab7a78a3994a37b1c9bdc08761c57">tableName</a></td>
      </tr>

      <tr className="memdesc:a5b7ab7a78a3994a37b1c9bdc08761c57">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">Name of the table to be locked, in \[ schema\_name. ]table\_name format, using standard <a href="/content/concepts/tables/#table-name-resolution" target="_top">name resolution rules</a>. <br /></td>
      </tr>

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

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

      <tr className="memdesc:ad0ceaa81ab3b5a95ec82e47f37cfb008">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">The type of lock being applied to the table. <br /></td>
      </tr>

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

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

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

      <tr className="separator:a9f613059140cf8f23711e0d4dc605b55">
        <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#ae6ac44ea2b9603bbad231212560ab451">GPUdb::lockTable</a>. </p>
      <p>Manages global access to a table's data. By default a table has a <a className="el" href="#ad0ceaa81ab3b5a95ec82e47f37cfb008">lockType</a> of <a className="el" href="/content/api/cpp/namespacegpudb#a3850006e51cb92262ee99c33e236be8e">read\_write</a>, indicating all operations are permitted. A user may request a <a className="el" href="/content/api/cpp/namespacegpudb#a13f9c3cae84296683c96fee7fc9d0559">read\_only</a> or a <a className="el" href="/content/api/cpp/namespacegpudb#a778a0ff86149e98e2801e79e77a9d808">write\_only</a> lock, after which only read or write operations, respectively, are permitted on the table until the lock is removed. When <a className="el" href="#ad0ceaa81ab3b5a95ec82e47f37cfb008">lockType</a> is <a className="el" href="/content/api/cpp/namespacegpudb#a1765927f79afe041ba87edf363884e26">no\_access</a> then no operations are permitted on the table. The lock status can be queried by setting <a className="el" href="#ad0ceaa81ab3b5a95ec82e47f37cfb008">lockType</a> to <a className="el" href="/content/api/cpp/namespacegpudb#aaea6e5cd5925eb2a89b9f638432e8055">status</a>. </p>
      <p className="definition">Definition at line <a className="el" href="/content/api/cpp/lock__table_8h_source#l00026">26</a> of file <a className="el" href="/content/api/cpp/lock__table_8h_source">lock\_table.h</a>.</p>
    </div>

    <h2 className="groupheader">Constructor & Destructor Documentation</h2>
    <h2 className="memtitle"><span className="permalink"><a href="#a96e944f27a8d7a7f1878ccc83488e08e">◆ </a></span>LockTableRequest() <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::LockTableRequest::LockTableRequest </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_1LockTableRequest" title="A set of parameters for GPUdb::lockTable.">LockTableRequest</a> object with default parameters. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/lock__table_8h_source#l00031">31</a> of file <a className="el" href="/content/api/cpp/lock__table_8h_source">lock\_table.h</a>.</p>
      </div>
    </div>

    <h2 className="memtitle"><span className="permalink"><a href="#ada93d41c525ab1545011241eba41b417">◆ </a></span>LockTableRequest() <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::LockTableRequest::LockTableRequest </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::string &</td>
                  <td className="paramname"><span className="paramname"><span className="em">lockType\_</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_1LockTableRequest" title="A set of parameters for GPUdb::lockTable.">LockTableRequest</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 to be locked, in \[schema\_name.]table\_name format, using standard <a href="/content/concepts/tables/#table-name-resolution" target="_top">name resolution rules</a>. It must be a currently existing table or view. </td>
              </tr>

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

                <td>
                  The type of lock being applied to the table. Setting it to <a className="el" href="/content/api/cpp/namespacegpudb#aaea6e5cd5925eb2a89b9f638432e8055">status</a> will return the current lock status of the table without changing it. Supported values:

                  <ul>
                    <li> <a className="el" href="/content/api/cpp/namespacegpudb#aaea6e5cd5925eb2a89b9f638432e8055">lock\_table\_status</a>: Show locked status. </li>
                    <li> <a className="el" href="/content/api/cpp/namespacegpudb#a1765927f79afe041ba87edf363884e26">lock\_table\_no\_access</a>: Allow no read/write operations. </li>
                    <li> <a className="el" href="/content/api/cpp/namespacegpudb#a13f9c3cae84296683c96fee7fc9d0559">lock\_table\_read\_only</a>: Allow only read operations. </li>
                    <li> <a className="el" href="/content/api/cpp/namespacegpudb#a778a0ff86149e98e2801e79e77a9d808">lock\_table\_write\_only</a>: Allow only write operations. </li>
                    <li> <a className="el" href="/content/api/cpp/namespacegpudb#a3850006e51cb92262ee99c33e236be8e">lock\_table\_read\_write</a>: Allow all read/write operations. </li>
                  </ul>

                  The default value is <a className="el" href="/content/api/cpp/namespacegpudb#aaea6e5cd5925eb2a89b9f638432e8055">lock\_table\_status</a>.
                </td>
              </tr>

              <tr>
                <td className="paramdir">\[in]</td>
                <td className="paramname">options\_</td>
                <td>Optional parameters. 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/lock__table_8h_source#l00074">74</a> of file <a className="el" href="/content/api/cpp/lock__table_8h_source">lock\_table.h</a>.</p>
      </div>
    </div>

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

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

      <div className="memdoc">
        <p>The type of lock being applied to the table. </p>
        <p>Setting it to <a className="el" href="/content/api/cpp/namespacegpudb#aaea6e5cd5925eb2a89b9f638432e8055">status</a> will return the current lock status of the table without changing it. Supported values: </p>

        <ul>
          <li> <a className="el" href="/content/api/cpp/namespacegpudb#aaea6e5cd5925eb2a89b9f638432e8055">lock\_table\_status</a>: Show locked status. </li>
          <li> <a className="el" href="/content/api/cpp/namespacegpudb#a1765927f79afe041ba87edf363884e26">lock\_table\_no\_access</a>: Allow no read/write operations. </li>
          <li> <a className="el" href="/content/api/cpp/namespacegpudb#a13f9c3cae84296683c96fee7fc9d0559">lock\_table\_read\_only</a>: Allow only read operations. </li>
          <li> <a className="el" href="/content/api/cpp/namespacegpudb#a778a0ff86149e98e2801e79e77a9d808">lock\_table\_write\_only</a>: Allow only write operations. </li>
          <li> <a className="el" href="/content/api/cpp/namespacegpudb#a3850006e51cb92262ee99c33e236be8e">lock\_table\_read\_write</a>: Allow all read/write operations. </li>
        </ul>

        <p>The default value is <a className="el" href="/content/api/cpp/namespacegpudb#aaea6e5cd5925eb2a89b9f638432e8055">lock\_table\_status</a>. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/lock__table_8h_source#l00110">110</a> of file <a className="el" href="/content/api/cpp/lock__table_8h_source">lock\_table.h</a>.</p>
      </div>
    </div>

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

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

      <div className="memdoc">
        <p>Optional parameters. </p>
        <p>The default value is an empty map. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/lock__table_8h_source#l00115">115</a> of file <a className="el" href="/content/api/cpp/lock__table_8h_source">lock\_table.h</a>.</p>
      </div>
    </div>

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

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

      <div className="memdoc">
        <p>Name of the table to be locked, in \[ schema\_name. ]table\_name format, using standard <a href="/content/concepts/tables/#table-name-resolution" target="_top">name resolution rules</a>. </p>
        <p>It must be a currently existing table or view. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/lock__table_8h_source#l00088">88</a> of file <a className="el" href="/content/api/cpp/lock__table_8h_source">lock\_table.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/lock__table_8h_source">lock\_table.h</a></li>
    </ul>
  </div>
</div>
