A Quick Entrance Tour
This is what an Entrance window looks like when a table and a few other tabs are open:
In
this example, the explorer tree on the left side of the window contains
host nodes named "localhost" and "anonymous". There are also database,
table, file directory, and file nodes. You double click on a node
to open it, right-click or control-click on a node to bring up its
popup menu.
Expand
a host node, by clicking the triangle next to it, and you will
see MySQL databases. Expand a folder node and you will see files.
Host nodes have green icons when they are connected.
The
"current database" shown on the lower left, is the database that
Entrance will use for running queries. You can change it by
clicking on a database and clicking the connect tool, then
disconnecting any other connected databases.
A right-click or control-click on any node brings up its popup menu.
Open a SQL script and run it
Entrance
creates one folder node for saving SQL scripts, named "sql",
automatically when it is installed. You can attach more with File
| Add Folder... You can also drag and drop files to and to a
folder in the Entrance tree from your system's file explorer.
Expand the sql folder now, and double click on the script "createTenElements.sql" to open it.
Notice
that the exclamation point on the toolbar "Run" tool changed to green.
When the Run icon is green, you have a script ready to run.
Clicking the "Run" tool or use the File | Run menu
selection to run it.
Try running the script now. When you do, it will create a table named "TenElements" and then display data from it:
You
can jump back and forth between viewing the SQL script or viewing the
results it generates by clicking on the "SQL" and "Results" tabs at the
bottom of the window.
Open a table
Double click on the table "TenElements" to open it, and you will see the "Table View" of TenElements:
Both
the table and the SQL script are now open, and you can jump back and
forth between them by clicking the tabs labeled "createTenElements" or
"TenElements".
The Match Box
Next try entering "Hy" in the match box in the upper right corner of the Entrance window, and press "Enter" to see what happens:
The
match box works like "grep" for database tables. It filters rows
in the current table view to show only the rows matching a pattern, but
without changing the underlying table data. You can clear the
filter simply by deleting what is in the match box and pressing enter
again.
"Calculate statistics..." and other tools in the Tools menu also apply the match box filter (as of version 0.80.1).
Sort a table
There
is a quick way to sort a table: Right-click or control-click a
table column, then select one the sort selections from its popup:
Query a table
You
can quickly start writing a SQL query on a table by selecting some of
its columns and then "SQL to select these columns" from the column
popup. A cool feature: The resulting SQL query matches the
sort order of the table and uses filter criteria from the match box.
You can think of this as a running start for SQL script
development.
Saving queries
Navigate
back to the SQL tab for the new query you created, which will be named
"Untitled1", and then click the "Save" tool on the toolbar. Name
the new query something, and click OK.
Now look in the "sql" folder, and there is the query.
There are keyboard shortcuts for saving queries, and the File menu will show you what they are for your system.
Make a blank script
Use the "New" tool to start with a blank scripts. Each time you click New it will create a new blank script tab.
Closing scripts and tables
To
close scripts and tables use the Window | Close this tab menu
selection, which has a shortcut key. Check the menu to see what
the shortcut is on your system.
To continue learning about Entrance, read "Make a List" or "Give yourself a demo". If you are a SQL developer be sure to read "SQL and Charting" and "Make a Report".
Please
note: This web page and other Entrance documentation web pages
are copyrighted material and have not been released under the terms of
the GPL.
Copyright
(c) Tod Landis 2006,2007 All Rights Reserved
Modified: June 3, 2007
Java
and the Java Coffee Cup Logo are trademarks or registered trademarks of
Sun Microsystems, Inc. in the U.S. and other countries. Solaris
is a trademark of Sun Microsystems, Inc. MySQL is a registered
trademark of MySQL AB in the United States, the European Union and
other countries. Windows is a trademark of Microsoft Corporation.
Macintosh is a trademark of Apple Computer, Inc.