This is an automated email from the ASF dual-hosted git repository.
git-site-role pushed a commit to branch asf-site
in repository https://gitbox.apache.org/repos/asf/incubator-netbeans-website.git
The following commit(s) were added to refs/heads/asf-site by this push:
new f6d445f Automated site publishing by Jenkins build 559
f6d445f is described below
commit f6d445fa0382112c0913599555f8f4ad74f80c8a
Author: jenkins <[email protected]>
AuthorDate: Mon Jan 28 20:53:30 2019 +0000
Automated site publishing by Jenkins build 559
---
content/kb/docs/ide/mysql.html | 232 +++++++++++++++++++++++++++++++----------
1 file changed, 178 insertions(+), 54 deletions(-)
diff --git a/content/kb/docs/ide/mysql.html b/content/kb/docs/ide/mysql.html
index 6b39e48..761d751 100644
--- a/content/kb/docs/ide/mysql.html
+++ b/content/kb/docs/ide/mysql.html
@@ -102,8 +102,8 @@
<li><a href="#_creating_and_connecting_to_the_database_instance">Creating and
Connecting to the Database Instance</a></li>
<li><a href="#_creating_database_tables">Creating Database Tables</a>
<ul class="sectlevel2">
-<li><a href="#_using_the_sql_editor">Using the SQL Editor</a></li>
-<li><a href="#_using_the_create_table_dialog">Using the Create Table
Dialog</a></li>
+<li><a href="#usingSQLEditor">Using the SQL Editor</a></li>
+<li><a href="#usingCreateTable">Using the Create Table Dialog</a></li>
</ul>
</li>
<li><a href="#_working_with_table_data">Working with Table Data</a></li>
@@ -142,9 +142,17 @@ This tutorial assumes that you already have the MySQL
RDBMS installed and config
<div class="olist arabic">
<ol class="arabic">
<li>
-<p>Right-click the Databases node in the Services window and choose Register
MySQL Server to open the MySQL Server Properties dialog box.
-image::images/mysql-props1.png[]</p>
+<p>Right-click the Databases node in the Services window and choose Register
MySQL Server to open the MySQL Server Properties dialog box.</p>
</li>
+</ol>
+</div>
+<div class="imageblock">
+<div class="content">
+<img src="images/mysql-props1.png" alt="mysql props1">
+</div>
+</div>
+<div class="olist arabic">
+<ol class="arabic" start="2">
<li>
<p>Confirm that the server host name and port are correct.</p>
</li>
@@ -154,14 +162,23 @@ image::images/mysql-props1.png[]</p>
<p>Notice that the IDE enters <code>localhost</code> as the default server
host name and <code>3306</code> as the default server port number.</p>
</div>
<div class="olist arabic">
-<ol class="arabic">
+<ol class="arabic" start="3">
<li>
<p>Enter the Administrator user name (if not displayed).</p>
</li>
</ol>
</div>
-<div class="paragraph">
-<p>*Note: *You need administrative access to be able to create and remove
databases.</p>
+<div class="admonitionblock note">
+<table>
+<tr>
+<td class="icon">
+<i class="fa icon-note" title="Note"></i>
+</td>
+<td class="content">
+You need administrative access to be able to create and remove databases.
+</td>
+</tr>
+</table>
</div>
<div class="olist arabic">
<ol class="arabic">
@@ -170,8 +187,17 @@ image::images/mysql-props1.png[]</p>
</li>
</ol>
</div>
-<div class="paragraph">
-<p>*Note: * A blank password can also be a password.</p>
+<div class="admonitionblock note">
+<table>
+<tr>
+<td class="icon">
+<i class="fa icon-note" title="Note"></i>
+</td>
+<td class="content">
+A blank password can also be a password.
+</td>
+</tr>
+</table>
</div>
<div class="olist arabic">
<ol class="arabic">
@@ -181,25 +207,65 @@ image::images/mysql-props1.png[]</p>
</ol>
</div>
<div class="paragraph">
-<p>The Admin Properties tab is then displayed, allowing you to enter
information for controlling the MySQL Server.
-6. In the Path/URL to admin tool field, type or browse to the location of your
MySQL Administration application such as the MySQL Admin Tool, PhpMyAdmin, or
other web-based administration tools.</p>
+<p>The Admin Properties tab is then displayed, allowing you to enter
information for controlling the MySQL Server.</p>
</div>
-<div class="paragraph">
-<p>*Note: *<code>mysqladmin</code> is the MySQL admin tool found in the
<code>bin</code> folder of the MySQL installation directory. It is a
command-line tool and not ideal for use with the IDE.</p>
+<div class="olist arabic">
+<ol class="arabic" start="6">
+<li>
+<p>In the Path/URL to admin tool field, type or browse to the location of your
MySQL Administration application such as the MySQL Admin Tool, PhpMyAdmin, or
other web-based administration tools.</p>
+</li>
+</ol>
</div>
-<div class="paragraph">
-<p>Type any arguments for the admin tool in the Arguments field.
-7.
-In the Path to start command, type or browse to the location of the MySQL
start command. To find the start command, look for <code>mysqld</code> in the
<code>bin</code> folder of the MySQL installation directory.</p>
+<div class="admonitionblock note">
+<table>
+<tr>
+<td class="icon">
+<i class="fa icon-note" title="Note"></i>
+</td>
+<td class="content">
+<code>mysqladmin</code> is the MySQL admin tool found in the <code>bin</code>
folder of the MySQL installation directory. It is a command-line tool and not
ideal for use with the IDE.
+</td>
+</tr>
+</table>
</div>
<div class="paragraph">
-<p>*Note: * The recommended binary for Unix and NetWare is
<code>mysql_safe</code>. The start command may also vary if MySQL was installed
as part of an AMP installation.</p>
+<p>Type any arguments for the admin tool in the Arguments field.</p>
+</div>
+<div class="olist arabic">
+<ol class="arabic" start="7">
+<li>
+<p>In the Path to start command, type or browse to the location of the MySQL
start command. To find the start command, look for <code>mysqld</code> in the
<code>bin</code> folder of the MySQL installation directory.</p>
+</li>
+</ol>
+</div>
+<div class="admonitionblock note">
+<table>
+<tr>
+<td class="icon">
+<i class="fa icon-note" title="Note"></i>
+</td>
+<td class="content">
+The recommended binary for Unix and NetWare is <code>mysql_safe</code>. The
start command may also vary if MySQL was installed as part of an AMP
installation.
+</td>
+</tr>
+</table>
</div>
<div class="paragraph">
-<p>Type any arguments for the start command in the Arguments field.
-8. In the Path to stop command field, type or browse to the location of the
MySQL stop command. This is usually the path to <code>mysqladmin</code> in the
<code>bin</code> folder of the MySQL installation directory. If the command is
<code>mysqladmin</code>, in the Arguments field, type <code>-u root stop</code>
to grant <code>root</code> permissions for stopping the server.
-9.
-When finished, the Admin Properties tab should resemble the following figure.
If you are satified with your configuration, click OK.</p>
+<p>Type any arguments for the start command in the Arguments field.</p>
+</div>
+<div class="olist arabic">
+<ol class="arabic" start="8">
+<li>
+<p>In the Path to stop command field, type or browse to the location of the
MySQL stop command. This is usually the path to <code>mysqladmin</code> in the
<code>bin</code> folder of the MySQL installation directory. If the command is
<code>mysqladmin</code>, in the Arguments field, type <code>-u root stop</code>
to grant <code>root</code> permissions for stopping the server.</p>
+</li>
+</ol>
+</div>
+<div class="olist arabic">
+<ol class="arabic" start="9">
+<li>
+<p>When finished, the Admin Properties tab should resemble the following
figure. If you are satified with your configuration, click OK.</p>
+</li>
+</ol>
</div>
<div class="imageblock">
<div class="content">
@@ -241,15 +307,34 @@ When finished, the Admin Properties tab should resemble
the following figure. If
</ol>
</div>
<div class="paragraph">
-<p>The Create MySQL Database dialog box opens.
-2. In the Create MySQL Database dialog box, type the name of the new database.
We will use <code>MyNewDatabase</code> for this tutorial. Leave the checkbox
unselected at this time.
-image::images/create-db-dbx.png[]</p>
+<p>The Create MySQL Database dialog box opens.</p>
</div>
-<div class="paragraph">
-<p>*Note: *You can also grant full access to a given user. By default, only
the admin user has the permissions to perform certain commands. The drop down
list lets you assign these permissions to a specified user.</p>
+<div class="olist arabic">
+<ol class="arabic" start="2">
+<li>
+<p>In the Create MySQL Database dialog box, type the name of the new database.
We will use <code>MyNewDatabase</code> for this tutorial. Leave the checkbox
unselected at this time.</p>
+</li>
+</ol>
+</div>
+<div class="imageblock">
+<div class="content">
+<img src="images/create-db-dbx.png" alt="create db dbx">
+</div>
+</div>
+<div class="admonitionblock note">
+<table>
+<tr>
+<td class="icon">
+<i class="fa icon-note" title="Note"></i>
+</td>
+<td class="content">
+You can also grant full access to a given user. By default, only the admin
user has the permissions to perform certain commands. The drop down list lets
you assign these permissions to a specified user.
+</td>
+</tr>
+</table>
</div>
<div class="olist arabic">
-<ol class="arabic">
+<ol class="arabic" start="3">
<li>
<p>Click OK.</p>
</li>
@@ -259,7 +344,7 @@ image::images/create-db-dbx.png[]</p>
<p>The new database appears under the MySQL Server node in the Services
window.</p>
</div>
<div class="olist arabic">
-<ol class="arabic">
+<ol class="arabic" start="4">
<li>
<p>Right-click the new database node and choose Connect in the popup menu to
open the connection to the database.</p>
</li>
@@ -292,7 +377,7 @@ image::images/create-db-dbx.png[]</p>
</ol>
</div>
<div class="sect2">
-<h3 id="_using_the_sql_editor">Using the SQL Editor</h3>
+<h3 id="usingSQLEditor">Using the SQL Editor</h3>
<div class="paragraph">
<p>In this exercise you will use the SQL editor to create the
<code>Counselor</code> table.</p>
</div>
@@ -311,7 +396,7 @@ image::images/create-db-dbx.png[]</p>
</div>
<div class="listingblock">
<div class="content">
-<pre class="prettyprint highlight"><code class="language-java"
data-lang="java">CREATE TABLE Counselor (
+<pre class="prettyprint highlight"><code class="language-sql"
data-lang="sql">CREATE TABLE Counselor (
id SMALLINT UNSIGNED NOT NULL AUTO_INCREMENT,
firstName VARCHAR (50),
nickName VARCHAR (50),
@@ -323,12 +408,36 @@ image::images/create-db-dbx.png[]</p>
);</code></pre>
</div>
</div>
-<div class="paragraph">
-<p>*Note: *Queries formed in the SQL Editor are parsed in Structured Query
Language (SQL). SQL adheres to strict syntax rules which you should be familiar
with when working in the IDE’s Editor. Upon running a query, feedback
from the SQL engine is generated in the Output window indicating whether
execution was successful or not.
-4. To execute the query, either click the Run SQL
(image::images/run-sql-button.png[]) button in the task bar at the top
(Ctrl-Shift-E), or right-click within the SQL Editor and choose Run Statement.
The IDE generates the <code>Counselor</code> table in the database, and you
receive a message similar to the following in the Output window.
-image::images/create-counselor-query.png[]
-5.
-To verify changes, right-click the Tables node in the Database Explorer and
choose Refresh. The Refresh option updates the Database Explorer’s UI
component to the current status of the specified database. Note that the new
<code>Counselor</code> table node (image::images/table-node.png[]) now
displays under Tables in the Database explorer. If you expand the table node
you can see the columns (fields) you created, starting with the primary key
(image::images/primary-key-icon.png[]).</p>
+<div class="admonitionblock note">
+<table>
+<tr>
+<td class="icon">
+<i class="fa icon-note" title="Note"></i>
+</td>
+<td class="content">
+Queries formed in the SQL Editor are parsed in Structured Query Language
(SQL). SQL adheres to strict syntax rules which you should be familiar with
when working in the IDE’s Editor. Upon running a query, feedback from the
SQL engine is generated in the Output window indicating whether execution was
successful or not.
+</td>
+</tr>
+</table>
+</div>
+<div class="olist arabic">
+<ol class="arabic" start="4">
+<li>
+<p>To execute the query, either click the Run SQL
(image::images/run-sql-button.png[]) button in the task bar at the top
(Ctrl-Shift-E), or right-click within the SQL Editor and choose Run Statement.
The IDE generates the <code>Counselor</code> table in the database, and you
receive a message similar to the following in the Output window.</p>
+</li>
+</ol>
+</div>
+<div class="imageblock">
+<div class="content">
+<img src="images/create-counselor-query.png" alt="create counselor query">
+</div>
+</div>
+<div class="olist arabic">
+<ol class="arabic" start="5">
+<li>
+<p>To verify changes, right-click the Tables node in the Database Explorer and
choose Refresh. The Refresh option updates the Database Explorer’s UI
component to the current status of the specified database. Note that the new
<code>Counselor</code> table node (<span class="image"><img
src="images/table-node.png" alt="table node"></span>) now displays under Tables
in the Database explorer. If you expand the table node you can see the columns
(fields) you created, starting with the [...]
+</li>
+</ol>
</div>
<div class="imageblock">
<div class="content">
@@ -337,7 +446,7 @@ To verify changes, right-click the Tables node in the
Database Explorer and choo
</div>
</div>
<div class="sect2">
-<h3 id="_using_the_create_table_dialog">Using the Create Table Dialog</h3>
+<h3 id="usingCreateTable">Using the Create Table Dialog</h3>
<div class="paragraph">
<p>In this exercise you will use the Create Table dialog box to create the
<code>Subject</code> table.</p>
</div>
@@ -353,13 +462,22 @@ To verify changes, right-click the Tables node in the
Database Explorer and choo
<p>Click Add Column.</p>
</li>
<li>
-<p>For the Name of the column, enter <code>id</code> . Choose
<code>SMALLINT</code> for data type from the Type drop-down list. Click OK.
-image::images/add-column-dialog.png[]</p>
+<p>For the Name of the column, enter <code>id</code> . Choose
<code>SMALLINT</code> for data type from the Type drop-down list. Click OK.</p>
+</li>
+</ol>
+</div>
+<div class="imageblock">
+<div class="content">
+<img src="images/add-column-dialog.png" alt="add column dialog">
+</div>
+</div>
+<div class="olist arabic">
+<ol class="arabic" start="5">
+<li>
+<p>Select the Primary Key check box in the Add Column dialog box. You are
specifying the primary key for your table. All tables found in relational
databases must contain a primary key. Note that when you select the Key check
box, the Index and Unique check boxes are also automatically selected and the
Null check box is deselected. This is because primary keys are used to identify
a unique row in the database, and by default form the table index. Because all
rows need to be identified, p [...]
</li>
<li>
-<p>Select the Primary Key check box in the Add Column dialog box. You are
specifying the primary key for your table. All tables found in relational
databases must contain a primary key. Note that when you select the Key check
box, the Index and Unique check boxes are also automatically selected and the
Null check box is deselected. This is because primary keys are used to identify
a unique row in the database, and by default form the table index. Because all
rows need to be identified, p [...]
-6.
-Repeat this procedure by adding the remaining columns, as shown in the
following table.</p>
+<p>Repeat this procedure by adding the remaining columns, as shown in the
following table.</p>
</li>
</ol>
</div>
@@ -417,13 +535,17 @@ Repeat this procedure by adding the remaining columns, as
shown in the following
<p>*Description: *description of the subject</p>
</li>
<li>
-<p>*Counselor ID: *counselor ID that corresponds to an ID from the Counselor
table
-image::images/create-table-subject.png[]</p>
+<p>*Counselor ID: *counselor ID that corresponds to an ID from the Counselor
table</p>
</li>
</ul>
</div>
+<div class="imageblock">
+<div class="content">
+<img src="images/create-table-subject.png" alt="create table subject">
+</div>
+</div>
<div class="paragraph">
-<p>Make sure that the fields in your Create Table dialog match those shown
above, then click OK. The IDE generates the <code>Subject</code> table in the
database, and you can see a new <code>Subject</code> table node
(image::images/table-node.png[]) immediately display under Tables in the
Database Explorer.</p>
+<p>Make sure that the fields in your Create Table dialog match those shown
above, then click OK. The IDE generates the <code>Subject</code> table in the
database, and you can see a new <code>Subject</code> table node (<span
class="image"><img src="images/table-node.png" alt="table node"></span>)
immediately display under Tables in the Database Explorer.</p>
</div>
</div>
</div>
@@ -446,16 +568,17 @@ image::images/create-table-subject.png[]</p>
</div>
<div class="listingblock">
<div class="content">
-<pre class="prettyprint highlight"><code class="language-java"
data-lang="java">INSERT INTO Counselor
+<pre class="prettyprint highlight"><code class="language-sql"
data-lang="sql">INSERT INTO Counselor
VALUES (1, 'Ricky', '"The Dragon"', 'Steamboat','334 612-5678',
'[email protected]', '1996-01-01')</code></pre>
</div>
</div>
<div class="olist arabic">
<ol class="arabic">
<li>
-<p>To execute the query, right-click within the SQL Editor and choose Run
Statement. In the Output window, you can see a message indicating that the
query was successfully executed.
-4.
-To verify that the new record has been added to the <code>Counselor</code>
table, in the Database Explorer, right-click the <code>Counselor</code> table
node and choose View Data. A new SQL Editor pane opens in the main window. When
you choose View Data, a query to select all the data from the table is
automatically generated in the upper region of the SQL Editor. The results of
the statement are displayed in a table view in the lower region. In this
example, the <code>Counselor</co [...]
+<p>To execute the query, right-click within the SQL Editor and choose Run
Statement. In the Output window, you can see a message indicating that the
query was successfully executed.</p>
+</li>
+<li>
+<p>To verify that the new record has been added to the <code>Counselor</code>
table, in the Database Explorer, right-click the <code>Counselor</code>
table node and choose View Data. A new SQL Editor pane opens in the main
window. When you choose View Data, a query to select all the data from the
table is automatically generated in the upper region of the SQL Editor. The
results of the statement are displayed in a table view in the lower region. In
this example, the <code>Counselor< [...]
</li>
</ol>
</div>
@@ -497,9 +620,10 @@ To verify that the new record has been added to the
<code>Counselor</code> tab
<div class="olist arabic">
<ol class="arabic">
<li>
-<p>Choose File > Open File from the IDE’s main menu. In the file
browser navigate to the location where you previously saved
<code>ifpwafcad.sql</code> and click Open. The script automatically opens in
the SQL Editor.
-2.
-Make sure your connection to <code>MyNewDatabase</code> is selected from the
Connection drop-down box in the toolbar at the top of the Editor.</p>
+<p>Choose File > Open File from the IDE’s main menu. In the file
browser navigate to the location where you previously saved
<code>ifpwafcad.sql</code> and click Open. The script automatically opens in
the SQL Editor.</p>
+</li>
+<li>
+<p>Make sure your connection to <code>MyNewDatabase</code> is selected from
the Connection drop-down box in the toolbar at the top of the Editor.</p>
</li>
</ol>
</div>
@@ -509,7 +633,7 @@ Make sure your connection to <code>MyNewDatabase</code>
is selected from the C
</div>
</div>
<div class="olist arabic">
-<ol class="arabic">
+<ol class="arabic" start="3">
<li>
<p>Click the Run SQL (image::images/run-sql-button.png[]) button in the SQL
Editor’s task bar. The script is executed against the selected database,
and any feedback is generated in the Output window.</p>
</li>
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists