|
|
|
|
| <!DOCTYPE html>
|
|
|
| <html lang="en" data-content_root="./">
|
| <head>
|
| <meta charset="utf-8" />
|
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
|
| <title>View/Edit Data — pgAdmin 4 8.6 documentation</title>
|
| <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
|
| <link rel="stylesheet" type="text/css" href="_static/style.css?v=d36593c3" />
|
|
|
| <script src="_static/documentation_options.js?v=d4c83366"></script>
|
| <script src="_static/doctools.js?v=9a2dae69"></script>
|
| <script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
|
| <script src="_static/sidebar.js"></script>
|
|
|
| <link rel="index" title="Index" href="genindex.html" />
|
| <link rel="search" title="Search" href="search.html" />
|
| <link rel="next" title="View/Edit Data Filter" href="viewdata_filter.html" />
|
| <link rel="prev" title="Query Tool Toolbar" href="query_tool_toolbar.html" />
|
| </head><body>
|
| <div class="related" role="navigation" aria-label="related navigation">
|
| <h3>Navigation</h3>
|
| <ul>
|
| <li class="right" style="margin-right: 10px">
|
| <a href="genindex.html" title="General Index"
|
| accesskey="I">index</a></li>
|
| <li class="right" >
|
| <a href="viewdata_filter.html" title="View/Edit Data Filter"
|
| accesskey="N">next</a> |</li>
|
| <li class="right" >
|
| <a href="query_tool_toolbar.html" title="Query Tool Toolbar"
|
| accesskey="P">previous</a> |</li>
|
| <li class="nav-item nav-item-0"><a href="index.html">pgAdmin 4 8.6 documentation</a> »</li>
|
| <li class="nav-item nav-item-1"><a href="developer_tools.html" accesskey="U">Developer Tools</a> »</li>
|
| <li class="nav-item nav-item-this"><a href="">View/Edit Data</a></li>
|
| </ul>
|
| </div>
|
|
|
| <div class="document">
|
| <div class="documentwrapper">
|
| <div class="bodywrapper">
|
| <div class="body" role="main">
|
|
|
| <section id="view-edit-data">
|
| <span id="editgrid"></span><h1><span class="target" id="index-0"></span>View/Edit Data<a class="headerlink" href="#view-edit-data" title="Link to this heading">¶</a></h1>
|
| <p>To view or modify data, right click on a table or view name in the
|
| <em>Object Explorer</em>. When the context menu opens, use the <em>View/Edit Data</em> menu
|
| to specify the number of rows you would like to display in the editor panel.</p>
|
| <img alt="Edit grid window" class="align-center" src="_images/editgrid.png" />
|
| <p>To modify the content of a table, each row in the table must be uniquely
|
| identifiable. If the table definition does not include an OID or a primary key,
|
| the displayed data is read only. Note that views cannot be edited; updatable
|
| views (using rules) are not supported.</p>
|
| <p>The editor features a toolbar that allows quick access to frequently used
|
| options, and a work environment divided into two panels:</p>
|
| <ul class="simple">
|
| <li><p>The upper panel displays the SQL command that was used to select the content
|
| displayed in the lower panel.</p></li>
|
| <li><p>The lower panel (the Data Grid) displays the data selected from the table or
|
| view.</p></li>
|
| </ul>
|
| <section id="the-view-edit-data-toolbar">
|
| <h2>The View/Edit Data Toolbar<a class="headerlink" href="#the-view-edit-data-toolbar" title="Link to this heading">¶</a></h2>
|
| <p>The <a class="reference internal" href="query_tool.html#query-tool"><span class="std std-ref">Query Tool</span></a> and <a class="reference internal" href="#editgrid"><span class="std std-ref">View/Edit Data</span></a> tools
|
| are actually different operating modes of the same tool. Some controls will be
|
| disabled in either mode. Please see
|
| <a class="reference internal" href="query_tool_toolbar.html#query-tool-toolbar"><span class="std std-ref">The Query Tool Toolbar</span></a> for a description of the
|
| available controls.</p>
|
| </section>
|
| <section id="the-data-grid">
|
| <span id="data-grid"></span><h2>The Data Grid<a class="headerlink" href="#the-data-grid" title="Link to this heading">¶</a></h2>
|
| <p>The top row of the data grid displays the name of each column, the data type,
|
| and if applicable, the number of characters allowed. A column that is part of
|
| the primary key will additionally be marked with [PK].</p>
|
| <p>To modify the displayed data:</p>
|
| <ul class="simple">
|
| <li><p>To change a numeric value within the grid, double-click the value to select
|
| the field. Modify the content in the square in which it is displayed.</p></li>
|
| <li><p>To change a non-numeric value within the grid, double-click the content to
|
| access the edit bubble. After modifying the contentof the edit bubble, click
|
| the <em>Ok</em> button to display your changes in the data grid, or <em>Cancel</em> to
|
| exit the edit bubble without saving.</p></li>
|
| </ul>
|
| <p>To enter a newline character, click Ctrl-Enter or Shift-Enter. Newline
|
| formatting is only displayed when the field content is accessed via an edit
|
| bubble.</p>
|
| <p>To add a new row to the table, enter data into the last (unnumbered) row of the
|
| table. As soon as you store the data, the row is assigned a row number, and a
|
| fresh empty line is added to the data grid.</p>
|
| <p>To write a SQL NULL to the table, simply leave the field empty. When you store
|
| the new row, the will server fill in the default value for that column. If you
|
| store a change to an existing row, the value NULL will explicitly be written.</p>
|
| <p>To write an empty string to the table, enter the special string ‘’ (two single
|
| quotes) in the field. If you want to write a string containing solely two single
|
| quotes to the table, you need to escape these quotes, by typing ''</p>
|
| <p>To delete a row, press the <em>Delete</em> toolbar button. A popup will open, asking
|
| you to confirm the deletion.</p>
|
| <p>To commit the changes to the server, select the <em>Save Data</em> toolbar button.</p>
|
| <p><strong>Geometry Data Viewer</strong></p>
|
| <p>If PostGIS is installed, you can view GIS objects in a map by selecting row(s)
|
| and clicking the ‘View Geometry’ button in the column. If no rows are selected,
|
| the entire data set will be rendered:</p>
|
| <img alt="Geometry Viewer Button" class="align-center" src="_images/geometry_viewer.png" />
|
| <p>You can adjust the layout by dragging the title of the panel. To view the
|
| properties of the geometries directly in map, just click the specific geometry:</p>
|
| <img alt="Geometry Viewer Property Table" class="align-center" src="_images/geometry_viewer_property_table.png" />
|
| <div class="admonition note">
|
| <p class="admonition-title">Note</p>
|
| <ul class="simple">
|
| <li><p><em>Supported data types:</em> The Geometry Viewer supports 2D and 3DM geometries in
|
| EWKB format including <cite>Point, LineString, Polygon MultiPoint, MultiLineString,
|
| MultiPolygon and GeometryCollection</cite>.</p></li>
|
| <li><p><em>SRIDs:</em> If there are geometries with different SRIDs in the same column, the
|
| viewer will render geometries with the same SRID in the map. If SRID=4326 the
|
| OSM tile layer will be added into the map.</p></li>
|
| <li><p><em>Data size:</em> For performance reasons, the viewer will render no more than
|
| 100000 geometries, totaling up to 20MB.</p></li>
|
| <li><p><em>Internet access:</em> An internet connection is required for the Geometry Viewer
|
| to function correctly.</p></li>
|
| </ul>
|
| </div>
|
| <p><strong>JSON Data Editor</strong></p>
|
| <p>A built in json editor is provided for <em>JSON/JSONB Data</em>.Double clicking on json/jsonb
|
| data type cell in data grid will open JSON Editor.Editor provides different mode to
|
| view and edit json data.</p>
|
| <img alt="Json Editor" class="align-center" src="_images/json_editor_modes.png" />
|
| <p><em>Code Mode</em>:
|
| Provides way to format & compact json data.Also provides ability to repair json data
|
| by fixing quotes and escape characters, removing comments and JSONP notation and
|
| turn JavaScript objects into JSON.</p>
|
| <p><em>Tree Mode</em>:
|
| Enabled to change, add, move, remove, and duplicate fields and values.Provides ability
|
| to searh & hilight data.</p>
|
| <p><em>Form Mode</em>:
|
| Allows only to edit values in json data there by providing ability to keep data structure
|
| unchanged while editing.</p>
|
| <p><em>Preview Mode</em>:
|
| Provides ability to check data before saving and also shows size of current json data.
|
| Format and compact json data as well.</p>
|
| <p><em>Editor Toolbar</em></p>
|
| <p>Different options are provided to manipulate json data.</p>
|
| <p>Code/Preview mode:</p>
|
| <img alt="Json Editor Code/Preview mode Tool Bar" class="align-center" src="_images/json_editor_code_preview_tool_bar.png" />
|
| <p>Tree/Form mode:</p>
|
| <img alt="Json Editor Tree/Form mode Tool Bar" class="align-center" src="_images/json_editor_tree_form_mode_tool_bar.png" />
|
| <table class="longtable docutils align-default">
|
| <colgroup>
|
| <col style="width: 16.7%" />
|
| <col style="width: 50.0%" />
|
| <col style="width: 33.3%" />
|
| </colgroup>
|
| <thead>
|
| <tr class="row-odd"><th class="head"><p>Icon</p></th>
|
| <th class="head"><p>Behavior</p></th>
|
| <th class="head"><p>Available in mode</p></th>
|
| </tr>
|
| </thead>
|
| <tbody>
|
| <tr class="row-even"><td><p><em>Format Json</em></p></td>
|
| <td><p>Click to <em>Format Json</em> format json data with proper indentation.</p></td>
|
| <td><p>Code, Preview</p></td>
|
| </tr>
|
| <tr class="row-odd"><td><p><em>Compact Json</em></p></td>
|
| <td><p>Click to <em>Compact Json</em> get compacted json data.</p></td>
|
| <td><p>Code, Preview</p></td>
|
| </tr>
|
| <tr class="row-even"><td><p><em>Sort</em></p></td>
|
| <td><p>Click to <em>Sort</em> icon to set sorting criteria for the data using file values.</p></td>
|
| <td><p>Code, Preview, Tree</p></td>
|
| </tr>
|
| <tr class="row-odd"><td><p><em>Transform</em></p></td>
|
| <td><p>Click to <em>Transform</em> to filter data using JSME query language.</p></td>
|
| <td><p>Code, Preview, Tree</p></td>
|
| </tr>
|
| <tr class="row-even"><td><p><em>Undo</em></p></td>
|
| <td><p>Click to <em>Undo</em> to undo last action performed on data .</p></td>
|
| <td><p>Code, Preview, Tree, From</p></td>
|
| </tr>
|
| <tr class="row-odd"><td><p><em>Redo</em></p></td>
|
| <td><p>Click to <em>Redo</em> to repat last action performed on data .</p></td>
|
| <td><p>Code, Preview, Tree, From</p></td>
|
| </tr>
|
| <tr class="row-even"><td><p><em>Mode</em></p></td>
|
| <td><p>Click to <em>Mode</em> dropdown to change dipaly mode of editor.Different modes avaialble
|
| are Code, Preview, Tree, From.</p></td>
|
| <td><p>Code, Tree, From, Preview</p></td>
|
| </tr>
|
| <tr class="row-odd"><td><p><em>Expand All</em></p></td>
|
| <td><p>Click to <em>Expand All</em> to expand json data.</p></td>
|
| <td><p>Tree, From</p></td>
|
| </tr>
|
| <tr class="row-even"><td><p><em>Collapse All</em></p></td>
|
| <td><p>Click to <em>Redo</em> to collapse json data.</p></td>
|
| <td><p>Tree, From</p></td>
|
| </tr>
|
| <tr class="row-odd"><td><p><em>Search Box</em></p></td>
|
| <td><p>Enter partial/complete string to search in data.</p></td>
|
| <td><p>Tree, From</p></td>
|
| </tr>
|
| </tbody>
|
| </table>
|
| </section>
|
| <section id="sort-filter-options-dialog">
|
| <h2>Sort/Filter options dialog<a class="headerlink" href="#sort-filter-options-dialog" title="Link to this heading">¶</a></h2>
|
| <p>You can access <em>Sort/Filter options dialog</em> by clicking on Sort/Filter button.
|
| This allows you to specify an SQL Filter to limit the data displayed and data
|
| sorting options in the edit grid window:</p>
|
| <img alt="Edit grid filter dialog window" class="align-center" src="_images/editgrid_filter_dialog.png" />
|
| <ul class="simple">
|
| <li><p>Use <em>SQL Filter</em> to provide SQL filtering criteria. These will be added to
|
| the “WHERE” clause of the query used to retrieve the data. For example,
|
| you might enter:</p></li>
|
| </ul>
|
| <div class="highlight-sql notranslate"><div class="highlight"><pre><span></span><span class="n">id</span><span class="w"> </span><span class="o">></span><span class="w"> </span><span class="mi">25</span><span class="w"> </span><span class="k">AND</span><span class="w"> </span><span class="n">created</span><span class="w"> </span><span class="o">></span><span class="w"> </span><span class="s1">'2018-01-01'</span>
|
| </pre></div>
|
| </div>
|
| <ul class="simple">
|
| <li><p>Use <em>Data Sorting</em> to sort the data in the output grid</p></li>
|
| </ul>
|
| <p>To add new column(s) in data sorting grid, click on the [+] icon.</p>
|
| <ul class="simple">
|
| <li><p>Use the drop-down <em>Column</em> to select the column you want to sort.</p></li>
|
| <li><p>Use the drop-down <em>Order</em> to select the sort order for the column.</p></li>
|
| </ul>
|
| <p>To delete a row from the grid, click the trash icon.</p>
|
| <ul class="simple">
|
| <li><p>Click the <em>Save</em> button to save work.</p></li>
|
| <li><p>Click the <em>Close</em> button to discard current changes and close the dialog.</p></li>
|
| </ul>
|
| <div class="toctree-wrapper compound">
|
| <ul>
|
| <li class="toctree-l1"><a class="reference internal" href="viewdata_filter.html">View/Edit Data Filter</a></li>
|
| </ul>
|
| </div>
|
| </section>
|
| <section id="promote-view-edit-data-to-query-tool">
|
| <h2>Promote View/Edit Data to Query Tool<a class="headerlink" href="#promote-view-edit-data-to-query-tool" title="Link to this heading">¶</a></h2>
|
| <p>A View/Edit Data tab can be converted to a Query Tool Tab just by editing the query. Once you start editing, it will ask if you really want to move away from View/Edit.</p>
|
| <img alt="Promote View/Edit Data tab to Query Tool tab warning" class="align-center" src="_images/promote_view_edit_data_warning.png" />
|
| <p>You can disable the dialog by selecting the “Don’t Ask again” checkbox. If you wish to resume the confirmation dialog, you can do it from “Prefrences -> Query Tool -> Editor -> Show View/Edit Data Promotion Warning?”</p>
|
| <p>Once you chose to continue, you won’t be able to use the features of View/Edit mode like the filter and sorting options, limit, etc. It is a one-way conversion. It will be a query tool now.</p>
|
| </section>
|
| </section>
|
|
|
|
|
| <div class="clearer"></div>
|
| </div>
|
| </div>
|
| </div>
|
| <div class="sphinxsidebar" role="navigation" aria-label="main navigation">
|
| <div class="sphinxsidebarwrapper">
|
| <div>
|
| <h3><a href="index.html">Table of Contents</a></h3>
|
| <ul>
|
| <li><a class="reference internal" href="#">View/Edit Data</a><ul>
|
| <li><a class="reference internal" href="#the-view-edit-data-toolbar">The View/Edit Data Toolbar</a></li>
|
| <li><a class="reference internal" href="#the-data-grid">The Data Grid</a></li>
|
| <li><a class="reference internal" href="#sort-filter-options-dialog">Sort/Filter options dialog</a></li>
|
| <li><a class="reference internal" href="#promote-view-edit-data-to-query-tool">Promote View/Edit Data to Query Tool</a></li>
|
| </ul>
|
| </li>
|
| </ul>
|
|
|
| </div>
|
| <h3><a href="index.html">Table of Contents</a></h3>
|
| <ul class="current">
|
| <li class="toctree-l1"><a class="reference internal" href="getting_started.html">Getting Started</a></li>
|
| <li class="toctree-l1"><a class="reference internal" href="external_database.html">External database for pgAdmin user settings</a></li>
|
| <li class="toctree-l1"><a class="reference internal" href="connecting.html">Connecting To A Server</a></li>
|
| <li class="toctree-l1"><a class="reference internal" href="managing_cluster_objects.html">Managing Cluster Objects</a></li>
|
| <li class="toctree-l1"><a class="reference internal" href="managing_database_objects.html">Managing Database Objects</a></li>
|
| <li class="toctree-l1"><a class="reference internal" href="modifying_tables.html">Creating or Modifying a Table</a></li>
|
| <li class="toctree-l1"><a class="reference internal" href="management_basics.html">Management Basics</a></li>
|
| <li class="toctree-l1"><a class="reference internal" href="backup_and_restore.html">Backup and Restore</a></li>
|
| <li class="toctree-l1 current"><a class="reference internal" href="developer_tools.html">Developer Tools</a><ul class="current">
|
| <li class="toctree-l2"><a class="reference internal" href="debugger.html">Debugger</a></li>
|
| <li class="toctree-l2"><a class="reference internal" href="query_tool.html">Query Tool</a></li>
|
| <li class="toctree-l2 current"><a class="current reference internal" href="#">View/Edit Data</a></li>
|
| <li class="toctree-l2"><a class="reference internal" href="schema_diff.html">Schema Diff</a></li>
|
| <li class="toctree-l2"><a class="reference internal" href="erd_tool.html">ERD Tool</a></li>
|
| <li class="toctree-l2"><a class="reference internal" href="psql_tool.html">PSQL Tool</a></li>
|
| </ul>
|
| </li>
|
| <li class="toctree-l1"><a class="reference internal" href="processes.html">Processes</a></li>
|
| <li class="toctree-l1"><a class="reference internal" href="pgagent.html">pgAgent</a></li>
|
| <li class="toctree-l1"><a class="reference internal" href="contributions.html">pgAdmin Project Contributions</a></li>
|
| <li class="toctree-l1"><a class="reference internal" href="release_notes.html">Release Notes</a></li>
|
| <li class="toctree-l1"><a class="reference internal" href="licence.html">Licence</a></li>
|
| </ul>
|
|
|
| <search id="searchbox" style="display: none" role="search">
|
| <h3 id="searchlabel">Quick search</h3>
|
| <div class="searchformwrapper">
|
| <form class="search" action="search.html" method="get">
|
| <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
|
| <input type="submit" value="Go" />
|
| </form>
|
| </div>
|
| </search>
|
| <script>document.getElementById('searchbox').style.display = "block"</script>
|
| </div>
|
| <div id="sidebarbutton" title="Collapse sidebar">
|
| <span>«</span>
|
| </div>
|
|
|
| </div>
|
| <div class="clearer"></div>
|
| </div>
|
| <div class="related" role="navigation" aria-label="related navigation">
|
| <h3>Navigation</h3>
|
| <ul>
|
| <li class="right" style="margin-right: 10px">
|
| <a href="genindex.html" title="General Index"
|
| >index</a></li>
|
| <li class="right" >
|
| <a href="viewdata_filter.html" title="View/Edit Data Filter"
|
| >next</a> |</li>
|
| <li class="right" >
|
| <a href="query_tool_toolbar.html" title="Query Tool Toolbar"
|
| >previous</a> |</li>
|
| <li class="nav-item nav-item-0"><a href="index.html">pgAdmin 4 8.6 documentation</a> »</li>
|
| <li class="nav-item nav-item-1"><a href="developer_tools.html" >Developer Tools</a> »</li>
|
| <li class="nav-item nav-item-this"><a href="">View/Edit Data</a></li>
|
| </ul>
|
| </div>
|
| <div class="footer" role="contentinfo">
|
| <div class="related" role="navigation" aria-label="related navigation">
|
| <ul>
|
| <li class="left" style="margin-left: 10px">© Copyright (C) 2013 - 2024, The pgAdmin Development Team.</li>
|
| <li class="right" style="margin-right: 10px"><a href="genindex.html" title="General Index" accesskey="I">index</a></li>
|
| <li class="right" ><a href="viewdata_filter.html" title="View/Edit Data Filter" accesskey="N">next</a> |</li>
|
| <li class="right" ><a href="query_tool_toolbar.html" title="Query Tool Toolbar" accesskey="P">previous</a> |</li>
|
| </ul>
|
| </div>
|
| </div>
|
| </body>
|
| </html> |