Query Layout

From PRAMS Plus Wiki
(Redirected from Query Overview)
Jump to navigation Jump to search

This page breaks down the layout of the Query main screen.


QueryX2

Main screen layout

Query Overview.png

When you first open QueryX2 you will see two panes.

The top pane will be where the query is written and the bottom pane is where the results will be displayed.

The top left of the window will show the database you are connected to.

This can be helpful because when launching query from another PRAMS program will automatically chose from the database selected.

Alternatively query will ask you what database to connect to when launched by itself. This will ask you for the server and database info along with loading in the DKF.

It's recommended to launch Query from Analyst under Tools.

Query Connection Manager.png

Menu Bar

On the top left of the window under the database connection info there will be the menu.

Selecting Query will bring up the following options:

New Query (Ctrl+N) Will open a new tab that can be worked in. To make a tab active select it. This will make the other queries grayed out showing they are not active.
Run Query (F5) This will run the active tab in query. Only an active query tab will run results.
Halt Running Query If the results are taking too long to appear you can select this option allowing modification to the query.

This generally happens when there are too many items being called on and not an efficient amount of memory to complete the task.

Save Query (Ctrl+S) This will save the active query. Note if any code is saved then it will overwrite past saves from loaded queries. If it is a new query it will ask what you want to Save as.
Save Query As... This will save the active query as a new query to load. Recommended if there is a modification to an existing query that you like but don't want to overwinter by saving.
Load Query This will open any saved queries and allow you to load then in to be ran. You can also delete any unnecessary queries that have accumulated.

To the right it will show when the query was last modified and you can choose to share the query with anyone on the same database connection as you.

Saved Queries.png

Save Query To File (Shift+Ctrl+S) This can be used to save the query to a file allowing it to be sent or loaded back in to Query.
Load Query From File (Shift+Ctrl+O) This can load the saved files from the last item on the list. Queries that have been loaded from file can be saved and stored in your queries.

Tools / View Selecting tools allows you to send the results to excel. There is also a button by run that allows you to do the same thing if view toolbar is checked.

Selecting View will bring up the following options to check-mark.

Tool Bar This will show the toolbar at the top right of the window Run, Excel, and Print.
Database Structure This will open up on the left side of the window the Database Structure that is all of PRAMS table to call on.

The DS can be hidden as a tab, pinned to be open always, or popped out to be separate from the query window.

Query History This will open up all the past queries that have been ran. This can be helpful if a query was ran and not saved so you can recover it.

Page Actions

Clicking and holding on a pane by the tab or top of it and then dragging it will open up a placement action allowing you to store a pane at any section of the program.

Below you can see when query history is drug out it can be placed on any of the directions and then when its let go it will snap to the location.

Query Pop out action.png