Working with Results Grid


Result Grid has two modes: Results Display mode and Table Data Edit mode.

 

Results Display Mode

In Display query mode you can execute actions described below in a table. Generate SELECT/INSERT/DELETE/UPDATE for dates and string uses settings from Import / Export

Result Grid supports two additional modes. You can transpose them by selecting "Transpose" from the popup menu. Results also can be grouped by any number of columns. To accomplish it select "Group / Ungroup" from popup menu

 

Export to Excel

Select Export To->Excel menu item from Result Grid popup menu to copy data to Excel

To export data to specific Excel file you can define Excel export template in Export/Import options.

Excel export template should have form: File_Name,Range_Name (C:\Temp\Book1.xls,R_DATA).

 

Table Edit Mode

Table Data edit is entered when you select "Edit Table Data" from table popup menu in Object View. In this mode you can directly edit data in underlying table. When entering string values you do not need to enclose them in single quotes. To assign NULL value to a column leave content of cell empty. To enter empty string type two single quotes. Dates can be entered in any format which can be converted to date. If conversion to date fails nothing will be changed. Change in underlying table happens when you leave cell. At this point implicit COMMIT executed.

 

Grid popup menu actions

Results in New WindowDisplay current results in a new window
Generate
    SELECTGenerates select statements for current selection
    INSERTGenerates insert statement for current selection
    UPDATEGenerates UPDATE statement for current selection. If table has unique constraint then will use it, otherwise will use selected columns in update clause
    DELETEGenerates DELETE statement for current selection. If table has unique constraint then will use it, otherwise will use selected columns in delete clause
    WHERE IN ()Generates WHERE IN statement for current selection
    ORDER BY ()Generates ORDER BY statement for current selection
    GROUP BY ()Generates GROUP BY statement for current selection
    CREATE TABLE ()Generates CREATE TABLE statement based on current selection
Column FormatAllows to quickly change column display format
FilterAllows to quickly filter rows based on a value in current cell
Get Child / Parent RowsAllows to quickly retrieve Child / Parent rows rows based on a FOREIGN KEY constraint defined for selected rows
Find in ResultsFind in Results
CopyCopy selection to Clipboard. Data copied in two different formats
Copy Special
    Copy With Column Name(s)Includes column names
    Copy Column Name(s)Copy only column names to Clipboard
    Copy Column Name(s) and TypesCopy only column names and types
    Copy as TextCopy as aligned formatted text
    Copy as DelimitedCopy as CSV
    Copy as XMLCopy as XML
    Copy as HTMLCopy as HTML
    Copy Result QueryCopy result query
Export To
    ExcelExport selection to Excel
    Excel (smart)Export to Excel using options set in Export/Import
    Excel (as displayed)Export to Excel as text displayed in Result Grid
    File (csv, xml, html)Export to File. Type of export will depend on specified file extension. Defafult is CSV
    File (as inserts)Export to File as INSERT statements
    SQL LogSave selection to log file
Results
    New Result TabAdd new result tab if option Multiple Results Tabs enabled
    Close Result TabDelete current result tab
    In GridDisplay query results in Grid
    In TextDisplay query results in Text
TransposeSwitch column and rows
Freeze ColumnsFreeze columns to the left of current cell
Show Column TypesDisplay column type below header in Grid
Show Column TotalsShow totals for numeric columns

Notes

Generate feature by default copies generated statement to a current cursor position in Script Editor.

If you hold Ctrl key down when using generate then statement will be copied at the end of current script