{"id":117934,"date":"2021-02-19T11:45:29","date_gmt":"2021-02-19T10:45:29","guid":{"rendered":"https:\/\/blog.jetbrains.com\/?post_type=datagrip&#038;p=117934"},"modified":"2021-10-13T10:11:58","modified_gmt":"2021-10-13T09:11:58","slug":"datagrip-2021-1-eap-2","status":"publish","type":"datagrip","link":"https:\/\/blog.jetbrains.com\/zh-hans\/datagrip\/2021\/02\/19\/datagrip-2021-1-eap-2","title":{"rendered":"DataGrip 2021.1 EAP 2"},"content":{"rendered":"<p>Hello! Here\u2019s yet another build in our EAP for <a href=\"https:\/\/www.jetbrains.com\/datagrip\/nextversion\/\" target=\"_blank\" rel=\"noopener\">DataGrip 2021.1<\/a>.<\/p>\n<h2><strong>Navigation<\/strong><\/h2>\n<h3>Straightforward actions<\/h3>\n<p>We&#8217;ve simplified the navigation and got rid of these settings:<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1270\" height=\"291\" class=\"alignnone size-large wp-image-118034\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2021\/02\/EAP-2-Killed-Settings.png\" alt=\"\"><\/p>\n<p>If you never changed these settings and had these check-boxes marked by default, the major change in 2021.1 for you is the following: <strong><em>Go to declaration (Ctrl\/Cmd+B)<\/em><\/strong><strong> on the object in SQL now leads you to the DDL, not to the database tree.<\/strong><\/p>\n<p>We also introduced a shortcut for the <em>Select in database tree <\/em>action<em>: <\/em><em>Alt+Shift+B <\/em>for Windows\/Linux and <em>Opt+Shift+B for MacOS.<\/em><\/p>\n<p>The main reasoning behind this change is the idea that the logic should be straightforward: each action should bring you to one predictable place.<\/p>\n<p>Now, if you have the the cursor on the object:<\/p>\n<ul>\n<li><strong><em>Ctrl\/Cmd+B<\/em><\/strong> shows the DDL.<\/li>\n<li><strong><em>F4<\/em><\/strong> shows data.<\/li>\n<li><strong><em>Alt\/Opt+Shift+B<\/em><\/strong> highlights the object in the database tree.<\/li>\n<\/ul>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1270\" height=\"712\" class=\"alignnone size-large wp-image-118111\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2021\/02\/EAP2-Navigation.gif\" alt=\"\"><\/p>\n<p>We do understand that some habits might be broken and we\u2019re ready to provide ways to return your previous experience. Some tips:<\/p>\n<ul>\n<li>Know the power of the keymap! If you liked <em>Ctrl\/Cmd+B<\/em> opening the database explorer, just remap the shortcut for <em>Select in database tree.<\/em><\/li>\n<li>If you liked that Ctrl\/Cmd+B or Ctrl\/Cmd+Click opened the <em>CREATE definition<\/em> when the object used in SQL was not yet created, just don&#8217;t remove these shortcuts from <em>Go to declaration <\/em>after remapping that we mentioned in the previous tip.<\/li>\n<li>If you used the unchecked &#8216;<em>Preview data editor over DDL editor<\/em>&#8216; setting and liked that double-click was opening the DDL, this behavior can be only brought back by the <a href=\"https:\/\/stackoverflow.com\/questions\/28415695\/how-do-you-set-a-value-in-the-intellij-registry#:~:text=On%20Mac%20by%20default%20it,and%20click%20or%20hit%20enter.)&amp;text=If%20you%20are%20using%20OS,option%20you&#039;re%20looking%20for.\" target=\"_blank\" rel=\"noopener\">registry key<\/a>: <code>database.legacy.navigate.to.code.from.tree.<\/code> According to our data, very few users used this flow. We also recommend using shortcuts for opening DDL for objects.<\/li>\n<\/ul>\n<p><strong>Known Problem: <\/strong>Now if you click on the table name in <em>Search Everywhere<\/em>, the DDL is opened, not the data editor. We&#8217;ll come up with the solution here.<\/p>\n<p>Please let us know if any cases are no longer covered by this new flow.<\/p>\n<h3>Database tab<\/h3>\n<p>Even though this is just a label renaming, we thought we\u2019d highlight it: the second tab in the search field actually searches not only for tables, but also views, functions, and procedures. The shortcut is <em>Cmd+O\/Ctrl+N<\/em>.<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1270\" height=\"855\" class=\"alignnone size-large wp-image-118133\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2021\/02\/EAP-2-Database-Tab.png\" alt=\"\"><\/p>\n<h2><strong>Data Editor<\/strong><\/h2>\n<h3>Edit data in MongoDB<\/h3>\n<p>A very crucial feature for thos\u0443 who work with MongoDB: starting with this version, you can edit data in MongoDB collections. The statement preview is available.<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1270\" height=\"801\" class=\"alignnone size-large wp-image-118078\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2021\/02\/EAP-2-Edit-Mongo.png\" alt=\"\"><\/p>\n<p>For now you cannot change the type of the field when editing, but we expect to add this possibility in the next EAP build.<\/p>\n<h3>New toolbar<\/h3>\n<p>We\u2019ve reworked the toolbar of the data editor. Roll-back and commit buttons are no longer displayed in automatic transaction mode, and there are two new buttons: <em>revert changes<\/em> and <em>find<\/em>.<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1270\" height=\"608\" class=\"alignnone size-large wp-image-118045\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2021\/02\/EAP-2-toolbar.png\" alt=\"\"><\/p>\n<h2><strong>Connectivity<\/strong><\/h2>\n<h3>Azure MFA support<\/h3>\n<p>Azure Active Directory interactive authentication is supported. When it is used, the browser will automatically open and let you log in.<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1270\" height=\"806\" class=\"alignnone size-large wp-image-118056\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2021\/02\/EAP-2-Azure.png\" alt=\"\"><\/p>\n<h3>Redshift driver 2.x<\/h3>\n<p>The Redshift 2.x JDBC driver is available for DataGrip users starting with version 2021.1. The major enhancement here is the <a href=\"https:\/\/youtrack.jetbrains.com\/issue\/DBE-7328\" target=\"_blank\" rel=\"noopener\">ability to cancel queries<\/a>.<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1270\" height=\"721\" class=\"alignnone size-large wp-image-118067\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2021\/02\/EAP-2-Redshift.png\" alt=\"\"><\/p>\n<h2><strong>Database explorer<\/strong><\/h2>\n<h3>Easy copy-paste of data sources<\/h3>\n<p><a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/datagrip\/2018\/05\/21\/copy-and-share-data-sources-in-datagrip\">The ability to copy and paste data sources<\/a> was introduced a long time ago. But starting with 2021.1, you can use copy, cut, and paste data sources with some of the most famous shortcuts in the world: Ctrl\/Cmd+C\/V\/X.<\/p>\n<ul>\n<li>When you copy a data source, the XML is copied into the clipboard. You can share it via messenger and also use the <em>Paste<\/em> action after copying that XML from the external place.<\/li>\n<li>If you cut and paste a data source inside one project, it will be just moved, no password required. But the password is required in all the other cases.<\/li>\n<li><em>Cut<\/em> can be undone via Ctrl\/Cmd+Z.<\/li>\n<\/ul>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1270\" height=\"896\" class=\"alignnone size-large wp-image-118122\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2021\/02\/EAP2-Cut-copy.gif\" alt=\"\"><\/p>\n<h2><strong>Coding assistance<\/strong><\/h2>\n<h3>Ambiguous column name when using CTE<\/h3>\n<p>The inspection that reports about ambiguous column names has become smarter and now takes into account columns inside common table expressions:<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1270\" height=\"792\" class=\"alignnone size-large wp-image-118089\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2021\/02\/EAP-2-Ambigous.png\" alt=\"\"><\/p>\n","protected":false},"author":395,"featured_media":0,"comment_status":"closed","ping_status":"closed","template":"","categories":[826,808,89],"tags":[6412,3810,600,2655,1043],"cross-post-tag":[],"acf":[],"_links":{"self":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/datagrip\/117934"}],"collection":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/datagrip"}],"about":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/types\/datagrip"}],"author":[{"embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/users\/395"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/comments?post=117934"}],"version-history":[{"count":4,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/datagrip\/117934\/revisions"}],"predecessor-version":[{"id":191550,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/datagrip\/117934\/revisions\/191550"}],"wp:attachment":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/media?parent=117934"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/categories?post=117934"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/tags?post=117934"},{"taxonomy":"cross-post-tag","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/cross-post-tag?post=117934"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}