Format a SQL Statement

<p>Perform this task to improve readability of SQL statements. This task changes only the presentation form of SQL statements, but their execution logic and meanings remain unchanged.</p> <p><strong><span style="font-size:18px">Prerequisites</span></strong></p> <p>You have successfully logged in to a database. For more information, see <a href="http://pinganyun.com/ssr/help/database/DMS/5d5e6ce2e9ca5f712e340eb2.5d5f481e1c51aa7124c5e3f9.5d5f486b1c51aa7124c5e3fa" target="_blank">Log in to an RDS MySQL Database</a> or <a href="http://pinganyun.com/ssr/help/database/DMS/5d5e6ce2e9ca5f712e340eb2.5d5f481e1c51aa7124c5e3f9.5d5f48ed1c51aa7124c5e3fb" target="_blank">Log in to an RDS PostgreSQL Database</a>.</p> <p><strong><span style="font-size:18px">Usage Guidelines</span></strong></p> <p>You can format only SQL statements of RDS MySQL and RDS PostgreSQL databases.</p> <p><strong><span style="font-size:18px">Procedures</span></strong></p> <ol> <li>Log in to the DMS Console.</li> <li>In the left navigation pane, click <strong>Quick Database Login</strong> to enter the <strong>Quick Database Login</strong> page.</li> <li>Click the target login tab, and then enter the domain name, port, database name, database username, and password.</li> <li>Click <strong>Log in Database</strong> to enter the <strong>Database Management</strong> page.</li> <li>Click the <strong>SQL Operation</strong> tab, and then select the target <strong>database</strong> in the right area of the page.</li> <li>In the SQL execution window, enter a SQL statement. This section uses the RDS MySQL database as an example.</li> <li>Click<strong> Format</strong>.</li> </ol> <p>&nbsp;<img src="https://obs-cn-shanghai.yun.pingan.com/pcp-portal/20203006151247-1005b5af9cfa.png" style="height:293px; width:830px" /></p> <p><strong><span style="font-size:18px">Result</span></strong></p> <p>The SQL execution window displays the SQL statement that has been formatted.</p> <p>&nbsp;<img src="https://obs-cn-shanghai.yun.pingan.com/pcp-portal/20203006151316-106044a59e13.png" style="height:295px; width:830px" /></p> <p>&nbsp;</p>
Did the above content solve your problem? Yes No
Please complete information!

Call us

400-151-8800

Email us

cloud@pingan.com

Online customer service

Instant reply

Technical Support

cloud products