Welcome to Data Compare for SQL Server

dbforge-data-compare-header

Thank you for choosing dbForge Data Compare for SQL Server!

ExpandedToggleIcon(9x12) dbForge Data Compare for SQL Server Overview

dbForge Data Compare for SQL Server is a powerful, fast and easy to use SQL comparison tool, capable of using native SQL Server backups as metadata source. With dbForge Data Compare you can:

· Tune your SQL database comparison
· Quickly analyze differences in a well-designed user interface
· Effortlessly synchronize data via a convenient wizard with additional options

ExpandedToggleIcon(9x12) Key Features

ExpandedToggleIcon(9x12) Where to start

To start using dbForge Data Compare for SQL Server, see Getting Started section. The guide helps you get started quickly by describing how to set up a new database connection, and provides an explanation of the key steps for basic database operations.

ExpandedToggleIcon(9x12) See Also

Copyright Information

© 2004-2017 Devart


What's New in Data Compare for SQL Server v4.3

SQL Server Support

· SQL Server 2016 Service Pack 1 (SP1) new syntax support
· SQL Server 2017 CTP2 new syntax support
· Azure SQL Data Warehouse connectivity support

Integration

dbForge Data Compare can be integrated into the latest SQL Server Management Studio v17.2

Data Comparison

· Static Data comparison in Script Folder
· Support for the MASKED columns
· Option to automatically select a key for comparing objects without a suitable unique key
· Added option to turn ON\OFF Generation of IF NOT EXISTS on inserting
· Possibility to open the comparison wizard instead of the comparison autorun when opening the .dcomp files

Creation of the Command Line Execution File

With the Command Line Execution File Settings dialog box, you can setup and create a command line execution file (.bat file), and use it for routine data comparison and synchronization tasks.


Editions

dbForge Data Compare for SQL Server comes in two editions: Standard, and Professional.

Standard edition includes essential tools for data comparison and synchronization.

Professional edition is a fully-featured software able to complete any data comparison and synchronization tasks and provide the best professional tricks to simplify your database management.

The table below represents comparative data of available editions of dbForge Data Compare for SQL Server.

Features | Standard | Professional
Support for SQL Server 2017 CTP2 | yes | yes
Support for SQL Server 2016 SP1 | yes | yes
Support for SQL Server 2016, 2014, 2012, 2008R2, 2008, 2005 (including Express editions), 2000 (including MSDE edition), and Microsoft SQL Azure | yes | yes
Support for SSMS 2016, 2014, 2012, 2008R2, 2008 | yes | yes
Comparison of tables and views | yes | yes
Rich options to customize data comparison and synchronization | yes | yes
Custom mapping of tables, columns, views, and schemas | yes | yes
Execution of SQL files and scripts | yes | yes
Comparison of native SQL Server backups | none | yes
Generating comparison and synchronization reports | yes | yes
Command line interface | none | yes

ExpandedToggleIcon(9x12) See Also:

Welcome to Data Compare for SQL Server

Requirements


Requirements

dbForge Data Compare for SQL Server requires the following:

Microsoft SQL Server compatibility

· SQL Server 2017 CTP2.0, 2016 SP1, 2016, 2014, 2012, LocalDB
· SQL Server 2008, 2008R2 (including Express edition)
· SQL Server 2005 (including Express edition)
· SQL Server 2000
· SQL Azure

Microsoft SQL Server Management Studio compatibility

· 2016, 2014, 2012, 2008R2, 2008

System Requirements

· .NET Framework 4.5.2 or higher installed. You can download .NET Framework here.

note Note

.NET Framework is pre-installed in Microsoft Windows Vista and Windows 7/8/8.1/10.

· Microsoft Windows 7/8/8.1/10
· Windows Server 2008/2012

ExpandedToggleIcon(9x12) See Also

Welcome to Data Compare for SQL Server

Copyright Information


Copyright Information

Information in this document, including URL and other Internet Web site references, is subject to change without notice. Unless otherwise noted, the example companies, organizations, products, domain names, e-mail addresses, logos, people, places and events depicted herein are fictitious, and no association with any real company, organization, product, domain name, e-mail address, logo, person, place or event is intended or should be inferred. Complying with all applicable copyright laws is the responsibility of the user.

Devart may have patents, patent applications, trademarks, copyrights, or other intellectual property rights covering subject matter in this document. Except as expressly provided in any written license agreement from Devart, the furnishing of this document does not give you any license to these patents, trademarks, copyrights, or other intellectual property.

Copyright 2008-2017 Devart. All rights reserved.

Microsoft and Windows are either registered trademarks or trademarks of Microsoft Corporation in the United States and/or other countries.

The names of actual companies and products mentioned herein may be the trademarks of their respective owners.

ExpandedToggleIcon(9x12) See Also

Welcome to Data Compare for SQL Server

Previous Releases


Previous Releases

ExpandedToggleIcon(9x12) In This Section

What's New in Data Compare for SQL Server, v4.2

What's New in Data Compare for SQL Server, v4.1

What's New in Data Compare for SQL Server, v4.0

What's New in Data Compare for SQL Server, v3.9

What's New in Data Compare for SQL Server, v.3.8

What's New in Data Compare for SQL Server, v.3.0

What's New in Data Compare for SQL Server, v.2.0

What's New in Data Compare for SQL Server, v.1.1

ExpandedToggleIcon(9x12) See Also

Welcome to Data Compare for SQL Server

Getting Started


What's New in Data Compare for SQL Server, v4.2

Comparison and synchronization of data in system-versioned tables

dbForge Data Compare for SQL Server now supports system-versioned temporal tables - a new type of user tables in SQL Server 2016 that provide a complete information on data changes at any point in time.

New comparison and synchronization options

A bunch of new options was added to make the comparison and synchronization process even more customizable.

Comparison and synchronization of memory-optimized table types

Memory-optimized table variables have a number of advantages over traditional table variables. The option of comparing and synchronizing data in memory-optimized tables has been implemented in dbForge Data Compare for SQL Server.

Comparison reports extended functionality

You can generate reports in a collection of comma-separated value (CSV) files.

PowerShell Supported

Automate data comparison and synchronization using a rich PowerShell environment and the Data Compare command lines.

Specific exit codes are added

Specific exit codes will indicate an error when a task you're running in the command line interface fails and will make troubleshooting more straightforward.

Other improvements

· Trial Product Activation implemented
· Application visual style greatly improved
· FIPS compliance
· Azure Active Directory authentication


What's New in Data Compare for SQL Server, v4.1

Support for SQL Server 2016 and its backup

You can now quickly compare data in SQL Server 2016 databases and backups, as well as effortlessly synchronize the data in a well-designed user interface of dbForge Data Compare for SQL Server.

New synchronization options

In Data Synchronization Wizard, you can see new sync options for:

· determining backup type
· specifying backup file extension
· specifying backup file compression
· determining Transaction Isolation Level during synchronization
· processing synchronization errors

Integration into Microsoft SQL Server Management Studio 2016

dbForge Data Compare for SQL Server seamlessly integrates into SQL Server Management Studio 2016, so you can compare SQL database data directly from the most recent SSMS version available.


What's New in Data Compare for SQL Server, v4.0

SSMS Integration Support

· SQL Server Management Studio integration enables starting the data comparison directly from SSMS

User Interface

· Redesigned Comparison Document UI

ExpandedToggleIcon(9x12) See Also

Welcome to Data Compare for SQL Server

Editions


What's New in Data Compare for SQL Server, v3.9

Compatibility

· Windows 10 support

Data Comparison

· Show white spaces option
· Ignore computed columns option
· Zooming font size in Data Viewer
· Ignore difference in end of string option

SQL Editing and Execution

· Query execution pane
· Easy way to hide data results
· Command-line interface for SQL formatting
· Encoding switch in the /execute command-line operation
· Updated Find&Replace feature for documents and files

Data Editor

· Data Viewer, LOB Editor, and Redirect Data to Output are combined in a single control
· Zooming font size in Data Viewer and Editor window

Other Features and Improvements

· New skins
· Support of multiple monitors

ExpandedToggleIcon(9x12) See Also

Previous Releases

What's New in Data Compare for SQL Server, v3.8


What's New in Data Compare for SQL Server, v3.8

SQL Server 2014 is supported

Code Completion

Data Comparison and Synchronization

· Columnstore index is supported
· Check for object existence option is added to the synchronization wizard
· Ignore column order in indexes option is added
· ALTER SCHEMA feature for objects transferring between schemas is supported
· Include print comments option is added
· Exclude comments option is added

User Interface

· SET connection options in query execution are added
· Switching tabs by the CTRL+ALT+PAGE UP and CTRL+ALT+PAGE DOWN keys combination
· SSMS shortcut schema availability
· Possibility to switch from the wizard page to the main application window
· SQL document zooming by holding the CTRL key and rotating the mouse wheel
· Coloring a database connection according to the document category
· Restore Session

ExpandedToggleIcon(9x12) See Also

Previous Releases

What's New in Data Compare for SQL Server, v3.0


What's New in Data Compare for SQL Server, v3.0

New extended data comparison reports

· Offline analyzing of comparison results can be done by exporting real data into the report
· New Comparison Report wizard
· Comparison report can include only columns containing differences for the rows that contain differences
· The number of changes for each column can be included into the comparison report

Custom query result comparison

The custom query result comparison feature can be used to compare results of specific queries. This proves exceptionally useful in case you need a customized comparison instead of comparing all data in your database.

SQL Azure Support

Comparing data and synchronizing SQL Azure databases has just become as easy as processing common ones. dbForge Data Compare fully supports SQL Azure database connection and processing.

More flexible comparison settings

· Possibility to use "One-to-many" objects mapping when some columns in the target database were separated as a table is added
· Possibility to include objects into comparison by mask is added. It is useful when you need to compare groups of tables
· Possibility to choose a random index as a comparison key is added
· Options for ignoring difference in time for DATETIME fields are added

Improved analysis of comparison results

· Possibility of quick navigation through data differences is added
· Full-text data search is available
· Possibility to hide unchanged columns in the result data grid is added
· The number of differences per column is now displayed on the status bar
· Possibility to view a random set of columns in data grid is added

Other improvements

· Extended examples on command line usage are added
· Additional user interface skins support is added
· Redesigned start page

ExpandedToggleIcon(9x12) See Also

Previous Releases

Getting Started


What's New in Data Compare for SQL Server, v2.0

Higher performance in practice

Having passed multiple performance tests on large databases including billions of records and BLOB data types of several gigabyte size, dbForge Data Compare for SQL Server, v2.0 proved marked performance improvement as compared with the previous version and beneficial leading among competitive programs.

Fast Comparison and Synchronization

You can benefit from 3 times faster comparison and synchronization comparing to dbForge Data Compare for SQL Server, v1.1.

Support of native SQL Server backups

This will allow you to use native SQL Server backups as a metadata source.

Data comparison and synchronization via command line

This will allow you to synchronize data in the automatic mode via command line.

Extended data comparison and synchronization options

You can better tune your comparison and synchronization as dbForge Data Compare offers a wider choice of options. Now auto mapping, comparison, and display options are at your disposal.

Generating comparison and synchronization reports

This will allow you to and publish differences between databases to produce reports.

Standard and Professional product editions available

You can select only required tools and save your money.

ExpandedToggleIcon(9x12) See Also

Previous Releases

What's New in Data Compare for SQL Server, v.1.1


What's New in Data Compare for SQL Server, v1.1

New Features and Improvements

· New data synchronization options were added to allow disabling triggers, dropping or recreating keys and indexes during data synchronization
· New data comparison option was added to allow ignoring TIMESTAMP columns during comparison
· The ability to copy the action plan and list of warnings in synchronization wizard was added
· Faster comparison of tables
· InvalidOperationException when showing data comparison results was fixed
· Bug with table columns describe was fixed
· Bug with foreign key describing was fixed

ExpandedToggleIcon(9x12) See Also

Previous Releases

Welcome to Data Compare for SQL Server


Getting Started

ExpandedToggleIcon(9x12) In This Section

dbForge Data Compare for SQL Server Start Page
This section describes the basic functionality provided by dbForge Data Compare for SQL Server.

Installation Guide
This section describes gives overview of the install/uninstall processes.

Activating dbForge Data Compare for SQL Server
This topic describes the activation procedure.

How To: Connect to a Database
This topic explains how to create a new server connection.

How To: Manage Database Connections
Learn how to manage the database connections.

Comparing Databases in MS SSMS
This topic explains how to start comparing databases in MS SSMS.

How To: Quickly Synchronize Two Databases
dbForge Data Compare for SQL Server allows you to compare data of databases and synchronize it.

How To: Save and Load Data Comparison
Learn how to save the compared data.


dbForge Data Compare for SQL Server Start Page

The goal of the start page is to provide a location, available when the product first started, for the user to find out about dbForge Data Compare for SQL Server functionality. We also added some other features to this start page such as the ability to navigate to the product support page, blog, feedback page, etc. The Start page uses a multi-tab model that provides the relevant features and tools in a specific tab.

To access the Start page, in the View menu click Other Windows, and then click Start Page.

Section | Tool | Description
Quick Links | Help | Opens the built-in help file where you will find how to perform basic and advanced tasks in dbForge Data Compare for SQL Server. It gives you necessary information to get started with the application and broaden your database administration skills when you are familiar with simple tasks.
 | Product Support Page | On the support page you can find answers to any questions you may have about using dbForge Data Compare for SQL Server and provide comments and suggestions about the product.
 | Blog | Opens the Devart blog which contains a variety of technical articles on every product and theme.
 | Forum | Participate in the discussion forum of dbForge for SQL Server product line. Get answers to your technical questions and find more valuable information about dbForge Data Compare for SQL Server and other products' advantages.
 | Devart website | Opens the Devart company website.
 | Product Feedback Page | We are striving to build a set of tools that simplify SQL interaction and enhance opportunities for developers, DBAs, and other people dealing with databases. We are interested in how well dbForge Data Compare for SQL Server works for you and what features you want to see added.
 | Recent Projects | The section displays recently opened projects. Click a required project name link to open it.
NewDataComparisonIcon | New Data Comparison | Click the icon to open the Data Comparison Wizard and start comparing the data immediately.
open-data-comparison | Open Data Comparison | Click the icon to choose a file path to an already existing comparison document and open it.

ExpandedToggleIcon(9x12) See Also

Getting Started

Installation Guide


Installation Guide

This section describes how to install and uninstall Data Compare for SQL Server.

ExpandedToggleIcon(9x12) In This Section

How To: Install dbForge Data Compare for SQL Server
Describes how to install the application.

How To: Uninstall dbForge Data Compare for SQL Server
Describes how to uninstall the application.


How To: Install dbForge Data Compare for SQL Server

This topic describes how to install Data Compare for SQL Server on Windows OS with the help of Devart dbForge Data Compare for SQL Server Setup Wizard.

To Install Data Compare for SQL Server

1. Run datacomparesql.exe to begin installation.
2. On the Welcome to dbForge Data Compare for SQL Server page, click Install.
3. On the Select Destination page, select the directory where dbForge Data Compare for SQL Server will be installed. To change the default directory, click Browse. To restore the default directory, click Restore default location. Optionally, click the License Terms link to learn End-User Agreement for dbForge Data Compare for SQL Server. If you agree to the Devart dbForge Data Compare for SQL Server License Terms, click Next.
4. Optionally, on the Shortcuts page, select the additional shortcuts you would like the Setup Wizard to create while installing. There are two options available: Create a desktop icon and Add a shortcut to the start menu. Click Next.
5. On the Add-In page, select product or products which dbForge Data Compare for SQL Server should be installed for as an add-in. Click Next.
6. On the File Associations page, select the document types and file extensions that will be associated with this application when it is installed on your computer. Click Next.
7. On the Startup Optimization page, select the option that fits your needs best. Click Next.
8. Optionally, on the Installing page, you can interrupt the installation by clicking the Cancel button.
9. On the final page, click Finish to exit Setup wizard. Optionally, you can select the Launch "dbForge Data Compare for SQL Server" option to start the application immediately after installation.

ExpandedToggleIcon(9x12) See Also

Installation Guide

How To: Uninstall dbForge Data Compare for SQL Server


How To: Uninstall dbForge Data Compare for SQL Server

This topic describes how to uninstall dbForge Data Compare for SQL Server from Windows OS.

To uninstall dbForge Data Compare for SQL Server

1. To begin the uninstall, go to Control Panel and then Programs and Features.
2. Right click Devart dbForge Data Compare for SQL Server and select Uninstall.
3. The Uninstall dialog box appears. Click Yes, if you are sure you want to uninstall the application. This starts the Devart dbForge Data Compare for SQL Server Uninstaller.
4. Optionally, on the Uninstall options page, you can specify the following additional options and then click Uninstall.
· Registry options
· Connection list
· Configuration files
· Format profiles
· Scripts
5. Optionally, select Go to the product feedback page after uninstall to leave a feedback about the application.
6. Click Uninstall to proceed with the uninstall.
7. If the uninstall is successful, the dialog box confirming that the application was successfully removed appears. Click OK to exit the uninstaller.

ExpandedToggleIcon(9x12) See Also

Installation Guide

How To: Connect to a Database


Activating dbForge Data Comapre for SQL Server

Unless activated, dbForge Data Compare for SQL Server works on the trial basis for 30 days. When this time period expires, dbForge Data Compare for SQL Server must be activated with the purchased activation key.

dbForge Data Compare for SQL Server can be activated either online, or offline.

Online activation

This activation method requires an active Internet connection.

To activate dbForge Data Compare for SQL Server online:

1. If you have not purchased dbForge Data Compare for SQL Server, click Buy Now... on the pop-up window that appears at the start of dbForge Data Compare for SQL Server. If you already have your activation key, click Activate...
Alternatively, click Activate Product on the Help menu.

2. The Activation window opens. Copy your activation key from the e-mail that was sent to you after your purchase, and paste it into the edit box.
The activation key looks like a long sequence of letters and digits.

note Note

If you do not see the e-mail with the activation key, be advised to check your Junk/ Spam/Bulk folders.

You can always retrieve your activation key at your Customer Portal page.

3. Click Activate.

Offline activation

Offline activation allows activating dbForge Data Compare for SQL Server right at the Devart web site. This activation method helps activating the product when the online activation fails.

To activate dbForge Data Compare for SQL Server offline:

1. Click the Manual Activation button on the Activation window. It opens when online activation fails.

2. Copy the activation request text with the Copy to Clipboard button, or save it to a text file with the Save to File... button.

3. Open the Manual Product Activation page of the Devart web site, and paste the copied text in the text box. Click Download license. The license file with the .lic extension is downloaded to your computer.

4. Return back to the Activation window of dbForge Data Compare for SQL Server and click the Load license... button. Specify the location of the downloaded .lic file and click Open.

ExpandedToggleIcon(9x12) See Also

Getting Started

How To: Connect to a Database


How To: Connect to a Database

Before you can connect to a database, you must create a server connection.

To create a connection:

1. On the Database menu, click New Connection. The Database Connection Properties dialog box opens.
2. In the Server combo box, click <Browse...>. The Browse for Servers window opens.
3. On the Local Servers tab, select an SQL Server instance (if any). Otherwise, click the Network Servers tab to select an SQL Server instance in the network.
4. Select the Authentication type, either SQL Server authentication or Windows authentication.
5. Enter the login credentials in the User and Password fields.
6. In Database, type or click the name of the database which you want to connect to.
7. In the Connection Name text box, the connection name should be generated automatically from the host name. You can create a distinctive name for your new connection.
8. (optional) You can assign a document category to the new connection.
9. (optional) You can click Advanced to configure advanced connection properties.
10. (optional) Click the Test Connection button to verify the connection.
11. Click OK to create the connection.

ExpandedToggleIcon(9x12) See Also

Getting Started

How To: Manage Database Connections


How To: Manage Database Connections

dbForge Data Compare for SQL Server offers you visual, quick, and simple way to manage database connections through the Connection Manager window.

Create a database connection

1. Open the Database Connection Properties dialog box by one of the following ways:
· Click [image] New Connection on the Database menu

-or-

· Click Connection Manager on the Database menu, and then click the New button in the Connection Manager dialog box

2. Database Connection Properties dialog box opens. Set up connection parameters here.

3. Click OK to finish creating the connection, or click Test Connection to find out whether the connection with such parameters exists.

Windows connection coloring

Window connection coloring allows you immediately to know to which server you're connected to. You can add coloring for each server connection in the Document Category field of the Database Connection Properties dialog box when setting the database connection properties.

Edit a database connection

To edit an already existing database connection, on the Database menu, click Connection Manager. The Connection Manager dialog box opens. Select a required connection, and then click the Edit button. The Database Connection Properties dialog box opens where you can make changes on database connection parameters.

Delete a database connection

To delete a database connection, open the Connection Manager on the Database menu. Choose a connection you want to delete, and then click the Delete button.

expandedtoggleicon(9x12) See Also

Getting Started

Comparing Databases in MS SSMS


Comparing Databases in MS SSMS

This topic explains how to start comparing databases in MS SSMS.

ExpandedToggleIcon(9x12) Comparing Schemas

1. In Object Explorer, right-click a database, point to Data Compare, and then click Set as Source or Set as Target.
2. Depending on your choice in previous step, drag source or target database from Object Explorer to the dbForge Data Compare for SQL Server window.
3. Click the green arrow button to open the dbForge Data Compare for SQL Server desktop application to proceed with schema comparison and synchronization.

expandedtoggleicon(9x12) See Also

Getting Started

How To: Quickly Synchronize Two Databases


How To: Quickly Synchronize Two Databases

dbForge Data Compare for SQL Server allows you to compare data of databases and synchronize it.

ExpandedToggleIcon(9x12) Database Connection Setup

1. Click New Data Comparison on the Start Page. The New Data Comparison wizard opens.
2. Select the Source and Target connections. You can edit a selected connection or create a new one. To do this, just click the Edit button, or the New button correspondingly. To quickly compare data, you can click the Compare button immediately after setting databases and skip the optional steps.
3. If you want to change default comparison settings, go to the Options and Mapping tabs of the New Data Comparison wizard.

ExpandedToggleIcon(9x12) Synchronization Script Generation

1. Select the data to synchronize in the grid with comparison results. (To do this, select the check boxes next to tables (or views) in the top grid. You may also select the check boxes next to individual records on the Only in Source, Only in Target, and Different Records tabs of the bottom grid).
2. Click the [image] Synchronize button on the Comparison toolbar to open the Data Synchronization wizard.
3. Select where to output the synchronization script in the wizard and then click the Synchronize button.

For more information about synchronization, refer to the Synchronizing Data section.

ExpandedToggleIcon(9x12) See Also

Getting Started

How To: Save and Load Data Comparison


How To: Save and Load Data Comparison

You can save the Data Comparison document (the one that opens after comparison to show comparison results) for the future usage. The saved file has the '*.dcomp' extension and contains data comparison information, including:

· Source and target settings
· Selected values for comparison options
· Selected values for synchronization options
· Schema mapping settings

It does not contain data comparison results or object DDL. When the file is opened, data are recompared. If target or source can not be found, the New Data Comparison dialog appears, where you should set source or target options.

ExpandedToggleIcon(9x12) Saving Data Comparison Document

To save:

· In the File menu, click Save (or Save As).
· Right-click the title of the document and select Save from the menu.
· Click the Save Save button on the toolbar.

ExpandedToggleIcon(9x12) Opening Data Comparison Document

· Drag it to the dbForge Data Compare for SQL Server UI.
· Use the Open File button on the Standard toolbar.

ExpandedToggleIcon(9x12) See Also

Getting Started


Comparing Data

This section describes how to setup the data comparison process, how to compare data, and analyze comparison results.

ExpandedToggleIcon(9x12) In This Section

How To: Set up Data Comparison
The topic describes all steps that can be taken during data comparison process and alternative ways for accomplishing routine comparison tasks.

Mapping
This section describes automatic and manual object mapping.

Data Comparison Options
The topic describes options of comparison process.

ExpandedToggleIcon(9x12) See Also

Analyzing Comparison Results


How To: Set Up Data Comparison

From this topic you will learn all steps that can be taken during data comparison process and alternative ways for accomplishing routine comparison tasks.

1. To open the Data Comparison Wizard and start comparing data, on the Comparison menu, select new-data-comparison-icon New Data Comparison.
2. In the Data Comparison Wizard window, select source and target connection from the drop-down list. Also you can create a new connection by clicking New or modify existing ones by clicking Edit.
3. Select the source and target database. You can easily swap source and target databases by clicking the Swap Swap button. (To immediately compare the data, click the Compare button. To tune the comparison, click the Next button to move to other wizard pages.

4. Click Next.
5. On the Options page, you can customize your comparison by checking the required options. Here you can generate a file with command line arguments. Click Next.

data-comparison-options-sqlserver
6. On the Mapping page, you can customize mapping. Use this page if you want to change the default mapping or map tables with different names or columns with different names and structure. Click Compare.

data-comparison-mapping-sqlserver
7. After comparison process is completed, you can view results in the Data Comparison document.

ExpandedToggleIcon(9x12) See Also

Comparing Data

Mapping


Mapping

This section describes Data Compare for SQL Server automatic and manual object mapping.

By default Data Compare for SQL Server maps tables that have the same name and owner and columns with the same names for comparison. Column order may be different. Unique or primary constrains with the same set of columns can be used as comparison keys.

You can change the default behavior to ignore differences in case, spaces, and underscores in object names by setting the corresponding options on the Options of the Data Comparison wizard. These settings apply to the names of tables, views, and columns. You can also map schemas, tables and columns manually. For more information visit other topics of this section.

ExpandedToggleIcon(9x12) In This Section

How To: Map Tables and Views
Describes how to map tables and views manually.

How To: Map Columns
Describes how to map columns manually.

How To: Set Comparison Key
Describes how to select constraints for the comparison key or create custom comparison key.

How to: Map Schemas
Describes how to map schemas manually.

How To: Filter Rows Included into Comparison
Describes how to filter rows to compare specific ranges.

Mapping Warnings
Describes warnings you may encounter when mapping database objects.

ExpandedToggleIcon(9x12) See Also

Comparing Data

Data Comparison Options


How To: Map Tables and Views

By default, when you move to the Mapping tab of the Data Comparison wizard, Data Compare for SQL Server automatically maps all available objects of the selected databases.

note Note

To remap already mapped objects, unmap them first. See the "How to unmap an object" section below.

note Note

After objects are mapped for comparison and synchronization, you may encounter mapping warnings, displayed as Caution icons. For more information about mapping warnings see the Mapping Warnings topic.

ExpandedToggleIcon(9x12) How to unmap an object:

1. Switch to the Mapping page of the Data Comparison wizard.

2. In the grid, select database objects to unmap. (To find a mapped database object quickly, use the Filter box. Type the string in this box to view only the objects, containing this string in their names. Click the arrow button to select a recent search. To clear the Filter box, click the x button.)
3. Click the unmap Unmap button on the toolbar. The unmapped objects disappear from the grid, but will be listed in the Object Mapping dialog.

ExpandedToggleIcon(9x12) How to map an object:

1. Switch to the Mapping page of the Data Comparison wizard.
2. Click the change-mapping Map Objects button on the toolbar. The Objects Mapping dialog will appear.

ObjectMappingSQL

note Note

Actual document look may slightly vary from the above image depending on the product you use.
3. Select source and target objects in the corresponding boxes.
4. Click the Map button and the mapped objects disappear from the Objects Mapping dialog and will be shown in the Mapping tab's grid.
5. Repeat steps 3-4 until you map all the objects you need. Click OK to close the dialog.

CollapsedToggleIcon(9x12) How to map an object using custom queries

You can use this option to compare custom results received after query execution instead of comparing whole tables or views. For this, you should:

1. Click the custom-query-mapping Custom Query button on the Mapping page of the wizard. The Custom Queries Mapping dialog box will open.

custom-query-sqlserver

note Note

Actual document look may slightly vary from the above image depending on the product you use.
2. Select Query or Table radiobuttons for Source and Target.
3. If you selected Table for both, refer to the How to map an object section of this topic. If you selected Query for Source, Target or both, write query name in the field (if the name assigned by default is not appropriate).
4. Type the needed query in the SQL field.
5. Click Validate to validate your queries, if necessary.
6. Click Map.
7. Click OK to close the dialog box.

Tips:

Click the Cancel button to close the dialog and discard mapping.

Click the Reset Reset button to restore the automatic mapping of objects.

ExpandedToggleIcon(9x12) See Also

Mapping

How To: Map Columns


How To: Map Columns

Data Compare for SQL Server allows you to map columns with non-equal names. You may map columns with different types, however this may result in data truncation, rounding, and errors during synchronization for certain types. If such a situation is possible, a warning icon Caution appears in the Target Column column of the Select columns for comparison grid. If the columns are not compatible and cannot be compared, the ErrorIcon icon appears near this column. For more information about types compatibility and mapping warnings, see the Mapping Warnings and Types Compatibility topics.

For customizing column mapping the Column Mapping dialog box is used. To open it, click the [image] button in the Columns in Comparison column on the Mapping page of the Data Comparison wizard.

note Note

Actual document look may slightly vary from the above image depending on the product you use.

note Note

If you want to remap already mapped columns, you should unmap them first.

How to unmap columns

Click the corresponding cell in the Target Column column and choose <None>.

How to map columns

Click the corresponding cell in the Target Column column and choose the column you need.

ExpandedToggleIcon(9x12) See Also

Mapping

How To: Set Comparison Key


How To: Set Comparison Key

Comparison key is used to determine which rows correspond to each other. You can choose suitable constraints for comparison or specify custom comparison keys. Data Compare for SQL Server can select comparison key automatically if tables have matching primary key or unique constraint.

To choose a constraint pair, click the CBDropDownArrow button in the Comparison Key column on the Mapping page of the Data Comparison wizard and select the constraint pair you need.

To set a custom comparison key, click the CBDropDownArrow button in the Comparison Key column on the Mapping page of the Data Comparison wizard and select <Custom>. Then in the appeared Column Mapping dialog box select check boxes in the Key column to add columns to the comparison key.

Note that you can set custom comparison key or choose the needed constraint pair directly in the Comparison Key drop-down list of the Column Mapping dialog box.

ColumnMapping

note Note

Actual document look may slightly vary from the above image depending on the product you use.

ExpandedToggleIcon(9x12) See Also

Mapping

How To: Map Schemas


How To: Map Schemas

Data Compare for SQL Server allows you to map tables or views with non-equal owners. It can be useful if schemas were renamed and you want to synchronize data between a database with new schema names and database with old schema names. Only one-to-one schema mapping is supported. If you need to synchronize data between one source schema and several target schemas or vice versa, you need to perform several comparison and synchronization operations.

note Note

Actual document look may slightly vary from the above image depending on the product you use.

To map schemas, do the following:

1. Switch to the Mapping Page of the New Data Comparison Wizard.
2. Click the map-schemas Map Schemas button on the toolbar. The Map Schemas dialog box will appear.
3. The Map Schemas dialog displays all source schemas in the first column. To map source schema with unmapped target schema, click the CBDropDownArrow button in the corresponding Target column cell and select the required schema from the drop-down list. If the target schema is already mapped, it is absent in the list. You should unmap it before mapping with another source schema. To unmap the schema pair, click the CBDropDownArrow button in the corresponding Target column cell and select <None> from the drop-down list.
4. After you mapped all schemas you need, click OK. If you want to restore original mapping, click the Reset Reset button.

ExpandedToggleIcon(9x12) See Also

Mapping

How To: Filter Rows Included into Comparison


How To: Filter Rows Included into Comparison

By default, Data Compare for SQL Server compares all the rows in the selected tables or views. If they contain a large amount of data, the comparison can take a lot of time and even result in running out of disk space. You can simply avoid such things by filtering the rows to compare specific ranges.

1. Open the Data Comparison wizard and specify Source and Target. Click Next.
2. On the Mapping wizard page, select a required object in the grid and click the Filter button. The WHERE Filter dialog opens. It is divided into Source section (on the left) and Target one (on the right). If you want to filter Source rows, use the left section. To filter Target rows, use the right section.
3. Right-click either Source or Target section and select Insert Column and a required column from the right-click menu. Type a filter expression.

4. If you want to apply the expression to both Source and Target rows, type the expression and select Use the same expression for source and target.
5. To apply the filtering expression, click OK. The filtered object will be marked with the ? icon in the Mapping wizard page grid.

ExpandedToggleIcon(9x12) See Also

Mapping

Mapping Warnings


Mapping Warnings

After objects are mapped for comparison and synchronization, you may encounter warnings on the Mapping page of the Data Comparison wizard. The warnings may be divided into two groups. They are table-level warnings and column level warnings.

Table-level warnings are displayed as Caution icon in the column with check boxes on the Mapping page of the Data Comparison wizard. Object pairs with table-level warnings are not compared. They are displayed with Caution icon instead of check box in the Data Comparison Document.

note Note

Actual document look may slightly vary from the above image depending on the product you use.

Column-level warnings are displayed as Caution icon in the Columns in Comparison column on the Mapping page of the Data Comparison wizard. They also appear in the Target column in the Column Mapping dialog box. Such warnings mean that some columns of a compared object pair cannot be compared because of type incompatibility or that you may encounter data loss when synchronizing data.

To read the warning messages, point to the warning icon. All warnings for this object will appear in the hint.

The following table contains information about table-level warnings and ways to remove them.

Warning | Description
No columns to compare. | It means, there are no columns with the same name in this pair of tables (views). To compare them you should map the columns manually. For more information about the column mapping, see How to: Map Columns.
Objects to compare have no key column. | It means that custom comparison key is used but is not set. You should mark at least one column pair as comparison key. For more information visit How to: Set Comparison Key.

The following table contains information about column-level warnings.

Warning | Description
Conversion is possible, but may fail in case of incompatible data. | This warning appears when source column may contain data, that are impossible to convert to target column data type. Such data cannot be synchronized. For example if the source character column is mapped to the numeric target column, character column may contain convertable data (e.g. '123') and inconvertible data like 'abc'.
Numeric columns have different precisions, migrating the data may cause overflows. | This warning appears when source numeric columns have larger precision than target column. In this case source may contain larger values than the target column can contain. Records containing such values cannot be synchronized.
Decimal columns have different precisions or scales, migrating the data may cause rounding or overflows. | This warning appears when comparing Decimal source column with Decimal target column and source column has larger precision and/or scale. If the source column contains larger values than the target column can contain, such records cannot be synchronized because of overflow. If the source column contains numbers with fractional part, such numbers will be rounded during synchronization.
Decimal and Integer columns have different precisions and scales, migrating the data may cause rounding or overflows. | This warning appears when comparing Decimal source column with Integer target column and source column has larger precision and/or scale. If the source column contains larger values than the target column can contain, such records cannot be synchronized because of overflow. If the source column contains numbers with fractional part, such numbers will be rounded during synchronization.
Date or time columns have different data format, migrating the data may cause truncation. | This warning appears when comparing Date or Time columns and source column has differed data format than target column. If source contains records with longer data than target can contain, the data will be truncated in the target when synchronizing.
Float and Integer columns have different precisions and scales. | This warning appears when comparing Float source column with Integer target column and source column has larger precision and/or scale. If the source column contains larger values than the target column can contain, such records cannot be synchronized because of overflow. If the source column contains numbers with fractional part, such numbers will be rounded during synchronization.
Computed column is not mapped as PERSISTED. | This warning appears when the target computed column, unlike source computed column, is not mapped as PERSISTED. Data in such columns can not be synchronized.
Numeric columns have different precisions, migrating the data may cause rounding. | This warning appears when comparing float or integer columns and precision of source column is larger than the precision of target column. If the source float column contains data with larger precision, such data will be rounded when synchronizing. If the source integer column contains larger values than the target column can contain, such records cannot be synchronized.
Columns have different sizes, migrating the data may cause truncation. | This warning appears when comparing binary or text columns and source column has larger size than target column. If source contains records with longer data than target can contain, the data will be truncated in the target when synchronizing.
Columns have different collations | This warning appears when columns in target and in source have different collations. Data in such columns can not be synchronized.
Types are incompatible. | These columns cannot be compared. Appears when data of the source column cannot be converted to the data type of the target column, for example TEXT and BINARY.
Source column allows Nulls which can not be stored in Target. | This warning appears when source column is nullable and target column is not. If source table contains data with nulls in this column, such data cannot be synchronized.
Timestamp column cannot be updated. | This warning appears when target column has a timestamp data type. Such columns cannot be updated, so their values will not be synchronized.
Xml columns have different storage types CONTENT or DOCUMENT. | This warning appears when Xml columns have different types - CONTENT or DOCUMENT. Data in such columns can not be synchronized.
Xml columns have different xml collection types. | This warning appears when Xml columns have different collection types. Data in such columns can not be synchronized.

note Note

You may exclude columns from comparison and synchronization either by unmapping them or by clearing check boxes in the first column of Select columns for comparison grid on the Column Mapping dialog box.

ExpandedToggleIcon(9x12) See Also

Mapping

Data Comparison Options


Data Comparison Options

Data comparison and synchronization options are set in the Data Comparison Wizard. You can include views and tables to data comparison and set options for automatic object mapping on the Source and Target wizard page.

Other comparison options can be found at the Options page. Select Ignore Blobs to exclude BLOB columns from comparison, Ignore Case for case insensitive data comparison, and set paginal mode options for displaying data of compared tables or views. Records for comparison and synchronization can be selected on this page. You can select whether to view identical records, different records, records only in source, and only in target.

data-comparison-options-sqlserver

ExpandedToggleIcon(9x12) See Also

Comparing Data


Analyzing Comparison Results

This section tells how to perform data comparison analysis.

ExpandedToggleIcon(9x12) In This Section

How To: View Data Comparison Results
The topic describes a data comparison document interface and explains how to view comparison results.

How To: Generate Data Comparison Report
The topic explains how to view results of data comparison in the form of a report.

ExpandedToggleIcon(9x12) See Also

Synchronizing Data


How To: View Data Comparison Results

After you have compared data, a Data Comparison document will appear with Source and Target connections displayed in the upper part of the window and data comparison results displayed in two grids. The top grid lists all the compared tables and views with values indication the quantity of rows that are different, identical, existing only in Target or only in Source. The bottom grid contains the corresponding data records of the selected database object in the top grid. The records are grouped by their status and displayed on separate tabs. They are Different Records, Only in Source, Only in Target, Identical Records, and Conflict Records (it appears only in case any conflict records exist). The shortcut menu of the Data Comparison document and its top menu provide a number of options to manage the comparison results. The status bar in the bottom of the grid shows the number of differences per a column.

Database objects can be filtered by differences. You can select what objects to show: objects with different, identical records, only in source or only in target records.

To view the specific kind of tables:

1. Click the down arrow near the Filter button on the Comparison toolbar.
2. Select the corresponding option in the appeared menu. Several options can be selected at the same time.

note Note

In case a table has both different and identical records, it will be visible, independently of the selected options (Different or Identical).

You can also filter Incorrectly mapped objects and Correctly mapped objects.

To clear filtering:

1. Click the down arrow near the Filter button on theComparison toolbar.
2. Select All from the appeared menu.

The bottom grid allows you to view data differences between the corresponding tables or views. Select a table in the compared database object grid, and the data of these tables appears in the tabs below.

The Identical Records tab contains a grid with data rows that are identical and there is no need to update such records in target. Other tabs contain an additional column with check boxes in the grid. This column is named as action, that will be executed when synchronizing data - Update, Delete, or Insert. By selecting or clearing these check boxes you can control which rows will be affected with data synchronization. This column will not hide when scrolling grid.

note Note

Incorrectly mapped objects are displayed with Caution icon instead of check box in the Data Comparison document. The data of such database objects are not compared. Zero count will be displayed for all kinds of records. Objects with no data to synchronize (with only identical records or with no records at all) are displayed without check boxes.

Only in Source and Only in Target tabs contain grid with Insert and Delete columns respectively and data rows, that are stored only in the table of the source and of the target database respectively. Different Records tab contains grid with the following columns.

· Column with check boxes.
· Comparison key columns. Their value is the same for the compared tables.
· Other table columns. Source columns and target columns are grouped in pairs and marked as (Source) and (Target). When the values of the corresponding columns are different, this pair is highlighted with bold.

If a non-unique custom comparison key was chosen for any table or view, the fifth column in main grid and the fifth tab, Conflict Records appear. The tab consists of two grids containing all records with non-unique values of the comparison key from the corresponding database. These records cannot be synchronized.

If you cleared Update, Delete, or Insert column check boxes in some tables, you may view only tables with selected records or only tables without selected records. To filter tables, click the down arrow near the Filter button on the Comparison toolbar and select the corresponding option in the appeared menu.

To refresh data comparison results, click the Refresh button on the Comparison toolbar. To view long text or binary fields, use the Data Viewer and Editor window.

ExpandedToggleIcon(9x12) See Also

Analyzing Comparison Results

How To: Generate Data Comparison Report


How To: Generate Data Comparison Report

Data Compare for SQL Server provides a possibility to view results of data comparison in the form of a report.

ExpandedToggleIcon(9x12) Generating Report

To generate a comparison report after comparison, perform the following steps:

1. Click Comparison on the menu bar and then click comparison-report-icon Generate Comparison Report. The Comparison Report Wizard opens.

2. On the Format page, select the required report format (HTML, Excel, or CSV).
3. Specify the name of the report file.
4. Specify the location of the report file.
5. Check the View the report on completion check box to view the report upon creation.
6. On the Options page, select the required options.

7. Click Generate.

ExpandedToggleIcon(9x12) See Also

Analyzing Comparison Results

Synchronizing Data


Synchronizing Data

ExpandedToggleIcon(9x12) In This Section

How To: Synchronize Data
The topic guides you through the process of establishing consistency among data from a source and a target data storage.

Synchronization Warnings
The topic describes what may occur during data synchronization process.

Synchronization Error Handling
The topic helps you configure Data Compare for SQL Server behavior for synchronization script execution.


How To: Synchronize Data

note Note

Data synchronization can not be rolled back! It may change or delete data in your target database. It is highly recommended to backup target database before synchronizing data.

ExpandedToggleIcon(9x12) Synchronizing databases

To start synchronizing data of two databases:

1. Select the data to synchronize. To do this, select check boxes in the column with check boxes for the tables (or views) you want to synchronize. You may also click a separate table and select check boxes in the column with check boxes on the Only in source, Only in target, and Different tabs for individual records to determine which records to synchronize. Use the check box in the header of the grid to apply settings to all the grid rows.

Comparison results of SQL Servers databases

note Note

Incorrectly mapped objects are displayed with Caution icon instead of check box in the Data Comparison document. Objects with no data to synchronize (with only identical records or with no records at all) are displayed without check boxes. You cannot select them for synchronization.
2. On the Comparison toolbar, click [image] Synchronize. The Data Synchronization Wizard will be opened.

DataSynchtonizationWizard
3. Select whether to backup target database and backup files location. Then select whether to execute a script as a single transaction. You may click the Synchronize button and skip next steps to open the synchronization script in the editor, but this is not recommended if the script is too large. Click the Next button.
4. Select where to output synchronization script: open in the editor, save for the future execution, or immediately execute it.
5. You may either click the Synchronize button to generate the update script, or click the Next button to set synchronization options and view the synchronization action plan and synchronization warnings if any exist, and then click the Synchronize button.

ExpandedToggleIcon(9x12) See Also

Synchronizing Data

Synchronization Warnings


Synchronization Warnings

Synchronization warnings are displayed at the Summary Page of the Data Synchronization wizard. These warnings are the same as column level Mapping Warnings. But mapping warnings appear regardless of real data differences, they are generated if there are column datatype differences, which may cause errors or data loss in the tables to compare. Synchronization warnings appear only if there are data to be updated or inserted to the target table.

If you encountered synchronization warnings, than synchronization may fail or data loss may occur because of truncation or rounding. If the warning has the ErrorIcon icon, then the error will certainly occur when executing synchronization script. To avoid this error, exclude this table or corresponding records from synchronization by clearing the corresponding check boxes in the Data Comparison document.

ExpandedToggleIcon(9x12) See Also

Synchronizing Data

Synchronization Error Handling


Synchronization Error Handling

When synchronizing databases, you may configure Data Compare for SQL Server behavior for synchronization script execution in case of error.

If you want to have consistent data in any case, select the Use single transaction check box on the General tab of the Data Synchronization Wizard. If this option was selected, all the synchronization script is executed as one single transaction. In case of any error or synchronization cancelling, all changes are rolled back.

If you want, for example, debug the synchronization script, and you don't want changes to be rolled back, clear the Use single transaction check box. In such case script is executed till the batch, containing errors. All changes made by the statements before the batch, which caused error, are applied to the database, so you may see which changes were applied.

note Note

To avoid errors when synchronizing data, pay attention to the Synchronization Warnings. Exclude database objects that can cause errors from the synchronization.

ExpandedToggleIcon(9x12) See Also

Synchronizing Data


Working with Command Line

This section describes how to automate data comparison and synchronization using the command line.

note Note

The command-line interface is available only in certain editions of Data Compare for SQL Server. For detailed information on the features availability in the Data Compare for SQL Server editions, please refer to the Editions topic.

ExpandedToggleIcon(9x12) In This Section

How To: Compare and Synchronize Data through Command Line
This chapter explains how to use the command line interface to run comparisons.

How To: Schedule Database Synchronization
The topic explains how to use the Windows Task Scheduler to run database synchronization automatically.

Additional /datacompare Arguments
This topic contains all additional command line arguments for /datacompare switch and shows how to use them.

Options Used in Command Line for /datacompare
Lists the comparison options to use in the command line.

Executing Scripts through the Command Line
Learn how to automate executing scripts using the command line.

Formatting Code through the Command Line
Learn how to automate code formatting through the command line.


How To: Compare and Synchronize Data through the Command Line

You can automate data comparison and synchronization using the command line.

ExpandedToggleIcon(9x12) Running Comparisons from the Command Line

1. Click Start.
2. Type cmd in the Search programs and files text box and press the ENTER button.

note Note

To run the Command Line in Windows 8:

From the Desktop Mode

· Move the mouse cursor to the exact lower left corner until the desktop shortcuts menu appears.
· Right-click to see the shortcut menu and than click Run.

From the Charms Bar

· Move your mouse to the upper right corner until the Charms Bar appears.
· Select Apps from the list and type “run” in the search box.
· Click Run from the search results.

Use Windows + R Shortcut Keys

· In desktop mode, press the Windows + R keys, to show the Run command line.
3. Type a path to the datacompare.com file located in the dbForge Data Compare for SQL Server installation folder on your PC, and press the SPACE bar.

C:\Program Files\Devart\dbForge Data Compare for SQL Server\datacompare.com

4. Specify command line arguments (connection strings and actions you want to run).

For example, specify the type of the operation.

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /datacompare /?

5. Specify the objects that will be compared and synchronized.

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /datacompare /compfile:"D:\mycompdoc.dcomp"

6. Synchronize data directly into the database and generate a synchronization script file.

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /datacompare /compfile:"D:\mycompdoc.dcomp" /sync:"D:\mysync.sql"

7. Generate a comparison and synchronization protocol into a file.

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /datacompare /compfile:"D:\mycompdoc.dcomp" /sync:"D:\mysync.sql" /log:"D:\mylog.log"

8. Compose a comparison report.

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /datacompare /compfile:"D:\mycompdoc.dcomp" /sync:"D:\mysync.sql" /log:"D:\mylog.log" /report:"D:\myreport.html"

9. Specify the report format. HTML and EXCEL formats are available.

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /datacompare /compfile:"D:\mycompdoc.dcomp" /sync:"D:\mysync.sql" /log:"D:\mylog.log" /report:"D:\myreport.html" /reportformat:HTML

10. Press ENTER to run the process.

Tip: To see a quick help on the arguments available in the command line, type the following:

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /?

ExpandedToggleIcon(9x12) Generate File With Command Line Arguments

To generate a file with command line arguments, open the Data Comparison wizard.

To access the Data Comparison Wizard click New Data Comparison on the start page. Alternatively, on the File menu, click NewDataComparisonButton

Select Source and Target for comparison. Go through other wizard pages to tune the data comparison.

On the Options tab, click Save settings to a command line arguments file and specify the file name and location to save the file. The selected Source and Target connection strings along with comparison options will be saved as command line arguments in the file. You can edit the values of comparison options in the file. For more information, go to the Options Used in Command Line topic.

Note that the generated file does not contain password information for security purposes. You should edit the file and enter the passwords manually.

You can see available additional arguments and learn how to use them in the Additional /datacompare Arguments topic.

The command line string with /argfile parameter will be written as follows:

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /argfile:file_name.txt

ExpandedToggleIcon(9x12) See Also

Working with Command Line

How To: Schedule Database Synchronization


How To: Schedule Database Synchronization

You can use Windows Task Scheduler to create and manage synchronization tasks that your computer will carry out automatically at the times you specify.

ExpandedToggleIcon(9x12) Create Synchronization Task

To create Windows task:

1. Run the Windows Task Scheduler.

note Note

To run the Windows Task Scheduler:

1. Click Start and then click Control Panel.
2. Click Administrative Tools.

note Note

If your current view is Category, click System and Security, and then click Administrative Tools
3. Click Task Scheduler.
3. Click the Action menu, and then click Create Basic Task.
4. Type a name for the task and an optional description, and then click Next.
5. Do one of the following:
· To select a schedule based on the calendar, click Daily, Weekly, Monthly, or One time, click Next; specify the schedule you want to use, and then click Next.
· To select a schedule based on common recurring events, click When the computer starts or When I log on, and then click Next.
· To select a schedule based on specific events, click When a specific event is logged, click Next; specify the event log and other information using the drop-down lists, and then click Next
6. To schedule a program to start automatically, click Start a program, and then click Next.
7. Click Browse to enter a path to the datacompare.com file in Program/script. (The default path is C:\Program Files\Devart\dbForge Data Compare for SQL Server.)
8. Also, make sure to specify arguments in the Add arguments field.
9. Click Next.
10. Click Finish.

ExpandedToggleIcon(9x12) See Also

Working with Command Line

Additional /datacompare Arguments


Additional /datacompare Arguments

This topic gives detailed description of command line switches and examples of their usage.

You can select the required options while setting the comparison in the Data Comparison wizard and generate a file with command line arguments by clicking Save settings to a

ExpandedToggleIcon(9x12) Arguments

To get more information on switches related to data comparison in the command line interface, you can type:

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /datacompare /?

Below all switches of this option are described, together with usage examples.

Action | Parameter
Load command line settings from comparison *.dcomp project file | /compfile:<path>
Save the comparison results to a log file, specify the file location and name. | /log:"D:\Log.log"
Exclude objects from comparison if they match the given expression by using the /meobjmask argument and specifying the needed expression. To turn the option off, specify No, N, Off, False, F. | /meobjmask:<expression/N>
Exclude columns from the comparison if they match the given expression. To turn off the option, specify: No, N, Off, False, F. | /mimask:<expression/N>
Include objects to comparison if they match the given expression by using the /miobjmask argument and specifying the needed mask expression. To turn the option off, specify No, N, Off, False, F. | /miobjmask:<expression/N>
Specify a path to the report file. Note, that in this case there is no need to specify the file format separately. | /report:"D:\report_file.html"
To generate and save a comparison report, specify the report format (HTML, XLS, CSV) along with the report location and name. | /reportformat:<HTML|XLS|CSV>
Generate and save a synchronization script, specify the file location and name. If an output file path is specified, the program will generate only a synchronization script. | /sync:"D:\sync_script.sql"

ExpandedToggleIcon(9x12) Usage Examples

To practice comparison and synchronization through the command line, try to generate a synchronization script for a database backup and a live database. To do this, you should first change the default path in the command line by typing cd <required path> (for example, C:\Program Files\Devart\dbForge Data Compare for SQL Server\datacompare.com) and pressing Enter. After the default directory has changed, type the following arguments into the Command Prompt:

"C:\Program Files\Devart\dbForge Data Compare for SQL Server\datacompare.com" /datacompare /source backup:"D:\backup_file.bak" /target server:mssql2014 database:db_name user:user_name password:"password" /CheckIdentical:Yes /sync:"D:\sync_script.sql"( /report:"D:\report_file.html")

1. Compare data using settings from a file saved earlier:

/datacompare /compfile:"D:\workDir\DC1vsDC2.dcomp"

2. Compare and synchronize data using connection string. Log will be written to the specified file: /datacompare /source connection:

"Connect Timeout=120;Data Source=SqlServer1;Initial Catalog=db1;Integrated Security=False;User ID=sa;Password=sa;Pooling=False" /target connection:"Connect Timeout=120;Data Source=SqlServer2;Initial Catalog=db2;Integrated Security=False;User ID=sa;Password=sa;Pooling=False" /sync /log:"D:\sync.log"

3. Compare data of the specified databases and save the synchronization script to the:

D:\compare_result.sql file: /datacompare /source server:SqlServer user:sa password:sa database:db1 /target server:SqlServer user:sa password:sa database:db2 /sync:"D:\compare_result.sql"

4. Compare and synchronize data using settings from the file, do not generate comments in the synchronization script, turn off dml triggers during synchronization; generate a report to the specified file in the HTML format:

/datacompare /compfile:"DC1vsDC2.dcomp" /nocomments:yes /nodml:yes /report:"report.txt" /reportformat:HTML /sync

5. Compare and synchronize data using settings from a file. Synchronize Lob columns using files:

/datacompare /compfile:"D:\workDir\DC1vsDC2.dcomp" /fspath:"\\SqlHost\Temp" /sync

6. Compare data and generate data report using settings from a file. Comparison and data writing settings of the different objects will be included into the report.

/datacompare /compfile:"DC1vsDC2.dcomp" /report:"report.html" /incdata:Yes /incs (settings:Yes)

ExpandedToggleIcon(9x12) See Also

Working with Command Line

Options Used in Command Line for /datacompare


Options Used in Command Line for /datacompare

You can select the required options while setting the comparison in the Data Comparison wizard and generate a file with command line arguments by clicking Save settings to a command line arguments file on the Options wizard page. Also you can set comparison options by using the /option_name:[Y/N] switch in the Command Prompt. Specify either full or short names of the options. Here is the list of their names.

By default, dbForge Data Compare for SQL Server generates a file with command line arguments and writes all comparison and synchronization options into it. Each option is written like the following: /option_name: [Y/N]

You can edit the file to turn on/off required options. To turn on comparison and synchronization options, edit their values to "Yes", "Y", "True", "T", or "On". To turn off the options, change their values to "No", "N", "False", "F", or "Off".

Each option has a full and short name. You can type either name of a required option into the Command Prompt instead of editing the file.

See below the list of options with their full and short command line names.

ExpandedToggleIcon(9x12) Options List
Full Name | Short Name | Option
CheckDifferent | chkdiff | Include different records into comparison results
CheckIdentical | chkequal | Include identical records into comparison results
CheckOnlyInSource | chksource | Include only in source records into comparison results
CheckOnlyInTarget | chktarget | Include only in target records into comparison results
CompareClrTypesAsBinary | clrasbin | Compare and synchornize CLR types as binary, otherwise as string
CompareColumnStoreTables | colstore | Compare tables with COLUMNSTORE indexes
CompareMemoryOptimizedTables | moptimize | Compare memory optimized tables
CompareTables | tables | Include tables into comparison
CompareViews | views | Include views into comparison
ExcludeObjectsByMask | meobjmask | Exclude tables or views by mask
IgnoreBlobColumns | miblob | Ignore blob columns during comparison
IgnoreCase | icase | Ignore case in symbols for non-key columns
IgnoreColumnsByMask | micolmask | Specify a custom wildcart expression for columns names to exclude columns from comparison
IgnoreComputedColumns | micomput | Ignore computed columns
IgnoreEndOfLine | ieol | Ignore end of line characters during comparison and synchronization
IgnoreIdentityColumns | miident | Ignore identity columns during comparison
IgnoreLeadingSpaces | ilspaces | Ignore leading spaces
IgnoreRowguidColumns | mirowguid | Ignore ROWGUID columns during comparison
IgnoreTemporalTableSysColumns | isyscol | Ignore coumn is SYSTEM_TIME for temporal tables
IgnoreTimestampColumns | mitime | Ignore TIMESTAMP columns during comparison
IgnoreTrailingSpaces | ispaces | Ignore whitespaces in the end of strings during comparison and synchronization
IncludeObjectsByMask | miobjmask | Include tables or views by mask
IsEmptyStringEqualsNull | emptyeqnull | Treat NULL and EMPTY STRING as the same value
IsIgnoreTime | itime | Ignore time for fileds of the DATETIME type and compare only dates
MappingIgnoreCase | micase | Ignore case in object names when mapping them
MappingIgnoreSpaces | mispace | Ignore spaces in object names when mapping them
MappingIgnoreUnderscores | miunder | Ignore underscore in object names when mapping them
RoundFloatTypes | round | Round float types up to 3 digits
BulkInsert | bi | Use bulk insert for data insertion
CheckConcurrencyUpdates | concupd | Check for the concurrecncy updates
CreateBackupFolder | cbackupfolder | Create folder for database backup
DisableDdlTriggers | noddl | Disable DDL triggers in the beginning of synchronization
DisableDmlTriggers | nodml | Disable DML triggers in the beginning of synchronization
DisableForeignKeys | nofk | Disable foreign keys in the beginning of synchronization
DropCheckConstraints | dropcheck | Drop check and not null constraints in the beginning of synchronization
DropKeys | dropkeys | Disable primary keys, indexes and unique constraints
ExecuteAsSingleTransaction | tran | Execute a synchronization script as a single transaction
FileStoragePath | fspath | Specify a backup file location
IncludePrintComments | iprint | Include print comments into output while executing the script
ReseedIdentityColumns | reseed | Reseed a current value for identity columns
RestoreConstraintsWithCheck | checkconstrrestore | Restore constraints with CHECK
UseSchemaNamePrefix | fullnames | Generate fully qualified object names
IncludeComparisonSettings | incsettings | Include comparison settings
IncludeDifferencesPerColumns | incdiffcols | Include differences per columns
IncludeIdenticalObjects | incident | Include identical objects
IncludeObjectsData | incdata | Include objects data
IncludeOnlyColumnsWithChanges | inccolswchanges | Include only columns with changes

ExpandedToggleIcon(9x12) See Also

Working with Command Line

Advanced Data Comparison Topics


Executing Scripts through the Command Line

You can automate executing the scripts using the command line.

Click Start.

1. Type 'cmd' in the Search programs and files text box and press the ENTER button.

note Note

To run the Command Line in Windows 8:

From the Desktop Mode

· Move the mouse cursor to the exact lower left corner until the desktop shortcuts menu appears.
· Right-click to see the shortcut menu and than click Run.

From the Charms Bar

· Move your mouse to the upper right corner until the Charms Bar appears.
· Select Apps from the list and type “run” in the search box.
· Click Run from the search results.

Use Windows + R Shortcut Keys

· In desktop mode, press the Windows + R keys, to show the Run command line.
3. Type a path to the datacompare.com file located in the dbForge Data Compare for SQL Server installation folder on your PC, and then press the SPACE key.

C:\Program Files\Devart\dbForge Data Compare for SQL Server\datacompare.com

4. To execute the corresponding script, use the /execute command, and press the SPACE key.

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /execute /?

5. Specify connection details of the server where to execute the script.

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /execute
/connection:"Data Source=DBMSSQL\MSSQL2012;Integrated Security=False;User ID=sa"

6. Specify the script file.

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /execute
/connection:"Data Source=DBMSSQL\MSSQL2012;Integrated Security=False;User ID=sa" /inputfile:"script.sql"

7. Specify the password.

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /execute
/connection:"Data Source=DBMSSQL\MSSQL2012;Integrated Security=False;User ID=sa" /inputfile:"script.sql"
/Password:mypsw

8. To hide the command line window, use the /quiet command. (Useful for batch files).

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /execute
/connection:"Data Source=DBMSSQL\MSSQL2012;Integrated Security=False;User ID=sa" /inputfile:"script.sql"
/Password:mypsw /quiet

9. Press ENTER to run the process.

If you use the /argfile argument, all the following commands are specified inside an argfile:

/execute

/connection:"Data Source=DBMSSQL\MSSQL2012;Integrated Security=False;User ID=sa"

/inputfile:"script.sql"

In this case, the command line string will be written as follows:

C:\Program Files\Devart\dbForge Data Compare for SQL Server>datacompare.com /argfile:myarg.txt

ExpandedToggleIcon(9x12) Arguments Used in Command Line

Select corresponding command line switches to perform the required operations:

Argument | Action and Usage
/connection | This switch is used to specify a connection string. Command usage looks like: /connection:<connection_string>
/database | This switch is used to specify a database to execute the script to. Databases specified in the script before will be ignored. It does not affect the objects specified with fully qualified names.
/inputfile | This switch is used to specify an SQL or ZIP file with the script to execute.
/password | This switch is used to specify a server password. It overrides the password specified in the connection string. Command line usage looks like: /password:<pw>
/encoding | This switch is used to specify the encoding which should be applied to open and execute the script. Command line usage looks like: /encoding:<encoding>

ExpandedToggleIcon(9x12) See Also


Formatting Code through the Command Line

You can automate code formatting using the command line.

Click Start.

1. Type 'cmd' in the Search programs and files text box and press the ENTER button.

note Note

To run the Command Line in Windows 8:

From the Desktop Mode

· Move the mouse cursor to the exact lower left corner until the desktop shortcuts menu appears.
· Right-click to see the shortcut menu and than click Run.

From the Charms Bar

· Move your mouse to the upper right corner until the Charms Bar appears.
· Select Apps from the list and type “run” in the search box.
· Click Run from the search results.

Use Windows + R Shortcut Keys

· In desktop mode, press the Windows + R keys, to show the Run command line.
3. Type a path to the datacompare.com file located in the dbForge Data Compare for SQL Server installation folder on your PC, and press the SPACE key.

C:\Program Files\Devart\dbForge Data Compare for SQL Server\datacompare.com

4. Specify the operation you want to perform (code formatting) and the required parameters and arguments:

datacompare.com /formatsql [/switch1[:value | [parameter1:value parameter2:value ..]] /switch2 ..]

Tip: To see a quick help on the arguments available in the command line, type the following:

/formatsql /?

5. Press ENTER to run the process.

note Note

You can set the unlimited quantity of the required extensions:
datacompare.com /formatsql /sourcefolder:"c:\" /filextention:*.sql /filextention:*.prg /filextention:*.db1

ExpandedToggleIcon(9x12) Arguments Used in Command Line

Select corresponding command line switches to perform the required operations:

Argument | Action and Usage
/connection | This switch is used to specify a connection string. Command usage looks like: /connection:<connection_string>
/filextention | This switch is used to specify the extension of the source folder files that will be formatted. The .sql extension is selected by default. Command usage looks like: /filextention:*.<sql|prc|txt|...>
/log | This switch is used to generate a formatting log file in the specified directory. Command usage looks like: /log:<filepath>
/outputfile | This switch is used to specify the path to an output file where formatting results of the source file will be saved (in this case, the source file is saved without changing). If the parameter is not specified, the formatting results will be saved in the source file. Command usage looks like: /outputfile:<path>
/outputfolder | This switch is used to specify the patch to an output folder where the source folder files with formatting results will be saved (files form the source folder will no be changed). If the parameter is not specified, the formatting results will be saved in the source folder. Command usage looks like: /outputfolder:<path>
/password | This switch is used to specify a server password. It overrides the password specified in the connection string. Command usage looks like: /password:<pw>
/profile | This switch is used to specify the path to a file that contains settings for formatting options. If the parameter is not specified, the default settings will be applied to the formatting options. Command usage looks like: /profile:<path>
/sourcefile | This switch is used to specify the source SQL file to be formatted. Command usage looks like: /sourcefile:<path>
/soucefolder | This switch is used to specify the path to a folder where the files for formatting are located. Command usage looks like: /sourcefolder:<path>
/includesubfolders | This switch is used to include the current directory and all subdirectories in search operation. Command usage looks like: /includesubfolders

ExpandedToggleIcon(9x12) See Also

Executing Scripts through the Command Line


Advanced Data Comparison Topics

This section contains advanced topics that describes data comparison and synchronization process.

ExpandedToggleIcon(9x12) In This Section

Working with Backup Files
The topic describes how to compare and synchronize backups.

Known Data Comparison Issues
The topic describes problems that can occur during comparison and synchronization process.

Type Compatibility Table
The topic describes which data types can be compared.

Data Comparison Process Overview
The topic gives basic information on data comparison and synchronization.

Data Synchronization Process Overview
The topic contains basic information on data comparison and synchronization.


Working with Backup Files

Data Compare for SQL Server provides an option of comparing data between backup files or between databases and backup files. This feature can be useful if you want, for example, to retrieve data from a backup file and compare it with your database without restoring or copying the backup from a remote network.

ExpandedToggleIcon(9x12) Comparing and synchronizing backup files

With Data Compare for SQL Server you can:

· compare a backup file with another backup file or with a database
· create a synchronization script from a backup

If you set backup file as a target, the synchronization wizard creates a script to update the database from which the backup was created. Backup files cannot be modified directly.

If you set backup file as the source, and a database is the target, the database can be synchronized with the backup.

ExpandedToggleIcon(9x12) Compatibility with backup files

Data Compare for SQL Server supports:

· native SQL Server backups

If you want to set up a comparison with the backup files usage you should keep in mind that Data Compare for SQL Server does not support:

· tables that do not have a primary key, unique index, or unique constraint
· views
· computed columns, but you can compare persisted computed columns
· string representations of CLR types (only binary representation is supported)
· custom comparison keys, but you can select an alternative unique index, or unique constraint
· row filtering using the SQL Filter Editor.

ExpandedToggleIcon(9x12) See Also

Advanced Data Comparison Topics

Known Data Comparison Issues


Known Data Comparison Issues

There are some known problems that may abort data comparison process:

· When you are working with Azure, you can get the "A transport-level error has occurred when receiving results from the server. (provider: TCP provider, error: 0 - An existing connection was forcibly closed by the remote host.)" error, and the comparison process will be aborted.

This problem occurs because Azure closes connection.

When a connection is opened, a connection pool that stores low-level connections and keeps them open to reduce performance loss when re-opening these connection is created. Data Compare for SQL Server uses the ADO.NET model for data access, where pool timeout is 10 minutes, whereas Azure closes low-level connections after 5 minutes timeout. That's why you get the above message when trying to access data.

Microsoft ADO.NET developers should correct such behaviour.

ExpandedToggleIcon(9x12) See Also

Advanced Data Comparison Topics

Type Compatibility Table


Type Compatibility Table

This table demonstrates which data types can be compared by Data Compare for SQL Server.

- can be compared

TableC - explicit conversion is performed when comparing. A synchronization script will contain already converted data. On the Different, Equal, and Only in Target tabs in the Data Comparison document, you will see data in Target data type, Only in source will display data in the Source data type.

Table! - possible data loss

Empty cells mean that these type pairs cannot be compared.

ExpandedToggleIcon(9x12) See Also

Advanced Data Comparison Topics

Data Comparison Process Overview


Data Comparison Process Overview

dbForge Data Compare for SQL Server gives you a perfect opportunity to compare data between different databases and backup files with many useful features. They include the following:

· Comparison of data between different databases and backup files
· Displaying of data comparison results in a convenient UI, easy for analysis and synchronization
· Quick data synchronization of target and source databases or backup files
· Asynchronous comparison and synchronization

By default data comparison is performed only for the objects with the same names and owners. Process of choosing corresponding database objects in source and target for comparison is called object mapping. You can use Data Compare for SQL Server automatic mapping or map database objects manually. Data Compare for SQL Server allows you to customize mapping of schemas, tables (views) and columns, so you can compare data of objects with non-equal names, owners, and structure.

The following tables and views cannot be compared:

· Invalid tables or views.
· Tables or views, metadata of which can not be retrieved.

By default, data is compared by a primary or unique key, but other key or custom column set can be defined. A comparison key is used to determine which rows correspond to each other. It is not recommended to use a non-unique comparison key. If the table does not have a suitable key, you should manually select a custom key for this table when comparing. You should always set a custom key for views when comparing data with the Compare Views check box selected.

Data comparison can be saved to the file and opened later.

ExpandedToggleIcon(9x12) See Also

Advanced Data Comparison Topics

Data Synchronization Process Overview


Data Synchronization Process Overview

After you have compared data, Data Compare for SQL Server gives you an easy and convenient way to synchronize data.

You may manually specify which tables and even which records to synchronize. Use the check boxes in the first column of the data comparison document grid to include or exclude objects to synchronization.

Note that it is highly recommended to backup target database before data synchronization. The Data Synchronization Wizard allows you to perform backup.

Synchronization script is divided into batches with GO commands. GO statements are inserted after DML statements and statements, setting server options. GO statements are always inserted after the end of the DML statements for any table or view. If there are too many DML statements for a table or view (more than 1000 statements or more than 1 Mb of statements), they are divided into several batches with GO statements. In such case GO statements are inserted after each 1000 statements or after each 1 Mb of statements, depending on which comes first. You can synchronize database as one single transaction. If so, all synchronization actions will be rolled back in case of error. Otherwise, all statements before GO block with error will be executed, and statements of the invalid block and after invalid block will not be executed.

If you synchronize data with different data type, you may encounter synchronization warnings. They are displayed at the Summary tab of the Data Synchronization Wizard. If you have any synchronization warnings, that means that during synchronizing data you may encounter errors or data loss because of rounding, truncation, etc. For more information about synchronization warnings, read the Synchronization Warnings topic.

The Data Synchronization Wizard allows you to either apply updates immediately or create an update script for the Target database and save it to a file. For more information, visit the How To: Synchronize Data topic.

Before launching the synchronization, you may view Action Plan that contains all the actions that will be performed during synchronization. The action plan represents the synchronization script structure, so it is good to analyze it before this script will be generated or executed if you have chosen to execute the script immediately. The action Plan is displayed on the Summary page of the Data Synchronization Wizard.

ExpandedToggleIcon(9x12) See Also

Advanced Data Comparison Topics

Comparing Data


Writing and Executing SQL Statements

ExpandedToggleIcon(9x12) In This Section

Writing SQL Statements
Basic tips on writing SQL statements ans working with SQL scripts.

Executing SQL Statements
Explains some special features for executing SQL statements.

Viewing Server Messages and Errors
Describes windows designed to display server messages and errors.

Using Parameters
Information on how to use parameters to simplify process of editing the query.

Executing Large Scripts
Tells how to execute a large script without opening it in the editor.

Opening Large Scripts in SQL Editor
Contains information about opening large scripts in the editor.

Associating Windows with Connection
Information on how documents and tool windows use connections.

SQL Document Shortcut Keys
Describes the shortcut keys used in dbForge Data Compare for SQL Server when working with an SQL document or stored procedure.


Writing SQL Statements

Every SQL document contains the Text view with SQL editor in it. You switch to this view to edit your SQL queries.

When you type text in SQL editor, it automatically recognizes and highlights SQL syntax.

For ease of SQL writing and reviewing, you can also use such supported shortcut keys as: CTRL+PLUS (+) KEY (to zoom the query in), CTRL+MINUS (-) KEY (to zoom the query out), CTRL+0 (to return an SQL document to the one-to-one scale).

You write and execute SQL queries not only one at a time but you may as well compose SQL scripts. SQL scripts consist of multiple SQL statements separated by the appropriate statement delimiter.

ExpandedToggleIcon(9x12) See Also

Writing and Executing SQL Statements

Executing SQL Statements


Executing SQL Statements

ExpandedToggleIcon(9x12) How to Run Execution

Entire Script

To execute the entire script, click the Execute button on the SQL toolbar.

Alternatively, on the SQL menu, select the Execute command.

Selected Block of Text

To execute an arbitrary text block:

1. Select the text block using the mouse or keyboard.
2. Run the Execute command as when executing the entire script. Alternatively, select Execute Selection from the shortcut menu of SQL Editor

Current Statement

To execute current statement, click the Execute Current Statement button on the SQL toolbar.

Alternatively, right-click a required statement, and select Execute Current Statement command on the shortcut menu.

Execute to Cursor

To execute script to the current position of the cursor:

1. Move cursor to the required position.
2. Click Execute to Cursor on the shortcut menu or press Ctrl+Shift+F10.

ExpandedToggleIcon(9x12) How to Stop Execution

To stop SQL execution, click Stop Execution the SQL toolbar.

ExpandedToggleIcon(9x12) Representing Query Execution Results

The query execution results can be represented in two ways - in text and in grid formats.

To represent results as text, click Results as Text on the SQL toolbar before query execution.

To represent results as grid, click Results as Grid on the SQL toolbar before query execution.

ExpandedToggleIcon(9x12) See Also

Writing and Executing SQL Statements


Viewing Server Messages and Errors

When you run a query against a database server, it returns a response to the client. There are three types of server response to an SQL query:

· Tabular data
· Status (info) message
· Error

Tabular data is displayed in the data editor. Status messages and errors are logged to Output window. Errors are not only logged to Output window they are also shown in Error List window.

ExpandedToggleIcon(9x12) Using Output Window

Following image represents general view of Output window.

note Note

Depending on the product the Output window appearance may vary.

Output Panes

The window can contain up to four output panes (depending on the specific product):

· General pane contains most output messages, not only from a database server but from the application itself.
· Data pane displays query results that are represented as a formatted text. This pane remains empty unless Redirect Data to Output Window option is set in any SQL document.
· SQL Log pane displays all SQL queries executed by an application during the current session. But you need to turn on Write queries sent by the program to SQL Log option to see those queries.

As you can see from the above screen-shot, server errors are also logged to Output window. And you can navigate to the place of an error by double-click of from the shortcut menu.

Searching Output Messages

You can search text in Output window. To find specific text:

1. Focus Output window.
2. Open Find and Replace window by pressing CTRL+F.
3. Enter search text and press ENTER or click the Search button.

ExpandedToggleIcon(9x12) Using Error List Window

When something goes wrong, typically you see an error. If this is a user or database server error, such as mistyped query, in most cases you will see it in Error List window.

Here is an example of an error displayed in Error List.

Error List shows not only errors, but also warnings and informational messages which require user attention. Warning is in essence a non-blocking error. And informational message is just a user notification.

You can filter messages by type using appropriate buttons on the toolbar of Error List window.

You can navigate to the error location by double-clicking it in the list or by selecting Go to Error from the shortcut menu.

How to View Errors from Current Document Only

Error List aggregates all error messages in the application. And if you have multiple open documents with errors, the error processing can quickly become awkward.

But the window has one more filter button - In Active Document. This button allows to view only those errors that are located in current document window.

ExpandedToggleIcon(9x12) See Also

Writing and Executing SQL Statements

Using Parameters


Using Parameters

ExpandedToggleIcon(9x12) What is a Parameter?

Parameter is a placeholder for a variable that contains a value of some type that is passed to a database server along with the SQL text at the query execution time. Also, parameter can hold values returned by a server after query or stored procedure execution.

You can benefit from using of parameters in the following situations:

· When you execute a query multiple times with different input values
· When you debug a query from your application code

ExpandedToggleIcon(9x12) Adding Parameters to a Query Text

Parameters are declared using '@' prefix followed by name of the parameter. Prefix is included to the name of the parameter.

For example:

SELECT
Employee.*
FROM
HumanResources.Employee
WHERE
Employee.Title = @Job AND
Employee.VacationHours <= @Level

@Job and @Level are parameters in this query.

ExpandedToggleIcon(9x12) Modifying Parameter Values and Types

When you run a query that contains parameters with empty values, you will automatically be prompted to initialize them.

To set parameter values and types, select Edit Parameters on the SQL toolbar, or press F8. In the opened Edit Parameters dialog box, set parameters' type, value, and other properties.

note Note

When you execute a query with preset parameter values, you will not be automatically prompted to edit them. To edit parameters, press F8 or select Edit Parameters on the SQL toolbar.

ExpandedToggleIcon(9x12) See Also

Writing and Executing SQL Statements


Executing Large Scripts

Data Compare for SQL Server allows you to execute large scripts without opening SQL Editor and loading the whole script in memory. When you try to open a large script, you will be prompted to execute it with the help of the Execute Script Wizard.

To execute a large script:

1. On the Database menu, click ExecuteLargeScript Execute Large Script.
2. In Connection, select a connection to a required database server against which you want to execute your script.
3. In Database, select a required database from the drop-down list/
4. In File name, specify the path to the script you want to execute.
5. In SQL file encoding, ensure that the file encoding is selected correctly. The program automatically selects it basing on the script. If it fails, the default encoding (the current Windows encoding on the machine where the program is running) is selected. You can always select a required encoding from the drop-down list box.
6. Click Execute to execute the script.

ExpandedToggleIcon(9x12) See Also

Writing and Executing SQL Statements

Opening Large Scripts in SQL Editor


Opening Large Scripts in SQL Editor

To avoid performance slowdown, some features are disabled when working with large SQL scripts.

If script size exceeds 10 Mb, the SQL syntax highlight is disabled. It is not enabled when you reduce the script in the editor. You should reopen script to re-enable the feature.

note Note

Maximum file size the application can open depends on available memory on your computer.

ExpandedToggleIcon(9x12) See Also

Writing and Executing SQL Statements


Associating Windows with Connection

When several connection are established in the Database Explorer, you can execute queries or perform another actions with either of them. SQL documents are associated with a connection which you can see or set on the Connection toolbar. The drop-down list in the toolbar shows what connection is associated with the active document or tool window. If a tool window, that does not require a connection, is active, connection of the active document (or tool window in the document area) is displayed.

When creating or opening a SQL document, it is assigned a default connection. If you create SQL document with no connection present in Database Explorer, the document will have no connection and you can not execute SQL or retrieve data. You can change connection for SQL document by selecting required connection in the Document Connection box on the Connection toolbar.

note Note

Database Explorer is not available in dbForge Data Compare for SQL Server and dbForge Schema Compare for SQL Server.

ExpandedToggleIcon(9x12) See Also

Writing and Executing SQL Statements

SQL Document Shortcut Keys


SQL Document Shortcut Keys

Use following shortcut keys when working with an SQL document or stored procedure.

Icon | Command Name | Shortcut Keys | Action | Where is used
Execute | Execute | F5 | Execute query associated with current document | SQL editor
PreviousSQL | Previous SQL | Ctrl+Shift+ Up Arrow | Previous SQL statement from history | SQL editor
NextSQL | Next SQL | Ctrl+Shift+ Down Arrow | Next SQL statement from history | SQL editor
History | SQL History | Ctrl+Alt+H | Open SQL History dialog | SQL editor
Parameters | Edit Parameters | Ctrl+Shift+P | Edit parameters | SQL editor
DataAsText | Redirect Data To Output Window | Ctrl+Shift+T | Show data as text in the Output window | SQL editor
IListMembers | List Members | Ctrl+J | List members | SQL editor
IListMembers | List Members | Ctrl+K, L | List members | SQL editor
ICompleteWord | Complete Word | Ctrl+Space | Complete word | SQL editor
ICompleteWord | Complete Word | Ctrl+K, W | Complete word | SQL editor
ICompleteWord | Complete Word | Alt+Right Arrow | Complete word | SQL editor
IParameterInfo | Parameter Info | Ctrl+Shift+Space | Parameter information | SQL editor
IParameterInfo | Parameter Info | Ctrl+K, P | Parameter information | SQL editor
IQuickInfo | Quick Info | Ctrl+K, I | Display quick information | SQL editor
IQuickInfo | Quick Info | Ctrl+K, Ctrl+I | Display quick information | SQL editor
Comment | Comment Selection | Ctrl+E, C | Comment selection | SQL editor
Uncomment | Uncomment Selection | Ctrl+E, U | Uncomment selection | SQL editor
 | Toggle Outlining Expansion | Ctrl+M, M | Toggle outlining expansion | SQL editor
 | Toggle All Outlining | Ctrl+M, L | Toggle all outlining | SQL editor
 | Stop Outlining | Ctrl+M, P | Stop outlining | SQL editor
 |  | Ctrl+F2 | Switch to Navigation Bar | SQL editor

These shortcuts are default shortcuts. All shortcuts can be customized.

ExpandedToggleIcon(9x12) See Also

Writing and Executing SQL Statements


Working with Data in Data Editor

This section describes some things you should know about manipulating data in dbForge Data Compare for SQL Server.

ExpandedToggleIcon(9x12) In This Section

Viewing Data in Grid
Describes how to use multiple grid editor's features to customize the data display and get more insight.

Editing Data in Grid
Describes how to quickly edit data using various grid editor's features.

Data Shortcut Keys
Lists useful shortcut keys for working with data.


Viewing Data in Grid

This section describes features for viewing data in dbForge Data Compare for SQL Server.

ExpandedToggleIcon(9x12) In This Section

Viewing Data in Grid Overview
Tells how to efficiently view data in Data Compare for SQL Server.

Sorting Data in Grid
Tells how to sort data in the grid.

Grouping Data in Grid
Tells how to use data grouping.

Filtering Data in Grid
Tells how to apply various filter conditions to filter data in the grid.

Server-side and Client-side Sorting and Filtering Data in Grid
Explains how sorting and filtering are processed on the client side and on the server side. Gives a list of problems that may be encountered.

Paginal Mode
Teaches how to use paginal mode to limit row count in the grid.

Auto-search Mode
Teaches how to use auto-search mode to quickly locate data.

Card View
Describes how to use card mode for graphical data representation.

ExpandedToggleIcon(9x12) See Also

Working with Data in Data Editor

Editing Data in Grid


Viewing Data in Grid Overview

The Data Editor allows you to view and quickly edit data right in the grid. For more information on editing data refer to topic Editing Data in Grid.

ExpandedToggleIcon(9x12) To Access Data

· Execute a query that returns data.
· Open the table or view editor and switch to the data view.

Use the rich set of data management options in the shortcut menu.

note Note

Actual document look may slightly vary from the above image, depending on the product you use.

note Note

If you want to retrieve all data from a table with a large number of records, a message warning you about the possibility of the "Out of memory" exception is shown, and you can choose either of the following actions - continue retrieving data, cancel retrieving data, or turn on Paginal Mode.

To simplify data analysis, you can use the following features:

· Grouping Data in Grid
· Sorting Data in Grid
· Filtering Data in Grid
· Paginal Mode
· Card View
· Auto-search Mode
· Data Viewer

note Note

By default, Paginal Mode is enabled in data view with 1000 records per page, so only 1000 records are displayed at once. For more information, see Paginal Mode.

You can change columns order and width, group by order via dragging column headers into required place. You can fit the column's width to the column content by right-clicking on an appropriate header and choosing Best Fit from shortcut menu. To adjust widths of all columns at once, choose Best Fit (all columns) instead. Note that this operation can take some time when there are many records in the grid.

To refresh data, click the Refresh command in the Data menu (for Data view), the shortcut menu, or on the toolbar. To abort too long refresh operation, click the Stop Refresh command in the Data menu (for Data view) or on the toolbar.

Grid rows' background and foreground colors can be set. You can set them separately for odd and even rows, focused row, selected rows, focused cell, group rows.

Data row can be viewed, edited and printed as cards. To learn more about it, visit the Card View topic.

Data Compare for SQL Server allows you to view data as text. To retrieve data as text click Redirect Data to Output Window on the SQL toolbar, switch to the Data tab in the Output window and execute the query to get data. You cannot edit data in the Output window.

Tip: you can use down arrow to add an empty row to the table displayed in the grid. If you've added an empty row accidentally, you can easily delete it using the up arrow.

note Note

Null values 0000-00-00 in fields of DATE data type are displayed as 01.01.0001. Null values of TIMESTAMP fields are displayed as 01.01.0001 0:00:00.

ExpandedToggleIcon(9x12) See Also

Viewing Data in Grid

Sorting Data in Grid


Sorting Data in Grid

By default, Data Compare for SQL Server retrieves unsorted data from tables if the Retrieve Data option was used. If data was retrieved after executing an SQL statement, it will be sorted according to the operators used in this statement (in case operators are sorting-related, e. g. ORDER BY).

To sort data

To sort data in grid or to change the sort order, click the header of a column. Alternatively, right-click a column header, and then click Sort Ascending or Sort Descending on the shortcut menu.

To assign a secondary sorting, click another column header, while holding down the SHIFT key. You can set as many sorting columns as you need. To stop sorting on a certain column, click it while holding the CTRL key.

To clear column sorting, click the Clear Sorting option on the table shortcut menu.

The current sort order of a column is indicated by the sort glyph (a small arrow displayed at the column header's right edge). If data is sorted in ascending order, the sort glyph represents an up-arrow. When sorting in descending order, the sort glyph is displayed as a down-arrow. If the column isn't sorted, the sort glyph is hidden.

note Note

Actual document look may slightly vary from the above image, depending on the product you use.

ExpandedToggleIcon(9x12) See Also

Viewing Data in Grid

Grouping Data in Grid


Grouping Data in Grid

To group data by column, click ShowGroupByBox Show Group by Box on the document toolbar. The Group by Box pane will appear above the grid. Drag a column header you want the data to be grouped by to the pane.

Alternatively, right-click the required column header and click Group By This Column on the shortcut menu. The data is automatically displayed in groups marked with collapsed nodes. The column header is moved to the Group By Box pane.

note Note

Actual document look may slightly vary from the above image, depending on the product you use.

Group By Box is the area above the data grid where you can see the grouping order and perform further grouping-related operations. Drag a column header to Group By Box to group the data by that column. You can group the data by multiple columns. In this case the grid will display a tree of nested groups that you can expand by clicking '+' buttons. To collapse the groups, click '-' buttons.

To expand or collapse all groups at once, right-click the Group By Box pane, and then click Full Expand or Full Collapse on the shortcut menu.

To cancel grouping by column, drag-and-drop the column header from the Group By Box pane to the grid or right-click the column header, and then click Ungroup from the shortcut menu.

To remove all groupings, right-click Group By Box, and then click Clear Grouping on the shortcut menu.

ExpandedToggleIcon(9x12) See Also

Viewing Data in Grid

Filtering Data in Grid


Filtering Data in Grid

ExpandedToggleIcon(9x12) Hiding Data of a Column

1. Right-click the required column, and then click Visible Columns on the shortcut menu. The Visible Columns dialog box opens.
2. Clear the check box next to the column you want to hide in the grid.
3. Click OK to close the dialog box and apply the filter condition.

ExpandedToggleIcon(9x12) Filtering Data by Column

· On a column header, click the filer-button Filter button. Select the filter value from the drop-down list box. The box includes a set of values encountered in the column and the universal items such as All, Custom, Blanks, and Non Blanks.
· Right-click a column, and point to Quick Filter on the shortcut menu, and then click the required filtering condition.

quickfilter

When the data is filtered, the column Filter button will be changed to active-filter to indicate the applied filter. The filter condition appears at the bottom of the grid providing you a one-click quick access to the filter condition parameters. You can manage them in the following ways:

· To remove all filter conditions, click cancel-filter at the bottom of the grid. To remove the filter condition of a column, right-click this column and click Clear Filter on the shortcut menu.
· To switch from the filtered data to the full data display, clear the [image] check box at the bottom of the grid.
· To edit the filter condition, click edit-filter . The Filter Editor dialog box opens.

ExpandedToggleIcon(9x12) Applying a Custom Filter Condition to Column

1. Right-click the required column, point to Quick Filter on the shortcut menu, and then click [image]. The Filter Editor dialog box opens.
2. Choose a relation type and type values to build a filter.

filtereditor-oracle

Filter conditions in the Filter Editor dialog box are displayed as a tree with condition and group nodes. A group consists of several conditions or subgroups, united with a logical operator. To change a group logical operator, click it and select another one from the menu. To navigate between conditions and groups, use the UP ARROW and DOWN ARROW keys. To navigate between a condition column, a criteria operator and an operand value, use the LEFT ARROW and RIGHT ARROW keys.

To remove a condition, click FilterGreyDel or navigate to the condition and press the DELETE or MINUS SIGN key. To remove a group, click its logical operator and select the Remove Group from the appeared menu. You can copy, cut, and paste conditions and groups with CTRL+C, CTRL+X, and CTRL+V keys.

3. Click OK to apply the filter condition to the data in the grid.

ExpandedToggleIcon(9x12) Creating a New Filter Condition

1. Create a new group:
· Click the upper-level group operator and select Add Group from the menu.
· Press CTRL+PLUS SIGN.
2. Create a new filter condition by doing one of the following:
· Click the upper-level group operator and select Add Condition from the menu.
· Navigate to a group you want to enhance, and press INSERT or PLUS SIGN key.
· Click FilterGreyAdd of the group you want to enhance.
3. Click the condition column, and then and select the column you need from the menu.
4. Click the condition criteria operator and select the criteria operator you want to apply.
5. If the condition operator requires operand values, specify them.

ExpandedToggleIcon(9x12) See Also

Viewing Data in Grid

Server-Side and Client-Side Sorting and Filtering


Server-Side and Client-Side Sorting and Filtering

In Data Compare for SQL Server, sorting and filtering of data can be performed on the client or on the server side.

If there are not many records in a table, they are all shown in the result grid after retrieving data from a table or after executing a SELECT statement. If you want to sort these records or use a filter, the filtering and sorting procedures are performed on the client side and all available records are processed.

But if there are many records in a table, they are not displayed after executing a SELECT statement or retrieving data at once, because such action can cause hanging of the client machine or some other problems associated with too much data to operate.

The other case when not all records are displayed in the grid, is when Paginal Mode is on and there are more records then the number of records displayed on one page. In these cases, if you perform client-side sorting or filtering, only records available on the client machine are processed. That means you will not get a complete result of filtering or sorting. That's why Data Compare for SQL Server performs server-side filtering or sorting when not all records can be displayed in the grid.

When server-side filtering or sorting is performed, the application sends a query that is a modification of the starting query to the server. The shortcoming of this way is that server resources are taken, but the benefit is that a user will get a complete result of sorting or filtering.

But once all records are received, for example, after pressing CTRL+END or scrolling to the end, server-side filtering and sorting is turned off and client-side filtering and sorting is used.

Problems that may occur during server-side sorting and filtering:

In some cases the application can not modify the starting query to send it to the server and perform server-side sorting or filtering. These cases are the following:

· There is an expression without alias in a SELECT clause. Actually this is a restriction of MS SQL Server - one cannot modify a query that contains a statement without an alias in a SELECT clause. And if there is no alias for a column, one cannot sort or filter data in other columns as well, until all data is fetched or an alias is given.
· There is a query with an ORDER BY clause. In this case no server-side filtering can be performed, and it is a SQL Server restriction.

ExpandedToggleIcon(9x12) See Also

Viewing Data in Grid

Paginal Mode


Paginal Mode

Paginal Mode splits data into pages and is used for displaying data with large number of records.

To enable Paginal Mode, click Paginal Mode.

To configure the number of record per a page, type or select the value from the Page Row Count drop-down list box.

To navigate through pages, use the corresponding buttons on the document toolbar.

Paginal mode toolbar buttons

By default, Paginal Mode is enabled for data views with 1000 records on a page, so only 1000 records are displayed at once. You may change default settings on the Data Editor, General tab of the Options window.

note Note

Paginal Mode can also be enabled by clicking the corresponding button on a message received when retrieving data from a table that has large number of records.

note Note

If not all records are displayed on one page when Paginal mode is on, the warning icon Caution is shown on the status bar. If you move the mouse pointer onto the icon, a notification informing that the data is split into pages will be shown.

ExpandedToggleIcon(9x12) See Also

Viewing Data in Grid

Auto-search Mode


Auto-Search Mode

Auto-search mode allows you to search column data.

To enable or disable the Auto-Search mode, do any of the following:

· Press CTRL+I keys.
· On the Data menu, click Auto-search mode.
· Click Auto-search mode on the Data Editor toolbar.

To search for the data, select a cell in a column, and type first letters of the required data. If you made a mistake when typing, press BACKSPACE and type the string again.

To navigate to the next entry, press CTRL+DOWN keys. To return to the previous entry, press CTRL+UP. The entries will be highlighted.

ExpandedToggleIcon(9x12) See Also

Viewing Data in Grid

Card View


Card View

Data Editor allows you to view, edit, and print data in the Card View mode. In the Card View mode, each data row is represented as a card with caption 'Record N' and number.

To enable the Card View mode, click the Switch to Card View button on the Data Editor toolbar. To return the grid view mode, click the Switch to the Grid View button on the Data Editor toolbar.

You can view or edit data in the same way as in the grid mode. Data cards can be expanded and collapsed with help of corresponding button on a caption.

To sort or filter data in the card mode, click the Customize button, and then click either Sort, or Filter next to a column.

To customize the column display in cards, click the Customize button and select or clear check boxes next to the required columns.

Card View

ExpandedToggleIcon(9x12) See Also

Viewing Data in Grid

Editing Data in Grid


Editing Data in Grid

This section describes how to effortlessly edit data in dbForge Data Compare for SQL Server.

ExpandedToggleIcon(9x12) In This Section

Editing Data in Grid Overview
The topic describes how to quickly edit data using various grid editor's features.

Using Transactions
This topic explains how to use transactions in Data Compare for SQL Server for data editing. This functionality is not available in Devart Schema and Data Compare tools.

Cached Updates
This topic explains how to use cached updates mode.

ExpandedToggleIcon(9x12) See Also

Working with Data in Data Editor


Editing Data in Grid Overview

When dbForge Data Compare for SQL Server executes any statement returning a result set, the retrieved data is displayed in the Data Editor of the data view of the same SQL document. This topic shows how to edit the data in grid; for information about customizing data grid, as well as sorting, grouping and filtering, visit Viewing Data in Grid topic.

ExpandedToggleIcon(9x12) To insert, delete, copy and paste data:

Use the shortcut menu or the corresponding buttons under the grid. For example, you can do the following:

· To insert NULL (instead of empty string), select Set Value To ->Null from the shortcut menu. You can also use the CTRL+0 key combination.
Tip: Use Set Value To menu to quickly set an empty string, zero, or a current date.

· To add a new record, select the Append option from the shortcut menu or click the Append Append button under the grid. To delete a record from the grid, select the Delete option from the shortcut menu or click the '-' button under the grid or press CTRL+DEL keys.
· To copy and paste cell values, use the corresponding options from the shortcut menu.

ExpandedToggleIcon(9x12) To select data:

You can easily select and copy the data just like cells in a spreadsheet. Do either of these actions:

· Move the mouse pointer across the grid holding the left mouse button
· Click the first cell of the data range, press SHIFT, and, holding the SHIFT key, click the last cell. A rectangular range of cells will be selected.

Tip: Using the CTRL key, you may include and exclude cells to selection. Any number of rows may be copied and pasted to some other application, for example, a spreadsheet, but when you paste data in data grid, only the first row will be pasted.

note Note

Actual document look may slightly vary from the above image depending on the product you use.

note Note

Some queries return read only data, for example, queries with aggregate functions (count, avg etc.), or data, retrieved from non-updatable views. Such data can't be edited. It is also impossible to edit the result of executing of the script with several select statements.

ExpandedToggleIcon(9x12) Row and cell indicators

When working with grid, you can see special indicators near to the focused cell. These indicators reflect current editing state.

The row is focused.

The row has been edited.

Incorrect value was entered into a cell. You must either fix the value or press the ESCAPE key to cancel changes made to the cell.

ExpandedToggleIcon(9x12) See Also

Editing Data in Grid

Using Transactions


Using Transactions

Data Compare for SQL Server allows to control data editing with transactions. You can access the following buttons on the Connection toolbar: Begin Transaction, Commit, and Rollback.

Click on Begin Transaction button on the Connection toolbar or select Begin Transaction from the shortcut menu of the connection to start a new transaction. Since now all changes you make to a database object are not applied until you click Commit button on the Connection toolbar or select Commit from the shortcut menu of the connection. To revert all changes and return to the point where you have been at the moment of clicking Begin Transaction button, click on the Rollback button on the Connection toolbar or select Rollback from the the shortcut menu of the connection.

Commit is automatically issued when you save documents that represent database objects.

The transaction applies to the whole connection. Notice that the Output window reports all transaction events.

note Note

If you are using Devart Schema Compare or Data Compare tools, this functionality is not available.

ExpandedToggleIcon(9x12) See Also

Editing Data in Grid

Cached Updates


Cached Updates

Cached updates mode allows you to control data editing within single database object. For the object you have turned this mode on, updates are stored locally on the client side until you click the Apply Changes button. If you do not need the changes to be applied, click the Cancel Changes button. When you close the document in the cached updates mode, you cancel all changes made since the last Apply command.

ExpandedToggleIcon(9x12) See Also

Editing Data in Grid

Working with Data in Data Editor


Data Shortcut Keys

Use following shortcut key combinations when working with data in the Data Editor or data view of an SQL document.

Icon | Command Name | Shortcut Keys | Action | Where is used
AutoSearch | Auto-search mode | CTRL+I | Data auto-search mode | Data Editor
RefreshButton | Refresh | F5 | Refresh Data view | Data Editor
RefreshButton | Refresh | CTRL+R | Refresh Data view | Data Editor
 |  | CTRL+HOME | Focus on first record in data grid | Data Editor
 |  | CTRL+END | Focus on last record in data grid | Data Editor
 |  | CTRL+DELETE | Delete currently selected row in data grid | Data Editor
 |  | INSERT | Insert new record in data grid | Data Editor
 |  | CTRL+0 | Insert NULL value in current cell | Data Editor

These shortcuts are default shortcuts. All shortcuts can be customized.

ExpandedToggleIcon(9x12) See Also

Working with Data in Data Editor


User Interface Concepts

expandedtoggleicon(9x12) In This Section

Using Documentation
The topic explains how to use the current manual.

User Interface Elements
This topic provides you with basic information about managing your environment workspace.

Working with Text Editor
This topic explains how to work with the Text Editor.

Customizing Window Layout
This section provides information about window layouts and their customization.

Manipulating Documents
The topic describes how to manipulate documents in Data Compare for SQL Server.

Customizing Environment
This topic contains information on customizing environment to simplify your work and save time.

Find and Replace Text and Code
This section describes how to use Find and Replace utility.


Using Documentation

The application documentation is available from the official Devart website in the following formats:

· Online
· Offline CHM file (you can download it on the Download section of the product)

There are several ways to navigate through documentation:

· F1 Search
· Search
· Contents

expandedtoggleicon(9x12) F1 Search

F1 provides context help for the active window, dialog box. It always returns no more than one page.

expandedtoggleicon(9x12) Search

Use Search to return all documents that match any specified term or a set of terms.

expandedtoggleicon(9x12) Contents

The table of contents shows all documentation topics in a hierarchical tree view structure and provides a convenient way to browse help. If you opened topic from index or search or from the link and you want to know where this topic is located, use the Locate button or switch to the Contents tab.

expandedtoggleicon(9x12) See Also

Customizing Environments

User Interface Elements


User Interface Elements

This topic provides you basic information about managing your environment workspace. Environment workspace consists of toolbars, tool windows, menus and document area. To personalize menus and toolbars and to adjust their behavior to your needs, point to Toolbars in the View menu, and click Customize.

expandedtoggleicon(9x12) Toolbars

A toolbar is a container for a group of commands or controls that are typically related in their function.

Data Compare for SQL Server supports dockable toolbars. A dockable toolbar can be attached, or docked, to any side of its parent window, or it can be detached, or floated, in its own mini-frame window. This article explains how to use dockable toolbars in your applications.

Note Note

If you drag a toolbar to the right or left side of the window, toolbar drop-down lists or combo boxes will not be available. For example, if you drag the Connection toolbar to the right or left side of the window, the Connection box will not be available.

expandedtoggleicon(9x12) Menus

The environment has a set of toolbars where reside buttons, using which you can accomplish most frequent tasks. The toolbar you can access depends on kind of document currently active. If it is not visible, right-click on toolbars area and choose one from the shortcut menu.

You can control which toolbars are allowed to appear, and which must be always visible. By default, when you switch between views or documents, corresponding toolbars appear and disappear. When a toolbar is visible, right-click on toolbar area and deselect its item in the shortcut menu to prevent it from showing even if corresponding view is active. If you want to make a toolbar always visible, select it in the shortcut menu, when corresponding document or view is not active. To return a toolbar to its default state select it in the shortcut menu when corresponding document or view is active. You can edit any toolbar, delete, or add your own in Customization dialog box. To open it choose Customize from a toolbar shortcut menu.

expandedtoggleicon(9x12) Document Area

Document area typically displays SQL code or diagrams. Document area size can be manipulated by resizing docked tool windows. To free more space for documents, you can put docked tool windows to auto-hide mode by clicking the pushpin icon on the title bar of the window.

You can arrange documents in tab groups in document area. To create a tab group or move document to another tab group just drag a document to a drop point. Dragging a document to an arrow drop point will create new tab group; dragging it to the tab group central drop point will move the document to this tab group.

Multiple documents can be organized into horizontal or vertical tab groups for organizing a workspace for working with several documents at the same time. New document tab group can be created either by dragging document to the required place or by selecting New Horizontal Tab Group or New Vertical Tab Group from the document header shortcut menu.

Documents can be moved between tab groups by dragging-n-dropping or by selecting required command from the shortcut menu. You can expand a tab group to the whole document area and restore document tab groups' sizes by selecting Prominent from the document header shortcut menu.

expandedtoggleicon(9x12) Switching Between Windows

This section contains information about how to switch between documents and tool windows.

To cycle through open documents, use CTRL+TAB or CTRL+SHIFT+TAB key combinations. Press CTRL+TAB to switch to previously used document. Pressing CTRL+TAB again will return you to current document. Hit TAB key while holding CTRL key to cycle through recent documents stack. You can also use CTRL+SHIFT+TAB combination to browse documents in another direction.

To navigate from the current document tab to the next tab, use CTRL+ALT+PGDOWN key combination. To navigate from the current document tab to the previous tab, use CTRL+ALT+PGUP key combination.

You can also switch between documents in the following ways.

· By clicking document titles.
· By clicking the down arrow near the right upper corner of the document area and selecting document name from the appeared menu.
· By selecting document from the Window menu.
· By selecting document in the Windows dialog and clicking the Activate button.

To activate a tool window, use its shortcut key.

expandedtoggleicon(9x12) Switching to another skin

dbForge Data Compare for SQL Server provides you several types of a skin. To switch to another skin, on the Tools menu, choose Skin, and then click the skin name you like.

The following skins are available in dbForge Data Compare for SQL Server:

· Visual Studio 2013 Blue
· Visual Studio 2013 Light
· Visual Studio 2013 Dark
· Visual Studio 2010
· Metropolis
· Metropolis Dark
· Office 2010 Silver
· Office 2010 Blue
· Office 2010 Black
· Office 2013
· Office 2013 Dark Gray
· Office 2013 Light Gray
· Windows 7

expandedtoggleicon(9x12) See Also

Using Documentation

Working with Text Editor


Manipulating Documents

The topic describes how to manipulate documents in Data Compare for SQL Server.

expandedtoggleicon(9x12) Managing Documents

The Windows Dialog Box allows you to switch between documents and manage them. To open it, select Windows from the Window menu. This dialog allows you to save and close multiple documents at once, and activate required document.

To save document(s) select required document(s) and click the Save button.

To close document(s) select required document(s) and click the Close Window(s) button.

note Note

To close an opened document, click the document title with middle mouse button (mouse wheel).

To activate required document, select the document and click the Activate button.

expandedtoggleicon(9x12) Navigating through the Document Views

Each SQL document includes different representations of the content - document views.

To switch to a specific view, click a button with the view name on the bottom pane of the document. Alternatively, select the required view from the shortcut menu of the document bottom pane.

You can also cycle through available views with the F7 key.

expandedtoggleicon(9x12) Working with Document Tab Groups

Multiple documents can be organized into horizontal or vertical tab groups for organizing a workspace for working with several documents at the same time. New document tab group can be created either by dragging document to the required place or by selecting New Horizontal Tab Group or New Vertical Tab Group from the document header shortcut menu.

Documents can be moved between tab groups by dragging-n-dropping or by selecting required command from the shortcut menu.

expandedtoggleicon(9x12) Restoring Tabs

Document tabs can be saved to cash and eventually be restored after the application crush or accidental closing. To customize the tab restore options, on the Tools menu, select Options. In the Options dialog box, expand Environment, then expand Documents and select Restore. Set the time after which the data will be saved automatically and select restartable file types.

Document tabs will be restored automatically at the run of the application.

expandedtoggleicon(9x12) Document Header Shortcut Menu

The document header shortcut menu includes the following options:

Save <Name>.sql
Saves a current SQL document.

Close
Closes a current document.

Close All But This
Closes all documents excepting the selected one.

Copy Full Path
Copies the full path for the document.

Open Containing Folder
Opens the folder containing the document.

Float
Detaches the window.

New Horizontal Tab Group
Creates new horizontal tab group.

New Vertical Tab Group
Creates new vertical tab group.

expandedtoggleicon(9x12) See Also

Customizing Window Layout

Customizing Environment


Working with Text Editor

The text editor is the word processor of the Data Compare for SQL Server. When the text editor is used to edit text, it is referred to as the text editor. When it is used to edit SQL source code, which is its more common use, it is referred to as the code editor. You can open multiple code editors to view or/and edit code. A list of all documents open for editing in instances of the code editor is available on the Windows menu.

To open the Text editor:

1. On the File menu, click New, and then click File. (Alternatively, on the Standard toolbar, click the New File button.)

2. The New File dialog box opens.

3. Select either the Text file or the XML file form the General Files section.

The only difference between XML and text editors is that XML editor provides syntax highlighting for XML code. You can customize XML highlighting and coloring in Fonts and Colors, Text Editor, Options Dialog Box.

expandedtoggleicon(9x12) User Interface

Code pane
The area where code or text is displayed for editing. It provides SQL statement completion.

Indicator margin
A gray column on the left side of the code editor where indicators for breakpoints and bookmarks are displayed. Clicking this area sets a breakpoint on the adjacent line of code.

Selection margin
A column between the indicator margin and the editing window where you can click to select lines of code.

Horizontal and vertical scroll bars
Lets you scroll the code pane horizontally and vertically so that you can view the code that extends beyond the viewable edges of the pane.
expandedtoggleicon(9x12) Text Editor Toolbar

The Text Editor toolbar contains tools related to the code completion features, commenting and uncommenting of code, bookmarks, etc.

Display an Object Member List
Displays a list of valid databases, tables, columns, and other database objects. When a member from the list is selected, you can insert that member into your code by pressing TAB, or by typing a space or period.

Display Parameter Info
This feature opens the Parameters list to give you information about the number, names, and types of parameters required by a function or attribute. The Parameters list also displays parameter information for nested functions. If you type a function as a parameter to another function, the Parameters list displays the parameters for the inner function. Then, when the inner function Parameters list is complete, the Parameters list reverts to displaying the outer function parameters.

To view Parameter Info for functions:

1. After the name of a function, type an open parenthesis as you normally would to open the Parameters list.
2. Data Compare for SQL Server displays the complete declaration for the function in a pop-up window just under the insertion point. The first parameter in the list appears in bold.
3. As you type the function parameters, the bold changes to reflect the next parameter that you need to enter.
4. Press ESC at any time to close the list, or continue typing until you have completed the function.
5. Typing the closing parenthesis also closes the Parameters list.

Display Quick Info
This option displays the complete declaration for any identifier in your code.

You can manually invoke Quick Info feature as follows:

1. On the Edit menu, click Code Completion, and then click Quick Info.
2. Use the keyboard shortcut CTRL+K, CTRL+I.
3. Select the Quick Info toolbar button from the Text Editor toolbar.

Display Word Completion
Complete word types the rest of a variable, command, or function name once you have entered enough characters to disambiguate the term. Type the first few letters of the name, and then press ALT+RIGHT ARROW or CTRL+SPACEBAR.

Refresh Local Cache
If you are writing a query on a database while someone else is making changes to the structure of that database, the suggestions offered by Data Compare for SQL Server may become out of date. For instance, if someone has added several tables to a database while you have been connected to that database, these tables will not appear in the suggestions box. To reload the database objects, click Refresh Suggestions. Refreshing suggestions applies only to the database to which you are currently connected.

Reset Suggestions Cache
If you connect to a number of different databases during the same session, Data Compare for SQL Server will load all the objects for each database as required, without unloading any of the previously stored objects. This means that you can go back to previous queries and continue to see suggestions for any database to which you have previously connected.
Data Compare for SQL Server loads database objects into its memory whenever you connect to a database, in order to display suggestions from that database. If you connect to several databases with a large number of objects, this may eventually result in running out of memory. To reset the memory at any time, click Reset Suggestion Cache.

Decrease Line Indent
Removes a tab (or the equivalent spaces) from the selected lines or the current line.

Increase Line Indent
Adds a tab (or the equivalent spaces) to the selected lines or the current line.

Comment out the selected lines
Adds comment characters to the selection or the current line.

Uncomment the selected lines
Removes comment characters from the selection or the current line.

Toggle a bookmark on the current line
Adds or removes a bookmark on the selected line of the document in the active Editor. Does not alter the line of code bookmarked.

Move the caret to the previous bookmark
Selects the previous bookmark. When the first bookmark is reached, jumps ahead to the last one.

Move the caret to the next bookmark
Selects the next bookmark. When the last bookmark is reached, jumps back to the first one.

Clear all bookmarks in current document
Removes all the bookmarks in the current document.

Format Document
Automatically formats SQL code in the currently opened document.

expandedtoggleicon(9x12) Selecting text and code

You can quickly select a single word, line of text, or multiple paragraphs while you work with code in the editor. Keyboard shortcuts also let you select text starting from the cursor to any other point in your document.

To select text:

· To select any amount of text, just drag the mouse over the text.
· To select a word, either double-click a word or put your cursor next to word and press CTRL+SHIFT+ either RIGHT ARROW or LEFT ARROW.
· To select a line of text, drag the mouse over a line.
· To select text from the cursor to the start or end of the line, press SHIFT+ either HOME or END.

expandedtoggleicon(9x12) Editing text and code

The Editor allows you to manipulate text in the same ways as most word processing applications or text editors. For example, you can:

· Copy and Paste text or code inside the editor and between several Editors or between the Editor and other text editing applications.
· Put the Code Editor into the overstrike mode using the INSERT key
· Use the DELETE and BACKSPACE keys to remove text or code

expandedtoggleicon(9x12) Navigating text and code

There are various ways to move through text or code in the Code Editor using the mouse and navigation keys:

· Use the arrow keys to move one character at a time, or the arrow keys in combination with the CTRL key to move one word at a time. Arrow keys move one line at a time also.
· Click a location with the mouse.
· Use the scroll bars or scroll wheel on the mouse to move through the code.
· Use the HOME, END, PAGEUP, and PAGEDOWN keys.
· Use CTRL+PAGE UP and CTRL+PAGE DOWN to move the insertion point to the top or bottom of the window, respectively.
· Use CTRL+UP ARROW and CTRL+DOWN ARROW to scroll the view without moving the insertion point.

Go to Line command

Use the Go to Line command to a specific line number:

1. In the General, Text Editor, Options Dialog Box, select the Line Numbers option.
2. With a document open in the Editor, select Go to Line from the Edit menu.
3. Enter the line number you want to move to.

expandedtoggleicon(9x12) Change Text Case in the Editor

You can use menu commands or keyboard shortcuts to convert the case of selected text to all upper case or to all lower case.

To switch text to upper case:

1. Select the text you want to convert.
2. On the Edit menu, select Advanced.
3. To convert text to all upper case, choose Make Uppercase, or press CTRL+SHIFT+U.

To convert text to all lower case, choose Make Lowercase, or press CTRL+U.

expandedtoggleicon(9x12) Setting Bookmarks

As the name suggests, bookmarking accelerate your code navigation in the text editor.

There may be some piece of code where you need to move to very frequently. Generally, you scroll the page and move to that section, but Data Compare for SQL Server provides great features by which you can move to a particular section very quickly using some shortcut keys. This is called Bookmarking of Code.

You can place a bookmark by clicking on the bookmark icon or use CTRL + B, CTRL + T.

To create or remove a bookmark using the Text Editor toolbar:

1. Open a file in the Editor.
2. Place the insertion point on the line you want to bookmark.
3. Click the Toggle a bookmark on the current line button on the Text toolbar.

To move to a bookmarked line:

1. Scroll to the bookmarked line.
2. On the Text toolbar, the Move the caret to the previous bookmark and Move the caret to the next bookmark buttons are enabled.
3. Click these buttons to navigate to bookmarks in files within the current solution or project.

expandedtoggleicon(9x12) View White Space and Word Wrap

You can turn View White Space and Word Wrap modes on or off by selecting corresponding commands from the Advanced submenu of the Edit menu.

View White Space mode displays spaces and tab characters.

Word Wrap automatically displays any portion of a line that extends horizontally beyond the viewable editor area on the next line.

expandedtoggleicon(9x12) Text Indenting

The Editor provides text indenting functionality. You can set the indent at some line, thus when you press ENTER, this indent is set at the next line. To change line indenting use Increase Line Indent and Decrease Line Indent options.

To increase or decrease indenting perform the following actions:

1. Select the text you want to indent.
2. On the Edit menu, select Advanced.
3. Select Increase Line Indent or Decrease Line Indent to manage the indentation.

collapsedtoggleicon(9x12) Code Outlining

SQL Editor allows you to hide parts of code. Outlining marks are shown left of the code editor window. Code blocks which belong to the same structural item can be collapsed by using the minus (-) symbol. Outlined code is not deleted, it is merely hidden from view.

You can then expand the outlined statement or user-defined region by clicking the plus sign (+) next to the symbol.

Outlining SQL Statements

The statement is outlined in the following cases:

· it spans over two or more lines
· it is a create statement

Nested SQL statement (for example, SELECT in CREATE VIEW) is outlined only if it starts from the new line.

Statement is not outlined if it is very short and takes only one line of code. Stored code condition and cycle operators are not outlined; the same is about nested BEGIN ... END blocks.

User-defined Outlining Regions

You can outline code block using Regions.

To create the region, type #region command at the start line of the region. No symbols except spaces are allowed at the same line before #region command. Region may have the name, so simply specify it after space at the same line. Each region statement has to be closed by the #endregion command. Type #endregion at the beginning of the line determining the region end.

You can create named regions using the #region <region name> and #endregion <region name> commands.

SQL code block, grouped by the specified region can be collapsed/expanded by user. You can create nested regions to operate several SQL code blocks.

expandedtoggleicon(9x12) See Also

User Interface Elements

Find and Replace Text and Code


Customizing Window Layout

This section provides information about window layouts and their customization.

expandedtoggleicon(9x12) Closing and Displaying Tool Windows

When a tool window is closed, it becomes invisible but preserves its content, that will be available when the window is opened again. Most tool windows are listed in the View menu and can be opened by selecting corresponding View menu command. Other tool windows are listed in Database menu. You can also use shortcut keys to display certain tool windows.

All layout changes are saved when you close the application and restored when you open it again.

expandedtoggleicon(9x12) Auto-hide Mode

Tool window auto-hide mode allows you to minimize tool windows along the edges of the application window, freeing more space for the document area.

To turn on auto-hide mode, perform one of the following.

· Activate the window and select Auto Hide from the Window menu
· Right-click the window title and select Auto Hide from the shortcut menu
· Click on the pushpin icon on the title bar of the window

When tool window is in auto-hide mode, it shows when you point on it and hides when you click somewhere out of the window. You can turn auto-hide mode on for all docked tool windows to free all the workspace for document area. To do it, select AutoHide All from the Window menu.

expandedtoggleicon(9x12) Layout Saving and Restoring

All layout changes are saved when you close the application and restored when you open it again. To restore layout to its default state select Reset Window Layout from the Windows menu.

expandedtoggleicon(9x12) See Also

User Interface Concepts

Manipulating Documents


Customizing Environment

The environment provides many useful shortcut key combinations to speed up your work. Default shortcut settings are similar to shortcuts in Visual Studio. Default keyboard mapping schema can be changed to the one similar to Visual C++ 6.0 or to Delphi. There are some more keyboard mapping schemas. Moreover, you can assign your own shortcut keys to every action.

Shortcuts can be changed on the Keyboard, Environment, Options dialog box.

To access this dialog box:

1. In the Tools menu, click Options. The dialog box appears.
2. Expand the Environment section, and click Keyboard.

expandedtoggleicon(9x12) Choosing a keyboard mapping schema

You can select a keyboard mapping schema from the Apply the following additional keyboard mapping scheme drop-down list on the Keyboard page of the Environment section in the Options dialog box.

expandedtoggleicon(9x12) Determining and removing the shortcut key combination for a command

To determine or remove the shortcut key combination for a command perform the following actions.

1. On the Keyboard, Environment, Options dialog box, enter the command name without spaces or a part of it in the Show commands containing box.
2. In the list, select the correct command.
3. Shortcuts for selected command drop-down list now contains the assigned key combination for the command if any combinations exist. You can view them in the list.
4. If you want to remove the combination, select a command in the list, and click the Remove button.

expandedtoggleicon(9x12) Assigning custom shortcut key combination for a command

To assign a shortcut key combination for a command:

1. On the Keyboard, Environment, Options dialog box, enter the command name without spaces or a part of it, in the Show commands containing text box.
2. In the list, select the correct command.
3. On the Use new shortcut in drop-down list, select the feature area where you want to use the shortcut.
4. Place the cursor in the Press shortcut keys box, and press the key combination to set for the selected command. The combination will be displayed in the box.
5. Click Assign.

expandedtoggleicon(9x12) See Also

Customizing Environment

© 2004-2017 Devart


How To: Customize User Shortcuts

The environment provides many useful shortcut key combinations to speed up your work. Default shortcut settings are similar to shortcuts in Visual Studio. Default keyboard mapping schema can be changed to the one similar to Visual C++ 6.0 or to Delphi. There are some more keyboard mapping schemas. Moreover, you can assign your own shortcut keys to every action.

Shortcuts can be changed on the Keyboard, Environment, Options dialog box.

To access this dialog box:

1. In the Tools menu, click Options. The dialog box appears.
2. Expand the Environment section, and click Keyboard.

expandedtoggleicon(9x12) Choosing a keyboard mapping schema

You can select a keyboard mapping schema from the Apply the following additional keyboard mapping scheme drop-down list on the Keyboard page of the Environment section in the Options dialog box.

expandedtoggleicon(9x12) Determining and removing the shortcut key combination for a command

To determine or remove the shortcut key combination for a command perform the following actions.

1. On the Keyboard, Environment, Options dialog box, enter the command name without spaces or a part of it in the Show commands containing box.
2. In the list, select the correct command.
3. Shortcuts for selected command drop-down list now contains the assigned key combination for the command if any combinations exist. You can view them in the list.
4. If you want to remove the combination, select a command in the list, and click the Remove button.

expandedtoggleicon(9x12) Assigning custom shortcut key combination for a command

To assign a shortcut key combination for a command:

1. On the Keyboard, Environment, Options dialog box, enter the command name without spaces or a part of it, in the Show commands containing text box.
2. In the list, select the correct command.
3. On the Use new shortcut in drop-down list, select the feature area where you want to use the shortcut.
4. Place the cursor in the Press shortcut keys box, and press the key combination to set for the selected command. The combination will be displayed in the box.
5. Click Assign.

expandedtoggleicon(9x12) See Also

User Interface Concepts


Find and Replace Text and Code

This section describes how to use Find and Replace utility.

expandedtoggleicon(9x12) In This Section

Finding and Replacing Text
The topic explains how to finding and replacing text in a file.

Searching and Replacing Text in Files
The topic describes searching and replacing text in files techniques.

Using Incremental Search
The topic explains how to use incremental search to find required text in a file.

Regular Expressions for Find and Replace
The topic explains how to use regular expressions while searching.

Wildcards for Find and Replace
The topic explains how to use wildcards while searching.


Finding and Replacing Text

You can find and replace text using Find and Replace window. To open this window press CTRL+F or CTRL+H. These techniques allow you to control the scope of find and replace and choose the method of reviewing search matches and replacements.

You should consider the following information when you search and replace text:

· Options set in the Find and Replace window are global; certain options selected in one dialog box are selected for all the dialogs. These options are Match case, Match whole word, Search all open documents, Search hidden text, Search up, Wildcards, and Regular Expressions.
· Undo is available only for documents left open after a replace operation.
· Undo for a Replace All operation rolls back all replacement changes in the current document.

You can search one or more open files or windows and move through the search matches one by one using the Find and Replace window. This technique allows you to review each individual search match in the context of the text around the match.

To search current document, current project, or all open documents:

1. Open the items you wish to search.
2. Press CTRL+F and switch to Find mode if necessary.
3. In the Look in box, select 'Current Document', 'Current Project' or 'All Open Documents'.
4. In the Find what text box, enter the text you intend to search for.
5. Select additional search options to increase the accuracy of the search.
6. Click Find Next to start the search and continue choosing Find Next until the last file has been searched.

note Note

You may search in the Output or Data Viewer and Editor windows in the same way. Just select Current Window on the step 3. In the Data Viewer and Editor window you may search both hex code and text. Hex code can be searched only when no wildcards or regular expressions are used.

When the search passes the beginning or end of the document, a message is displayed in the status bar. A message box appears when the search reaches the starting point of the search.

To replace in the current document or in all open documents:

1. Open the items you wish to search.
2. Press CTRL+H and switch to Replace mode if necessary.
3. In the Look in box, select 'Current Document', 'Current Project' or 'All Open Documents'.
4. In the Find what text box, enter the text you intend to search for.
5. In the Replace with text box, enter the text with which you intend to replace the search text.
6. Click Replace and continue clicking Replace until the last match in the last file has been replaced. Use Find Next to skip a match you do not want to replace.

You may click Replace All to replace all matches. A message box appears, listing the total number of replacements. The Replace All command replaces all search matches, including those you have skipped with the Find Next button. To reverse Replace All, choose Undo from the Edit menu in each changed file before closing any of the files.

expandedtoggleicon(9x12) See Also

Find and replace text and code

Searching and Replacing Text in Files


Searching and Replacing Text in Files

You can use the Find and Replace in Files window to perform search and replace operations. To open this window press CTRL+F or CTRL+H, then switch to Find in Files or Replace in Files mode.

Searching and replacing text in files has following peculiarities:

· You can enter disc folder as search location or even create and use named folder sets.
· You can only find all occurrences, you cannot use Find Next.

To create a named folder set:

1. In the Find and Replace in Files window, click the button button next to the Look In box.
2. Enter the folder set name.
3. Edit the folder list with LeftArrow and RightArrow buttons. To browse folders
4. Click the Apply button. Now you may use this folder set in the Look In box.

To delete named folder set, click the button button next to the Look In box, enter the folder set name, and click Delete button.

To search in files:

1. Press CTRL+F and switch to Find in Files mode if necessary.
2. In the Look in box, select needed location or enter folder path or name of the named folder set.
3. In the Find what text box, enter the text you intend to search for.
4. Select additional search options to increase the accuracy of the search.
5. You may specify the file mask for searching in the Look at these file types box.
6. If needed, customize the Result options.
7. Click the Find All button.

After search is finished, all results are displayed in the Find Results window. You may double-click on matches to navigate to them.

To replace in files

1. Press CTRL+H and switch to Replace in Files mode if necessary.
2. In the Look in box, select needed location or enter folder path or name of the named folder set.
3. In the Find what text box, enter the text you intend to search for.
4. Select additional search options to increase the accuracy of the search.
5. If needed, customize the Result options. Select the Keep modified files open after Replace All check box if you want to be able to undo changes.
6. You may specify the file mask for replacing in the Look at these file types box.
7. In the Replace with text box, enter the text with which you intend to replace the search text.
8. Click Replace and continue clicking Replace until the last match in the last file has been replaced. Use Find Next to skip a match you do not want to replace.

You may click Replace All to replace all matches. A message box appears, listing the total number of replacements. The Replace All command replaces all search matches, including those you have skipped with the Find Next button. To reverse Replace All, choose Undo from the Edit menu in each changed file before closing any of the files.

expandedtoggleicon(9x12) See Also

Find and replace text and code

Using Incremental Search


Using Incremental Search

You can search an individual document or window incrementally by entering a search string character by character, then observing the matches found as the search string lengthens. To activate an incremental search, choose Advanced from the Edit menu and choose Incremental Search.

An incremental search automatically searches the entire document or all text within a window, with the exception of text that has been collapsed or concealed. The editor highlights the first set of characters found in the document or window that match the search string entered.

Incremental searches are performed by default from the current location in the document downward, and from left to right. To move to the next match, press CTRL+I. To reverse the direction of the search, press CTRL+SHIFT+I.

To search incrementally:

1. Place the cursor in a blank section of the file or window you want to search.
2. From the Edit menu, choose Advanced, and then select Incremental Search.
3. The cursor icon changes to binoculars with an arrow indicating the search direction, and the status bar displays the text Incremental Search.
4. Begin typing the search string.
5. The status bar displays the search string you are entering, and the editor highlights the first match found for what you have typed so far.
6. Continue to add characters to the search string.

The editor searches again for a match of the augmented search string, and again highlights the first match found.

If no match is found, the status bar displays the following message: Incremental Search: <text> not found.

expandedtoggleicon(9x12) See Also

Find and replace text and code

Regular Expressions for Find and Replace


Regular Expressions for Find and Replace

The Find and Replace window contains a list of symbols and signs which you can use to quickly find and replace required patterns of text. They are called regular expressions.

To select a regular expression, do the following:

1. In the Find and Replace window, select the Use check box and choose Regular Expressions from the drop-down list. The [image] arrow button next to the Find what field becomes active.
2. Click the [image] arrow button and select a regular expression from the drop-down list. It is inserted into the Find what field.

The drop-down list contains the following regular expressions:

Syntax | Expression | Description
. | Any single character | Matches any single character except a line break.
* | Zero or more | Matches zero or more occurrences of the preceding expression, finding all possible matches.
+ | One or more | Matches at least one occurrence of the preceding expression.
^ | Beginning of line | Anchors the match string to the beginning of a line.
$ | End of line | Anchors the match string to the end of a line.
< | Beginning of word | Matches only when a word begins at this point in the text.
> | End of word | Matches only when a word ends at this point in the text.
\n | Line break | Matches a platform-independent line break. In a Replace expression, inserts a line break.
[] | Any one character in the set | Matches any one of the characters within the []. To specify a range of characters, list the starting and ending character separated by a dash (-), as in [a-z].
[^] | Any one character not in the set | Matches any character not in the set of characters following the ^.
| | Or | Matches either the expression before or the one after the OR symbol (|). Mostly used within a group. For example, (database|management)system matches "database system" and "management system".
\ | Escape Special Character | Matches the character that follows the backslash (\) as a literal. This allows you to find the characters used in regular expression notation, such as { and ^. For example, \^ Searches for the ^ character.
{} | Tagged Expression | Matches text tagged with the enclosed expression.
:i | SQL identifier | Matches the expression ([a-zA-Z_$][a-zA-Z0-9_$]*).
:q | Quoted string | Matches the expression (("[^"]*")|('[^']*')).
:b | Space or Tab | Matches either space or tab characters.
:z | Integer | Matches the expression ([0-9]+).

expandedtoggleicon(9x12) See Also

Find and replace text and code

Wildcards for Find and Replace


Wildcards for Find and Replace

The Find and Replace window contains a list of expressions to replace characters or digits in the Find what field. They are called Wildcards.

To select a required wildcard, do the following:

1. In the Find and Replace window, select the Use check box and choose Wildcards from the drop-down list. The [image] arrow button next to the Find what field becomes active.
2. Click the [image] arrow button and select a wildcard from the drop-down list. It is inserted into the Find what field.

The drop-down list contains the following wildcards:

Syntax | Expression | Description
? | Any single character | Matches any single character.
# | Any single digit | Matches any single digit. For example, 5# matches numbers that include 5 followed by another number, such as 51, but not 15.
[!] | Characters not in set | Matches any one character that is not specified in the set.
\ | Escape | Matches the character that follows the backslash (\) as a literal. This allows you to find the characters used in wildcard notation, such as * and #.
* | One or more characters | Matches any one or more characters. For example, test* matches any text that includes "test", such as testfile.txt.
[] | Set of characters | Matches any one of the characters specified in the set.

expandedtoggleicon(9x12) See Also

Find and Replace Text and Code

User Interface Concepts


Reference

ExpandedToggleIcon(9x12) In This Section

Data Compare
This section describes all the wizards, documents, windows and other UI elements related to data comparison and synchronization processes.

Database Connection
This section describes Data Connection user interface elements.

Data Editor
This section provides information on data managing windows and dialogs.

Execute Script Wizard
Use this wizard for executing large scripts without opening them in the editor.

Find and Replace Window
This section describes how to use the Find and Replace window to search for text, expressions, or entity names within the code of your documents.

Options
The topics in this section describe dialog boxes and wizards that are used in dbForge Data Compare for SQL Server to perform commands and configure pages and controls.

Service Windows
This section describes user interface elements of service windows and dialogs.

Shortcut Keys
This topic describes customizable shortcut keys used in dbForge Data Compare for SQL Server.

SQL Document
This section describes SQL Document user interface elements.


Data Compare

This section describes user interface elements of the windows concerned with data comparison.

ExpandedToggleIcon(9x12) In This Section

Data Comparison Wizard
Describes Data Comparison wizard's fields and options.

Data Synchronization Wizard
The topic describes the Progress window that appears during comparison/synchronization.

Comparison and Synchronization Progress Info
This topic describes progress window for comparison and synchronization process.

Comparison Report
This section describes the Comparison Report wizard.

Data Comparison Document
Describes the details of the Data Comparison document.

ExpandedToggleIcon(9x12) See Also

Reference


Data Comparison Wizard

ExpandedToggleIcon(9x12) Data Comparison Wizard Description

The Data Comparison wizard provides a single access to perform the basic configuration steps to compare data stored in databases.

To access the Data Comparison Wizard, click New Data Comparison on the start page. Alternatively, on the File menu click NewDataComparisonButton.

ExpandedToggleIcon(9x12) The Main Tabs and Dialog Boxes of the Data Comparison Wizard

Source and Target, Data Comparison Wizard
Choose Source and Target connections, Databases, and select comparison options here.

Options, Data Comparison Wizard
Set data comparison options and records to view in comparison results on this page.

Edit Mask Dialog Box
Use this dialog box to specify a custom wildcard expression for tables (or views) to include them into comparison.

Objects Mapping Dialog Box
Use this dialog box to set custom mapping for tables and views.

Mapping, Data Comparison Wizard
Select objects and their columns to compare and set comparison keys for them.

Column Mapping Dialog Box
Use this dialog box to map columns and specify the comparison key.

Custom Queries Mapping Dialog Box
Use this dialog box to set custom query mapping for tables and views.

WHERE Filter Dialog Box
Use this dialog box to filter rows included into comparison.

Schemas Mapping Dialog Box
Use this dialog to set custom mapping for schemas.


Source and Target, Data Comparison Wizard

The tab consists of two sections. The first section, Source, is used to set the connection properties for the source database or to choose a backup file for comparison. The second section, Target, is used to set the connection properties for the target database respectively or to choose a backup file for comparison.

ExpandedToggleIcon(9x12) Database Comparison

Type
Select a database or a backup file you want to compare data with.

Connection
Select a connection here. Choose the <Manage...> option to call the Connection Manager window.

Edit...
Click to edit properties of the selected connection.

New...
Click to create a new connection.

Server Version
The version of the database server used in the connection is specified.

Database
Specify a database to compare.

ExpandedToggleIcon(9x12) Backup Comparison

Type
Select a database or a backup file you want to compare data with.

Add...
Click to add a backup file to compare.

Remove
Click to remove the selected backup file.

Clear
Click to remove all backup files from the grid.

Server Version
The version of the database server used in the connection is specified.

Database
A database which the backup was made from.

Date
A backup file creation date.

Server
The server version of a database which the backup was made from.

Type
The backup type.

File Name
A backup file name and its path.

ExpandedToggleIcon(9x12) See Also

Data Comparison Wizard

Options, Data Comparison Wizard


Options, Data Comparison Wizard

This tab allows you to set data comparison options and records to view in comparison results.

ExpandedToggleIcon(9x12) Options Wizard Page Content

Auto Mapping Options

A set of options that are used to adjust objects mapping.

Ignore case in object names
Select it to ignore case in object names (tables, views, schemas and columns) when mapping them. For example, sales.Customer will be mapped to sales.CuStomEr when this option is set.

Ignore underscores in object names
Select it to ignore underscores in object names (tables, views, schemas and columns) when mapping them. For example, sales.CustomerBalance will be mapped to sales.Customer_Balance when this option is set.

Ignore spaces in object names
Select it to ignore spaces in object names (tables, views, schemas and columns) when mapping them. For example, sales.CustomerBalance will be mapped to sales,[CustomerBalance] when this option is set.

Include tables or views by mask: *
Allows specifying a custom wildcard expression for tables or views to include them to comparison. For example, tables or views with such names as dept.Jobs, dept.Tmp_Jobs, Tmp_Job_History, sales.Departments, dept.Tmp_Departments, dept.Tmp_Departments2, will be included to mapping if "*jobs*, *Department*" is set for this option.
To add/edit a wildcard expression, click the OptionButton button next to the option and enter a required expression.

Exclude tables or views by mask. *Table*
Allows specifying a custom wildcard expression for tables or views to exclude them from comparison. For example, tables or views with such names as hr.employees, hr.employees, hr.TMP_EMPLPOYEES, sales.TMP_Employees_OLD, sales.REGIONS, Customer.TMP_regions, sales.tmp_RegionS_new will be excluded from mapping if "*employees*, *Regions*" is set for this option.
To add/edit a wildcard expression, click the OptionButton button next to the option and enter a required expression.

Ignore BLOB columns
Allows ignoring blob columns during comparison. The option can be applied to the following column types: IMAGE, (N)TEXT, (N)VARCHAR(max), VARBINAR(max), XML.

Ignore columns by mask: *ModifiedDate*, *CreatedOn*, *UpdatedBy*
Allows you to specify a custom wildcard expression for columns names to exclude columns from comparison. For example, columns with such names as UpdateByCustomer, NotUpdateByUser, RecordsCreatedOn, RecordCreatedOnDay, LastModifiedDate, and ProductModifiedDateTime will be excluded from mapping if *MadifiedData*, *CreatedOn*, *UpdatedBy* is set for this option.
To add/edit a wildcard expression, click the OptionButton button next to the option and enter a required expression.
The compare process usually involves some large tables with many fields. Most tables have system fields like date and timestamp or user name that updated a record. Although this information is useful, usually it is not a target of comparison. This option allows you to specify the columns to be ignored during comparison. To do this, a mask by which columns will be ignored should be set. To set such mask wildcards can be used. If this option is selected, column names are compared with the specified mask during comparison (register is not taken into account). If column name corresponds to the mask, the column is ignored. Columns that don't correspond to any masks are ignored during comparison. So if you do not want to compare columns with a specific name, use this option. This way the columns won't be compared and won't participate in comparison.

Ignore computed columns
Allows ignoring computed columns during comparison.

Ignore TIMESTAMP columns
Determines if TIMESTAMP should be ignored during comparison. TIMESTAMP columns can not be synchronized.

Ignore ROWGUID columns
Determines if ROWGUID columns should be ignored during comparison.

Ignore IDENTITY columns
Determines if IDENTITY columns should be ignored during comparison. You cannot synchronize a view if it includes an IDENTITY column.

Comparison Options

A set of options used to determine the objects and records that should be compared.

Compare history table for temporal tables
When selected, history table for temporal tables will be included into comparison.

Compare memory optimized tables
When selected, memory optimized tables will be included into comparison.

Compare tables with COLUMNSTORE indexes
When selected, tables with COLUMNSTORE indexes will be included into comparison.

Ignore column is SYSTEM_TIME for temporal tables
When selected, column is SYSTEM_TIME for temporal tables will be included into comparison. You cannot synchronize a SYSTEM_TIME columns.

Compare tables
Select to include tables into comparison.

Compare views
Select to include views into comparison. Views can be synchronized only if the referenced rows are from a single table, and do not include IDENTITY or computed columns.

Round float types up to 3 digits
Select it to specify the count of digits after the decimal point. Option rounds FLOAT, NUMERIC, DECIMAL, MONEY and SMALLMONEY data types.

Compare CLR types as binary
When selected, CLR types will be compared and synchronized as binary, otherwise - as string. It is recommended to apply this option when comparing large CLR data. Do not set this option for the types which do not inherit the IComparable interface.

Ignore leading spaces
When selected, whitespaces in the start of strings will be ignored during comparison and synchronization. This option can be applied only to (N)VARCHAR columns.

Ignore trailing spaces
Select to ignore whitespaces in the end of strings during comparison and synchronization. This option can be applied to (N)VARCHAR columns.

Compare CLR types as binary
Allows to compare and synchronize CLR types as binary, otherwise as string. It is recommended to apply this option when comparing large CLR data. Do not set this option for the types which do not inherit IComparable interface.

Ignore case
Ignores case in symbols for non-key columns of the following data types: (N)CHAR, (N)VARCHAR, (N)VARCHAR(MAX), (N)TEXT, CLR. This option can be applied to data which size doesn't exceed 5 Mb.

Ignore end of line
Allows ignoring end of line characters during comparison and synchronization. The option is applied only to (N)VARCHAR columns.

Treat NULL and EMPTY STRING as the same value
Treats NULL and EMPTY STRING as the same value for CHAR and VARCHAR values while comparing.

Ignore time part in DATETIME data types
Ignores time for fields of the DATETIME types and compares only dates. For example, if you set this option values '1995-09-29 03:14:15.000' and '1995-09-29 22:14:06.540' will be considered equal. This option is supported for the DATETIME, DATETIME2, SMALLDATETIME, and DATETIMEOFFSET data types.

Display Options

A set of options used to determine the set of results to be seen after comparison.

Different records
Select to include different records into comparison results. These records are displayed in the result grid and are available for synchronization. If this option is not selected, different records will not appear in to comparison results and will not be stored on disk.

Only in source records
Select to include records that are available only in source into comparison results. These records are displayed in the result grid and are available for synchronization. If this option is not selected, only in source records will not be stored on disk and will not appear in the comparison result.

Only in target records
Select to include records that are available only in target into comparison results. These records are displayed in the result grid and are available for synchronization. If this option is not selected, only in target records will not be stored on disk and will not appear in the comparison result.

Identical records
Select to include identical records into comparison results. These records are displayed in the result grid. If this option is not selected, identical records will not be stored on disk and will not appear in the comparison result.

Buttons

Save As My Defaults
Click this button to save current settings as your default settings.

Devart Defaults
Click this button to restore the application default comparison settings.

My Defaults
Click this button to restore your default comparison settings, previously saved with the Save As My Defaults button.

Other Elements

Find
Enter the first character of the option's name to show only the options that contain this part in their names.

Save settings to a command line arguments file
Click to save settings of options to use them in an arguments file when comparing databases through the command line or scheduling a task.

ExpandedToggleIcon(9x12) See Also

Data Comparison Wizard

Edit Mask Dialog Box


Edit Mask Dialog Box

This dialog allows you to specify a custom wildcard expression for tables (or views) to include them into comparison. For example, tables or views with such names as dept, Jobs, department.Tmp_Jobs, Tmp_Job_History, sales.Dept, job.Tmp, dept.Tmp_Departments2, will be excluded from mapping if "*job*,*dept*" is set for the Exclude tables or views by mask:* option.

To open this dialog, open the Data Comparison Wizard, navigate to the Include/Exclude tables or views by mask:* option and click the three-dotted button.

The Edit Mask dialog box contains a list of expressions to replace characters or digits in the Include/Exclude tables or views by mask:* field. They are called Wildcards.

To select the required wildcard, do the following:

1. In the Edit Mask dialog box, click the [image] arrow button next to the wildcard expression field.
2. Select a wildcard from the drop-down list. It is inserted into the wildcard expression field.

The drop-down list contains the following wildcards:

Syntax | Expression | Description
, | Next mask | Use comma to specify several masks.
* | Zero or more of any character | Matches any single or more characters. For example, test* matches any text that includes "test".
? | Any single character | Matches any single character.
# | Any single digit | Matches any single digit. For example, 5# matches numbers that include 5 followed by another number, such as 51, but not 15.
[] | Any single character in the set | Matches any of the characters that is specified in the set.
[!] | Any single character not in the set | Matches any of the characters that is not specified in the set.
\ | Escape Special Character | Matches the character that follows the backslash (\) as a literal. This allows you to find the characters used in wildcard notation, such as * and #.

ExpandedToggleIcon(9x12) See Also

Data Comparison Wizard

Objects Mapping Dialog Box


Mapping, Data Comparison Wizard

Select objects and their columns to compare and set comparison keys for them on this page.

This page displays the grid with compared tables and views, comparison keys and comparison columns. The grid contains the following columns:

Column with check boxes
Select check boxes to include objects to comparison.

Object Name
Displays object names.

Comparison Key
Select comparison key in this column. Use the button to choose another key or to select and edit custom key.

Columns in Comparison
See the quantity of columns (the first number) that are compared and the whole quantity of columns existing in the object (the second number). Click the button to open the Column Mapping Dialog Box and select columns to include into comparison and map them in this column.

note Note

The Caution icon informs you about mapping warnings.

You may select several tables and views and include or exclude them from comparison together. To select several tables click them holding the CTRL key. To select all tables and views press CTRL+A.

Filter Text Box
Enter filter here to see only objects, containing the filter string in their names.

ExpandedToggleIcon(9x12) Mapping Toolbar

Icon | Name | Description
Filter | Filter | Allows using some predefined filters in addition to filtering by object name
RefreshButton | Refresh | Click to refresh mapping
MapObjects | Map Objects | Click to call the Custom Object Mapping dialog box to customize the object mapping
Unmap | Unmap | Click to unmap the object pairs, selected in the grid
CustomQueryMapping | Custom Query | Click to call the Custom Queries Mapping dialog box to customize mapping
Reset | Reset | Click to restore automatic mapping
SQLFilter | Filter | Click to open the WHERE Filter dialog box to filter Source/Target rows included into comparison.

Predefined Filters

Name | Description
All | Shows all object pairs
Valid Mappings | Shows object pairs without table level warnings
Invalid Mappings | Shows object pairs with table level warnings
Auto Mapped Objects | Objects, that were mapped automatically by dbForge Data Compare
User Mapped Objects | Objects, that were mapped manually by user
Fully Mapped Objects | Objects that were fully mapped
Partially Mapped Objects | Objects that were fully mapped
Included Objects | Object pairs, included to comparison
Excluded Objects | Object pairs, excluded from comparison

note Note
1. If not all the objects are mapped, an information link that shows the number of unmapped objects is displayed in the bottom right corner of the wizard page. Click this link to go to the Object Mapping dialog box.
2. If the primary key is not set for some object, the icon is displayed in the check boxes column.

ExpandedToggleIcon(9x12) See Also

Data Comparison Wizard

Column Mapping Dialog Box


Objects Mapping Dialog Box

This dialog allows you to set custom mapping for tables and views.

Source objects

Table
Select this radio button to display the list of tables in the source database. If there are several schemas in the database, tables are grouped by these schemas.

Filter
To quickly find a required object, enter characters available in the required object's name. Only objects, names of which contain the required characters, will be shown in the list.

Hide mapped objects
Check this option to show only unmapped objects in the list.

Target objects

Table
Select this radio button to display the list of tables in the target database. If there are several schemas in the database, tables are grouped by these schemas.

Filter
To quickly find a required object, enter characters available in the required object's name. Only objects, names of which contain the required characters, will be shown in the list.

Hide mapped objects
Check this option to show only unmapped objects in the list.

Buttons

OK
Click to map the selected source and target object and close the dialog.

Close
Click to close the dialog.

Map
Click to map the selected source and target object without closing the dialog.

ExpandedToggleIcon(9x12) See Also

Data Comparison Wizard

Mapping, Data Comparison Wizard


Column Mapping Dialog Box

This dialog allows you to set custom mapping for columns.

Comparison Keys
Use this field to choose indexes, primary keys, unique keys from the drop-down list to select the key columns automatically depending on the columns that were included into the selected index or key.

Select columns for comparison
This grid allows controlling column mapping.

Check box column
Select check boxes to include column pairs to comparison.

Source column
Contains all source columns.

Target columns
Contains Target columns, mapped to the Source columns. Click to map or unmap a Target column. The icon shows the state of the pair - normal or warning.

Key
Select check boxes to include column pairs to a comparison key.

Column details
This grid displays properties of a Source and Target column from the selected column pair in the Select columns for comparison grid.

Reset
Click to restore the automatic mapping.

Cancel
Click to cancel changes and close the dialog.

OK
Click to apply changes and close the dialog.

ExpandedToggleIcon(9x12) See Also

Data Comparison Wizard

Custom Queries Mapping Dialog Box


Custom Queries Mapping Dialog Box

This dialog allows you to set custom mapping for tables and views.

ExpandedToggleIcon(9x12) Source Object

Table or view
Select this radio button to display the list of tables in the source database. If several schemas are being compared, tables are grouped by these schemas.

Search
To quickly find a required object, enter characters available in the required object's name. Only objects, names of which contain the required characters, will be shown in the list.

Hide mapped objects
Select this option to show only unmapped objects in the list.

Query
Select this radio button to create a custom query to compare custom results.

Name
Type the query name here.

Query text box
Type a query in this box.

ExpandedToggleIcon(9x12) Target Object

Table or view
Select this radio button to display the list of tables in the target database. If several schemas are being compared, tables are grouped by these schemas.

Search
To quickly find a required object, enter characters available in the required object's name. Only objects, names of which contain the required characters, will be shown in the list.

Hide mapped objects
Check this option to show only unmapped objects in the list.

Query
Select this radio button to create a custom query to compare custom results. Specify query name in the field below.

Name
Type the query name here.

Query text box
Type a query in this box.

Use the same query for Source and Target
Select this option to use the same query for source and target.

Buttons

Validate
Click to validate both queries one by one. To validate each query separately, choose the Validate Validate command from the Query text box shortcut menu.

OK
Click to map the selected source and target object and close the dialog.

Cancel
Click to close the dialog.

Map
Click to map the selected source and target object without closing the dialog.

note Note

To start comparing queries, you should specify a key in the Key column of the Column Mapping window.

ExpandedToggleIcon(9x12) See Also

Data Comparison Wizard

WHERE Filter Dialog Box


WHERE Filter Dialog Box

In most cases comparing data in tables is performed on an entire data set. However, there are circumstances when it is necessary to limit the scope of data in a table and perform comparison and synchronization only for a limited data set. The WHERE Filter dialog box is used to enter and enforce row filtering utilizing a WHERE clause. To open it, click the SQLFilter Filter button on the toolbar of the Mapping wizard page.

The WHERE Filter dialog box is divided into Source section (on the left) and Target one (on the right). If you want to filter Source rows, enter the filtering expression in the left section. To filter Target rows, specify the expression in the right section. The dialog contains the following details:

Source object name
It displays the name of the Source object selected in the grid on the Mapping wizard page.

Source expression
Enter a filtering expression to apply to Source rows. Right-click here and select Insert Column and a required column from the shortcut menu. Type the filter expression.

Target object name
It displays the name of the Target object selected in the grid on the Mapping wizard page.

Target expression
Enter a filtering expression to apply to Target rows here.

Use the same expression for source and target
You can enter the expression in one section and select this check box to apply it for both Source or Target. The expression will be copied to the opposite section.

Validate
Click this button to validate the entered expression.

ExpandedToggleIcon(9x12) See Also

Data Comparison Wizard


Schemas Mapping Dialog Box

This dialog allows you to set custom mapping for schemas.

ExpandedToggleIcon(9x12) Schemas Mapping

Grid
Contains schemas to map.

Source
Lists all source schemas.

Target
Contains target schemas, mapped to the source schemas. Click CBDropDownArrow to map or unmap target schema.

Reset
Restores automatic mapping.

OK
Applies schema mapping.

Cancel
Cancels mapping changes.

ExpandedToggleIcon(9x12) See Also

Data Comparison Wizard

Data Synchronization Wizard


Data Synchronization Wizard

ExpandedToggleIcon(9x12) Data Synchronization Wizard Description

The Data Synchronization Wizard provides a single access to perform the basic configuration steps to synchronize compared data.

To access the Data Synchronization Wizard, click SynchroniseButton Synchronize on the Comparison toolbar.

ExpandedToggleIcon(9x12) The Main Tabs and Dialog Boxes of the Data Synchronization Wizard

Output, Data Synchronization Wizard
Allows you to select general synchronization options including script execution.

Options, Data Synchronization Wizard
Allows you to select output options to manage synchronization script.

Summary, Data Synchronization Wizard
Allows you to review the synchronization actions and warnings.


Output, Data Synchronization Wizard

ExpandedToggleIcon(9x12) Synchronization Script Output

Specify output options concerning synchronization script.

Open the synchronization script in the internal editor
Select to output the synchronization script to the SQL document.

Save the script to a file
Select to output the synchronization script to file. Click the Browse button to specify the path to save this file.

Open in the internal editor
Select to open the script in dbForge Data Compare after creating.

Execute the script directly against the target database
Select to synchronize the target database immediately.

Refresh comparison results after successful synchronization
Select to refresh comparison results after synchronization if synchronization was executed successfully.

ExpandedToggleIcon(9x12) See Also

Data Synchronization Wizard

Options, Data Synchronization Wizard


Options, Data Synchronization Wizard

ExpandedToggleIcon(9x12) Database backup

Backup path: (Path)
Select to backup the target database before synchronization and specify the backup file location. The backup file name will be generated in the following format:<database_name>_<yyyy>_<MM>_<dd>_<hh>_<mm>.bak. It is recommended to backup your database before synchronization.

Backup type: (Type)
When selected, the backup will be created in the selected mode. Creating a differential database backup requires a preliminary full database backup. If your database has never been backed up, a full database backup will be created. The copy-only mode option is available for SQL Server 2008 or higher versions.

Create folder for database backup
Select to create folder for database backup storage.

Extension for backup file: (Extension)
When selected, the extension specified in this parameter will be used for the backup file. When the option is not selected, the default extension (.bak) will be used for the backup file.

Use compression for backup
When selected, the backup compression will be performed. This option is available for SQL Server 2008 or higher version.

ExpandedToggleIcon(9x12) Transactions

Use a single transaction
Select to execute a synchronization script as a single transaction. If selected, all the changes to the database will be rolled back in case of error when executing the synchronization script.

Add error handling statements
When selected, the script will stop executing after encountering an error.

Set transaction isolation level to SERIALIZE
When selected, the transaction isolation level will be set to the selected value. This option is enabled when the 'Use a single transaction' option is selected. You can specify the following transaction isolation levels: SERIALIZE, SNAPSHOT, REPEATABLE READ, READ UNCOMMITTED, READ COMMITTED.

ExpandedToggleIcon(9x12) Common

Check for the concurrency updates
If the option is turned on, UPDATE, DELETE commands will be supplemented with non-key values in WHERE condition. This will allow avoiding accidental data rewriting on live databases. For example, UPDATE PassTable SET Code = N'New Value' WHERE ID = 1 AND Code=N'Original Code';

Disable check constraints
Select to drop check and not null constraints in the beginning of the synchronization. After synchronization the check and not null constraints will be restored.

Disable DDL Triggers
Select it to make dbForge Data Compare disable DDL triggers in the beginning of the synchronization. After the synchronization they will be enabled. Note, this option will be disabled if target database is on SQL Server 2000.

Disable DML Triggers
Select it to make dbForge Data Compare disable DML triggers in the beginning of the synchronization. After the synchronization they will be enabled. Note, for triggers on a view created on SQL Server 2000, this option drops and then recreates them.

Disable foreign keys
Select this option to disable foreign keys before synchronizing tables and to enable them after it.

Disable primary keys, indexes and unique constraints
Select to drop primary keys, indexes, and unique constraints in the beginning of the synchronization. After synchronization the primary keys, indexes, and unique constraints will be restored. If the primary key, index or a unique constraint is the comparison key, it cannot be dropped.

Generate fully qualified object names
Check this option to generate fully qualified object names in the synchronization script. If this option is enabled, object names in synchronization script will include a schema name.

Include USE <database_name>
When selected, USE <database_name> clause will be added to the script.

Reseed Identity Columns
Check this option to reseed the current value of identity column

Reseed constraints with WITH CHECK
When selected, the constraints will be created with the WITH CHECK parameter. The option increases execution time, since data validation will take place, and there is a high chance it may fail. If the option is disabled, constraints will be created in the fast mode with the WITH NOCHECK parameter.

Synchronize database in the single user mode
When selected, database will be synchronized in the single user mode.

Synchronize via files path: (Enter a path)
If this option is checked, then during synchronization files for columns of the BLOB-type are copied to the specified folder (the File Storage Path option), and synchronization script holds references to these files using the OPENROWSET function. If this option is unchecked these files are not copied, and columns of the BLOB-type will be syncronized in a usual way. Files are created only for data the size of which is greater than 1 Mb, and for data the size of which is less than 1 Mb an ordinary script is formed.

ExpandedToggleIcon(9x12) Script Comments

Exclude Comments
Check this option to prevent comments generation in synchronization script.

Include print comments
Check to print comments into output while executing the script. If print comments are included in the deployment script, it is easier to locate items in output.

ExpandedToggleIcon(9x12) See Also

Data Synchronization Wizard

Summary, Data Synchronization Wizard


Summary, Data Synchronization Wizard

ExpandedToggleIcon(9x12) Summary Information

This tab contains summary information about synchronization. It consists of two subtabs:

Action Plan
This tab displays synchronization script plan. Statements in the script will be placed in the same order as actions in the action plan. You can copy the action plan using CTRL+C.

Search
Type filter string here. Use "_" symbol to substitute any character.

Expand All
Click to expand all synchronization actions.

Collapse All
Click to collapse all synchronization actions.

Warnings
This tab displays pairs of compared table which have synchronization warnings. Point to the table pairs to see column pairs which caused the warning and the warning text. You can copy the list of warnings using CTRL+C.

ExpandedToggleIcon(9x12) See Also

Data Comparison Wizard

Comparison and Synchronization Progress Info


Comparison and Synchronization Progress Info

When comparison or synchronization is in progress, the Progress window is shown. In this window, the following information is displayed:

· The action that is being performed. They are Describing objects and Comparing data for the comparison process, and Generating script for the synchronization process.
· The count of processed objects. The total number of objects and the number of objects already processed is displayed.
· Progress bar indicating the process progress.
· The name of the database object that is being processed.
· The count of records being processed.
· Elapsed time indicates the time used during comparison or synchronization. Remaining time indicates approximate time that will be used to complete the comparison or synchronization process. You should keep in mind that remaining time can be imprecise due to the peculiarities of its measurement. Below the most common situations when the time is measured inaccurately or is not available will be described:
· The measured time can be greater than the elapsed time for large data types (for example, varchar(max)). In case of large data types the maximum possible time is stated.

note Note

If a table contains BLOB data the size of which is larger than 5Mb, the amount of the processed megabytes is displayed.
· The time will be greater, if WHERE filter is used.
· The time will be measured inaccurately when backups are compared.
· The measured time can be changed if server or network load is changed.
· The amount of the remaining time is n/a if data is retrieved from a table too slowly.
· The Skip button allows to skip comparison of a table that is being compared and starts to compare the next table. You can use this button if you don't want to compare a large table.
· The Cancel button stops the comparison or synchronization process.

ExpandedToggleIcon(9x12) See Also

Data Compare

Comparison Report


Comparison Report

This section describes the Comparison Report wizard.

ExpandedToggleIcon(9x12) In This Section

Format, Comparison Report
Select the report format and location on this page.

Options, Comparison Report
Set options for your report on this page.

ExpandedToggleIcon(9x12) See Also

Data Compare

Data Comparison Document


Format, Comparison Report

The Generating Comparison Report window will help to generate a comparison report for the comparison performed before.

To access the Comparison Report Window:

On the Comparison menu click Generate Comparison Report.

ExpandedToggleIcon(9x12) Available Options

In this window you can choose the following options for the report:

Format
Specify the format of the report file you want to generate.

HTML
Generate a report in the HTML format.

Excel
Generate a report in the Excel (XLS) format.

CSV
Generate a report in the CSV format.

Name
Specify the name of the report file.

Location
Specify where the report should be created. Click Browse... specify the location.

Create report for

All objects
Check this option to include all objects (except identical ones) into your report.

Identical objects
Check this option to include identical objects into your report.

Objects marked for synchronization
Include only objects marked for synchronization into your report.

View the report on completion
Check this option to view the generated report after it was completed.

ExpandedToggleIcon(9x12) See Also

Comparison Report

Options, Comparison Report


Options, Comparison Report

ExpandedToggleIcon(9x12) Available options

In this window you can choose the additional options for the report:

Show number of differences per column
Check this option to include the list with the number of differences in each column to your report. For each database table, a table with the list of columns and the number of differences in them will be created.

Include comparison settings
Check this option to include comparison options into your report. This option is available only for HTML reports.

Include actual data records for different objects
Check this option to include data records available in your database tables into your report. For HTML report, each tablename in the main part of the report will be turned into a link to the part of the report where all data records are listed. For Excel report, pages containing this information will be added.

Hide unmodified columns
Only data that contains differences will be added to the report.

ExpandedToggleIcon(9x12) See Also

Comparison Report

Data Comparison Document


Data Comparison Document

Use this document to see, analyze data comparison results and set up synchronization. It consists of the following:

note Note

Actual document look may slightly vary from the image above, depending on the product you use.

Comparison Result Grid Shortcut Menu and Comparison Toolbar

The shortcut menu of the Comparison Result Grid of a Data Comparison document provides a number of options to manage the data comparison document:

edit-comparisonDataComparisonDocument Edit Comparison...
Calls Data Comparison Wizard where you can change options for the performed data comparison and perform new data comparison.

RefreshButton Refresh
Refreshes the opened comparison document.

stop-execution Stop Execution
Terminates data comparison or synchronization operation.

FilterDataComparisonDocument Filter
Use it to filter the comparison results by their status. Click the down arrow near the Filter button and select the corresponding option in the appeared menu.

filter-allDataComparisonDocument All
All rows are included into the grid.

filter-differentDataComparisonDocument With Different Rows
Only different rows are included into the grid.

filter-identicalDataComparisonDocument With Identical Rows Only
Only identical rows are included into the grid.

filter-conflictDataComparisonDocumen With Conflict Rows
Only conflict rows are included into the grid.

Included Objects
Only rows with included objects are shown into the grid.

Excluded Objects
Only rows with excluded objects are shown into the grid.

Correctly Mapped Objects
Check this option to show correctly mapped objects.

Incorrectly Mapped Objects
Select show incorrectly mapped objects. Objects are considered as mapped incorrectly if there is no comparison key or source or target object was described with error.

Generate Comparison Report
Opens the Comparison Report wizard. Go through the wizard pages to generate a report.

Synchronize
Opens Data Synchronization Wizard.

Exclude Selected Objects
Excludes selection from the needed row, if available.

Include Selected Objects
Includes selection into the needed row, if available.

Change Synchronization Direction
Changes the synchronization direction, so you can synchronize both databases without re-comparing them.

Document Header

Document header shows:

· The search field that allows you to find an object.
· Source and Target databases with their connections.
· Number of selected objects.

Comparison Data Details Grid

The Comparison Data Details Grid displays all the records of each compared object that is selected in the Comparison Result Grid. The records are automatically grouped by status and displayed on separate tabs, and are easy to navigate.

Column with check boxes
Select a check box to include an object to data synchronization.

Owner
Shows an owner of a source object.

Source Object
The object of the Source database that will be compared with the corresponding object of the Target database.

Only in Source
Displays a quantity of records that exist only in source database.

Different Records
Displays a quantity of records, having the same comparison key value, but differing in other columns.

Only in Target
Displays a quantity of records that exist only in target database.

Identical Records
Displays a quantity of identical records. Note that this column is available only if the Identical records option of Data Comparison Wizard is turned on.

Conflict Records
Appears only if there are conflict records (records, having non-unique values of the custom comparison key). It displays numbers of different key values in the conflict records.

Target Object
The object of the Target database which contents you compare and synchronize with the Source one.

Owner
Shows an owner of a target object.

Comparison Data Details Grid Toolbar

Only in Source
Displays a quantity of records that exist only in source database.

Different Records
Displays a quantity of records, having the same comparison key value, but differing in other columns.

Only in Target
Displays a quantity of records that exist only in target database.

Identical Records
Displays a quantity of identical records. Note that this column is available only if the Identical records option of Data Comparison Wizard is turned on.

Conflict Records
Appears only if there are conflict records (records, having non-unique values of the custom comparison key). It consists of two grids, each containing conflict records from the corresponding database.

GoToNextRight Go to the next difference
Points the next difference.

GoToNextLeft Go to the previous difference
Points the previous difference.

GoToNextDown Go to the next difference for the selected column
Points the next difference in column.

GoToNextUp Go to the previous difference for the selected column
Points the previous difference in column.

findDataComparisonDocument Find
Opens the Find and Replace Window. Use this option to start search in the grid.

visible-columnsDataComparisonDocument Visible Columns
Opens the Visible Columns dialog box. Use it to display only the needed columns in the bottom grid.

LockKeyColumns Lock Key Columns
Allows to keep an area of a worksheet visible while you scroll to another area of the worksheet, you can lock key columns in one area by freezing or splitting panes.

HideUnmodifiedColumns Hide unmodified columns
If this checkbox is checked, only columns that contain differences are displayed in the grid.

detached-window-btn Show comparison results in a detached window
Click to show Comparison Data Details Grid in a detached window.

collapse-btn Collapse Pane
Click to collapse Comparison Data Details Grid.

expand-btn Expand Pane
Click to expand Comparison Data Details Grid. The button appears only if Comparison Data Details Grid was collapsed previously.

Shortcut Menu of the Comparison Data Details Grid

The shortcut menu of the Comparison Data Details Grid of a Data Compare document contains the following options (options identical to the ones available on the toolbar are omitted):

best-fitDataComparisonDocument Best Fit
Fits the size of the selected column to the size of data available in it.

Best Fit (all columns)
Fits the size of each column displayed in the grid to the size of data available in it.

viewDifference View Difference
Opens the Data Viewer and Editor window where differences between records can be viewed. If the Data Viewer and Editor window is already opened, it makes this window active.

The status bar in the bottom of the grid displays the number of differences in each column shown in it.

ExpandedToggleIcon(9x12) See Also

Data Compare


Database Connection

This section describes Data Connection user interface elements.

note Note

Database Explorer is not available in the following products:

· dbForge Data Compare for SQL Server
· dbForge Schema Compare for SQL Server
· dbForge Data Generator for SQL Server
· dbForge Event Profiler for SQL Server

ExpandedToggleIcon(9x12) In This Section

Database Connection Properties Dialog Box
Information about connection parameters.

Connect to SQL Database Dialog Box
The topic helps you to connect to the server without having specified a password.

Browse for Servers Dialog Box
The topic helps you to select local and network servers.

Connection Manager Dialog Box
The topic helps you to create, edit, and delete database connections.

Connect to Server Dialog Box
The topic helps you to connect to the server when the Database Explorer window is not activated.


Database Connection Properties Dialog Box

Use the Database Connection Properties dialog box to setup or change the database connection parameters. There are several ways to access the Database Connection Properties dialog box:

· Click New Connection on the Database Explorer window toolbar.
· In Database Explorer, open the shortcut menu for the data connection you want to modify and choose Modify Connection.
· In the Database menu, click New Connection.
· Right-click in the Database Explorer, and then select New Connection on the shortcut menu.

note Note

Database Explorer is not available in the following products:

· dbForge Data Compare for SQL Server
· dbForge Schema Compare for SQL Server
· dbForge Data Generator for SQL Server
· dbForge Event Profiler for SQL Server

The Database Connection Properties dialog box includes the following tabs:

General, Database Connection Properties Dialog Box
Allows you to set the login information required to connect to the SQL Server.

Advanced, Database Connection Properties Dialog Box
Allows you to set additional options to tune database connections.

ExpandedToggleIcon(9x12) See Also

Database Connection

Browse for Servers Dialog Box


General, Database Connection Properties Dialog Box

Use the General tab of the Database Connection Properties dialog box to view and manage the following parameters of an SQL Server database connection:

Server
Select the server instance to connect to. The server instance last connected to is displayed by default.

Authentication
Two authentication modes are available when connecting to an instance of the Database Engine.

Windows Authentication
Microsoft Windows Authentication mode allows a user to connect through a Windows user account.

SQL Server Authentication
When a user connects with a specified login name and password from a non-trusted connection, SQL Server performs the authentication itself by checking to see if a SQL Server login account has been set up and if the specified password matches the one previously recorded. If SQL Server does not have a login account set, authentication fails, and the user receives an error message.

Active Directory Password Authentication
Allows connecting to MicrosoftAzure SQL Database with help of identities in Azure Active Directory. Use this method for connecting to SQL Database if you are logged into Windows using credentials from a domain that is not federated with Azure, or when using Azure AD authentication using Azure AD based on the initial or the client domain.

Active Directory Integrated Authentication
Allows connecting to MicrosoftAzure SQL Database by using identities in Azure Active Directory. Use this method for connecting to SQL Database if you are logged into Windows using your Azure Active Directory credentials from a federated domain.

Login
Enter the login to connect with. This option is not available if you have selected to connect using Windows Authentication.

Password
Enter the password for the login. This option is not available if you have selected to connect using Windows Authentication.

Allow saving password
If selected, the password is stored among the other connection parameters.

Database
Select a name of an SQL Server database you want to connect to.

Show all databases
Select the check box to show all databases.

Connection Name
Use this text box, to specify the connection name.

Document Category
You can assign a category for a document to associate it with a specific connection.

Test Connection
Click this button to make the test connection to a database.

ExpandedToggleIcon(9x12) See Also

Database Connection Properties Dialog Box

Advanced, Database Connection Properties Dialog Box


Advanced, Database Connection Properties Dialog Box

The Advanced properties tab provides the following options:

Connection timeout
Sets the length of time (in seconds) to wait for a connection to the server before terminating the attempt and generating an error. The default value is 15 seconds.

Execute timeout
Sets the length of time (in seconds) to wait for a query execution before terminating the attempt and generating an error.

Encrypt connection
Forces encryption of the connection.

To add more connection parameters to the connection string, use the additional connection parameters.

Keyword

Default

Description

Asynchronous Processing

When true, enables asynchronous operation support. Recognized values are true, false, yes, and no.

AttachDBFilename

"false"

The name of the primary database file, including the full path name of an attachable database. AttachDBFilename is only supported for primary data files with an .mdf extension. The attachment will fail if the primary data file is read-only. The path may be absolute or relative.

Connection Timeout

15

The length of time (in seconds) to wait for a connection to the server before terminating the attempt and generating an error.

Context Connection

"false"

true if an in-process connection to SQL Server should be made.

Current Language

The SQL Server Language record name.

Data Source

The name or network address of the instance of SQL Server to which to connect. The port number can be specified after the server name: server=tcp:servername, portnumber. When specifying a local instance, always use (local). To force a protocol, add one of the following prefixes: np:(local), tcp:(local), lpc:(local)

Encrypt

"false"

When true, SQL Server uses SSL encryption for all data sent between the client and server if the server has a certificate installed. Recognized values are true, false, yes, and no.

Failover Partner

The name of the failover partner server where database mirroring is configured.

Initial Catalog

The name of the database.

Integrated Security

"false"

Whether the connection is to be a secure connection or not. Recognized values are 'true', 'false', and 'sspi', which is equivalent to 'true'.

MultipleActiveResultSets

"false"

When true, an application can maintain multiple active result sets (MARS). When false, an application must process or cancel all result sets from one batch before it can execute any other batch on that connection. Recognized values are true and false.

MultiSubnetFailover

Always specify multiSubnetFailover=Yes when connecting to the availability group listener of a SQL Server 2012 availability group or a SQL Server 2012 Failover Cluster Instance. multiSubnetFailover=Yes configures SQL Server Native Client to provide faster detection of and connection to the (currently) active server. Possible values are Yes and No.

Network Library

The network library used to establish a connection to an instance of SQL Server. Supported values include dbnmpntw (Named Pipes), dbmsrpcn (Multiprotocol, Windows RPC), dbmsadsn (Apple Talk), dbmsgnet (VIA), dbmslpcn (Shared Memory, local machine only) and dbmsspxn (IPX/SPX), dbmssocn (TCP/IP) and Dbmsvinn (Banyan Vines).

The corresponding network DLL must be installed on the system to which you connect. If you do not specify a network and you use a local server (for example, "." or "(local)"), shared memory is used.

Packet Size

Size in bytes of the network packets used to communicate with an instance of SQL Server.

Password

The SQL Server password.

Persist Security Info

"false"

When set to 'false' (strongly recommended), security-sensitive information, such as the password, is not returned as part of the connection if the connection is open or has ever been in an open state. Resetting the connection string resets all connection string values including the password.

Replication

"false"

true if replication is supported using the connection.

TrustServerCertificate

"false"

When set to true, SSL is used to encrypt the channel when bypassing walking the certificate chain to validate trust. If TrustServerCertificate is set to true and Encrypt is set to false, the channel is not encrypted. Recognized values are true, false, yes, and no.

Type System Version

A string value that indicates the type system the application expects. Possible values are:

· Type System Version=SQL Server 2000;
· Type System Version=SQL Server 2005;
· Type System Version=SQL Server 2008;
· Type System Version=Latest;

When set to SQL Server 2000, the SQL Server 2000 type system is used. The following conversions are performed when connecting to a SQL Server 2005 instance:

· XML to NTEXT
· UDT to VARBINARY
· VARCHAR(MAX), NVARCHAR(MAX) and VARBINARY(MAX) to TEXT, NEXT and IMAGE respectively.

When set to SQL Server 2005, the SQL Server 2005 type system is used. No conversions are made for the current version of ADO.NET.

When set to Latest, the latest version than this client-server pair can handle is used. This will automatically move forward as the client and server components are upgraded.

User ID

The SQL Server login account.

User Instance

"false"

A value that indicates whether to redirect the connection from the default SQL Server Express instance to a runtime-initiated instance running under the account of the caller.

Workstation ID

The local computer name

The name of the workstation connecting to SQL Server.

ExpandedToggleIcon(9x12) See Also

Database Connection Properties Dialog Box

Browse for Servers Dialog Box


Connect to SQL Database Dialog Box

The dialog box appears when you connect to the server without having specified a password.

Authentication
Specify the required authentication mode here.

User
Enter the name for the SQL login account.

Password
Enter the password for the SQL login account.

Server
Specify the server you want to connect to.

Database
Specify the database you want to work with.

ExpandedToggleIcon(9x12) See Also

Database Connection

Browse for Servers Dialog Box


Browse for Servers Dialog Box

Use the Browse for Servers dialog box to select the local and network servers.

This dialog box appears when you click <Browse...> in the Server combo-box (which is located on the General tab of the Database Connection Properties dialog box)

The Database Connection Properties dialog box provides the next members:

Local Servers
Displays the list of local servers.

Network Servers
Allows you to select an SQL Server instance in the network.

Refresh
Refreshes the list of network servers.

ExpandedToggleIcon(9x12) See Also

Database Connection

Connect to Server Dialog Box


Connection Manager Dialog Box

Connection Manager dialog box allows you to create, edit, and delete database connections.

ExpandedToggleIcon(9x12) Dialog Box Controls

Dialog box contains the following controls:

Connections
The list of the existing database server connections.

New
Click to open Database Connection Properties dialog box for creating a new connection.

Edit
Click to open Database Connection Properties dialog box for editing a connection.

Delete
Click to delete the connection.

Connection String
Displays a connection string, containing the connection parameters, for the selected connection.

ExpandedToggleIcon(9x12) See Also

Database Connection

Connect to Server Dialog Box


Connect to Server Dialog Box

Use the dialog box to connect to the server when the Database Explorer window is not activated.

note Note

Database Explorer is not available in the following products:

· dbForge Data Compare for SQL Server
· dbForge Schema Compare for SQL Server
· dbForge Data Generator for SQL Server
· dbForge Event Profiler for SQL Server
· dbForge Documenter for SQL Server

Connections
Displays information on available server connections.

Server
Specify the server connection you want to create a new SQL document in.
Database
Specifies a database you want ot connect to.
User
Specifies a connection user login.
Name
Specifies a selected server database name.

ExpandedToggleIcon(9x12) See Also

Database Connection


Data Editor

This section provides information on data managing windows and dialogs.

ExpandedToggleIcon(9x12) In This Section

Data Viewer and Editor
Describes how to view and edit fields of large data types.

Custom AutoFilter Dialog Box
Tells how to build a custom filter for a data column.

Filter Editor Dialog Box
Describes how to build complex filter conditions for table data.

Visible Columns Dialog Box
Tells how to filter data by hiding some columns.

Data Editor Window
Describes user interface elements of the Data Editor window.


Data Viewer and Editor Window

Data Viewer and Editor is a tool which allows simple viewing and editing fields.

The control automatically detects type of the content of the BLOB field and represents it as an image, text, rich text or hex dump. To access Data Viewer and Editor, on the View menu, click Data Viewer and Editor. Then just select the text or BLOB field, and its content appears in the Data Viewer and Editor window.

load-data Load Data
Replaces the cell content with the data from the file. It opens the Open File dialog where you can select a required file and specify the encoding which should be applied to open and save the file content.

Save Save Data
Opens the Save File As dialog to save data to a file.

note Note

If you try to save to database more data than can be stored in the selected column type, the data will be truncated.

Save Data at the Left
Saves data displayed in the left part of the window to a file.

Save Data at the Right
Saves data displayed in the right part of the window to a file.

note Note

The Save Data at the Left and Save Data at the Right options are available for comparison results.

null-data Null Data
Sets the cell value to NULL.

Apply Changes
Click to apply changes.

cancel-changes Cancel Changes
Click to cancel changes.

copy-cell Copy Entire Cell Value
Copies the cell data into the clipboard.

Paste Entire Cell Value
Replaces the cell data with the data from the clipboard. The format of the pasted data is automatically detected and the required view is set.

cut-cell Cut Entire Cell Value
Cut the cell data placing it to the clipboard.

Hexadecimal View
Shows cell data as hex dump.

Text View
Shows cell data as a text.

xml-view XML View
Shows the cell data as structured XML.

json-icon JSON View
Shows cell data as a JSON string.

Rich Text View
Shows cell data as a rich text.

Image View
Shows cell data as an image.

geometry-viewer Spatial View - Geometry
Shows geometry data as an image. The image in the view can be moved with the mouse pointer. The image can be also zoomed in and out. To zoom the image in, hold down the Ctrl key and roll the mouse wheel forward. To zoom the image out, hold down the Ctrl key and roll the mouse wheel backward.

FitScale Fit Image
Fits an image to the size of the window.

View White Space
Shows each white space with a green character.

Type | Size
Shows the type and size of the displayed data. If data cannot be displayed in the selected view, the Type will be set to Unknown.

note Note

You can copy all data in the cell by using the CTRL+SHIFT+C shortcut. Format of the copied data will depend on the selected view. For example, if the Hexadecimal view is selected, the data will be copied in hex order; data in the Text view, will be copied in text format, etc.

ExpandedToggleIcon(9x12) See Also

Data Editor

Custom AutoFilter Dialog Box


Custom AutoFilter Dialog Box

Custom AutoFilter dialog is used to create a custom filter for a data grid column. It is displayed when choosing Custom in the grid drop-down filter list.

Using this dialog, you can build a custom data filter with two conditions for a column. Condition relation can be selected from the drop-down list in the left box and value for relation can be entered in the right box. Select And or Or option, and click OK to apply the filter.

ExpandedToggleIcon(9x12) See Also

Data Editor

Filter Editor Dialog Box


Filter Editor Dialog Box

Use the Filter Editor dialog to create complex filter conditions to filter data in the data grid. To open this dialog, right-click a required column and select the [image] Condition item from the Quick Filter sub-menu.

Filter conditions in the Filter Editor dialog box are displayed as a tree with condition and group nodes. A group consists of several conditions or subgroups, united with a logical operator.

Condition Tree

The upper part of the Filter Editor dialog is a condition tree. Its nodes are red-colored condition groups and conditions, started with blue-colored column name.

Condition Group

It is displayed as a red-colored logical operator and a FilterGreyAdd button. Clicking the FilterGreyAdd button adds a new condition to group. Clicking the logical operator displays the following menu:

And
Sets And logical operator for the group. All group conditions must be true.

Or
Sets And logical operator for the group. At least one condition from the group must be true.

Not And
Sets Not And logical operator for the group. At least one condition from the group must be false.

Not Or
Sets Not Or logical operator for the group. All group conditions must be false.

Add Condition
Adds a new condition to the group.

Add Group
Adds a new condition group to the current group.

Clear All
This command is available for the top-level condition group only. Removes all conditions and subgroups, leaving only the top-level group node.

Remove Group
This command is available for the non-top-level condition group only. Removes the condition group.

Condition

It consists of the following parts:

Condition column
Blue-colored name of the grid column, to which condition will be applied. You can set another column for the condition by clicking the column name and choosing the column from the appeared menu.

Criteria operator
Green-colored criteria operator. You can set another operator for the condition by clicking the operator name and choosing the operator from the appeared menu.

Operand value
Click and enter the operand value here. Some operators have no operand values (for example Is blank operator), some may have several values.

FilterGreyAdd
This button appears for operators that can have one or more operand values. Click it to add one more operand value.

FilterGreyDel
Click this button to delete the condition. You can also navigate to the condition and press the DELETE or MINUS SIGN key

To navigate between conditions and groups, use the UP ARROW and DOWN ARROW keys. To navigate between a condition column, a criteria operator and a operand value, use the LEFT ARROW and RIGHT ARROW keys.

Buttons

OK
Apply the filter and close Filter Builder dialog.

Cancel
Close Filter Builder dialog and cancel all filter changes.

Apply
Apply the filter and without closing Filter Builder dialog.

ExpandedToggleIcon(9x12) See Also

Data Editor

Visible Columns Dialog Box


Visible Columns Dialog Box

Use the Visible Columns dialog to simplify data analysis and filter data by hiding some columns in the grid. To open this dialog, select Visible Columns from the column shortcut menu. The Visible Columns dialog contains the following:

List of columns
Clear a check box next to a column to hide the column data in the grid. Select a check box to show the column data again.

Select / Deselect All
Select this check box to show all the columns at once. Clear the check box to manually select required columns.

Sort alphabetically
Select it to show the columns in alphabetical order.

ExpandedToggleIcon(9x12) See Also

Data Editor

Data Editor Window


Data Editor Window

This topic describes the Data Editor window user interface elements.

RefreshButton Refresh Data
Use this option to refresh data.

Stop Refresh Data
Use this option to stop refresh operation.

Cached Updates Mode
Allows you to control data editing within single database object.

Apply Changes
Click to store your changes to the server.

Cancel Changes
Click in case you do not want the changes to be applied.

Paginal Mode
Use the Paginal Mode to simplify data view by dividing it into parts.

Go To First Page
Click the Go To First Page button to open the first part page of data.

Go To Previous Page
Click the Go To Previous Page button to open the previous part page of data.

Go to Next Page
Click the Go to Next Page button to open the next part page of data.

Go To Last Page
Click the Go To Last Page button to open the last part page of data.

Switch To Grid View
Click the Switch To Grid View button on the data view toolbar to switch to the Grid View mode.

Switch To Card View
Click the Switch To Card View button to switch to the Card View mode.

Show Group By Box
Click the Show Group By Box button to group data by column.

Auto-search mode
Click the Auto-search mode button to switch to the Auto-search mode. You can also switch to the Auto-search mode by pressing CTRL+I keys.

Data Editor Grid
Contains editable data. It could be represented as a table in the Grid View mode as well as cards in the Card View mode.

First First
Click the First button to switch to the first record field.

Previous Previous
Click the Previous button to switch to the previous record field.

Next Next
Click the Next button to switch to the next record field.

Last Last
Click the Last button to switch to the last record field.

Append Append
Click the Append button to insert more records.

Delete Delete
Click this button to delete the records.

End Edit
Click this button to confirm the changes.

Cancel Edit
Click the Cancel Edit button to discard the changes.

ExpandedToggleIcon(9x12) See Also

Data Editor


Execute Script Wizard

Use this wizard for executing large scripts without opening them in the editor. To access the Execute Script Wizard, on the Database menu, click ExecuteLargeScript Execute Large Script. The wizard pages are listed below.

ExpandedToggleIcon(9x12) Script Location, Execute Script Wizard

Use this page to choose a location and connection parameters of a large script to execute it without opening in the text editor. This will significantly save your time while working with large scripts.

Options

Connection
Click the field to select a connection to a required server where you want to execute your script. In the drop-down list of the field you can click the <Manage...> link to open the Connection Manager dialog box. It will help you to create, edit, and delete existing connections.

Database
Click the field to select a required database from the list of all databases available on the selected SQL Server.

File Name
Enter the path to a script you want to execute or click the Browse button to select the path in the Open dialog.

SQL file encoding
Select the encoding which should be applied to open and execute the script. The program automatically selects it based on the script, if it fails, the default encoding (the current Windows encoding on the machine where dbForge Data Compare for SQL Server is running) is selected.

Execute
Click it to execute the selected script.

Cancel
Click it to close the wizard and discard the script execution.

ExpandedToggleIcon(9x12) Execution Progress, Execute Script Wizard

See script execution progress on this page. To stop the script execution, click the Cancel button.

ExpandedToggleIcon(9x12) Operation Complete, Execute Script Wizard

See the results of script execution on this page.

ExpandedToggleIcon(9x12) See Also

Reference


Find and Replace Window

You can use the Find and Replace window to search for text, expressions, or entity names within the code of your documents. To access this window, from the Edit menu, click Find and Replace, and then select one of the options listed.

The Find and Replace window contains a toolbar with two drop-downs, one for find operations and one for replace operations. When you select an operation, the corresponding options for the operation are displayed. You can search and replace in one or more files or an entire project for text, SQL code, or symbols.

ExpandedToggleIcon(9x12) In This Section

Find, Find and Replace Window
Used to search the active file for a string or expression. Jumps from match to match within each document.

Find in Files, Find and Replace Window
Used to search for a string or expression in files stored within a set of search folders, or across the active solution. Displays matches in the Find Results windows.

Choose Search Folders Dialog Box
The topic describes Choose Search Folders dialog box that allows you to create your own set of search folders, and to specify the order in which they are searched.

Find Results Window
The topic describes the Find Results window that allows you to navigate text search results


Find, Find and Replace Window

Use Find and Replace dialog box for searching and replacing text in the code editor.

note Note

The dialog boxes and menu commands you see might differ from those described in Help depending on your active settings or edition.

To access the Find and Replace dialog box:

1. In the Edit menu, click Find and Replace.
2. Select required option from the list.

An alternative way to access the Find and Replace window is by pressing CTRL+F shortcut key.

ExpandedToggleIcon(9x12) Menus

Find
Allows to select Find or Find in Files dialog.

Find
The search will be executed in an open document.

Find in Files
The search will be executed in the selected files or a project. If this option is selected, the Find and Replace window provides additional options. You can create a set of selected folders, specify search file types, and set result options.

Replace
Allows to select Replace or Replace in Files dialog.

Replace
The search will be executed in the document. The occurrences will be replaced with the replacement string.

Replace in Files
The search will be executed in the files or a project. The occurrences will be replaced with the replacement string.

ExpandedToggleIcon(9x12) General Options

Find what
To search for a new text string or expression, specify it in the box. To search for any of the strings that you searched for most recently, open the list, and select the string for which you want to search. You can also:

· Reuse the search strings by selecting any from the drop-down list in the field
· Enter a new search string into the field
· Use regular expressions as search strings
· Use wildcards in your search strings

Replace with
Replacement string.

Look in
Select search location here.

Current Document
Search will be executed in current document only.

Current Window
Search will be executed in current tool window. It can be either the Output window or the Data Viewer and Editor window.

All Open Documents
Search will be executed in all open documents.

Selection
Search will be executed in the selected text.

Current Project
Search will be executed in the opened project.

ExpandedToggleIcon(9x12) Find Options

Match case
Case sensitive search.

Match whole word
The string will not be found/replaced if it is not a whole word.

Search up
Search will be performed in reverse direction.

Search hidden text
Search in collapsed text areas (such as regions, definitions and others) will be also performed.

Use
Use regular expressions or wildcards in search.

Regular expressions
A regular expression is a pattern of text that consists of ordinary characters (for example, letters a through z) and special characters, known as metacharacters. The pattern describes one or more strings to match when searching text. If this option is selected, the arrow button next to the Find what field becomes active. You can click the button and select a required regular expression to add to the Find what field.

Wildcards
This is a list of expressions to replace characters or digits in the Find what field.

ExpandedToggleIcon(9x12) Buttons

Find Next
Searches the next occurrence in document.

Bookmark All
Sets bookmarks for the lines, that contain occurrences in the scope. Available for the Find mode.

Replace
Searches the next occurrence in document or replaces the selected one if on replace dialog, shows replace dialog if on search dialog. Available for the Replace mode.

Replace All
Replaces all occurrences in search location. Available for the Replace mode.

ExpandedToggleIcon(9x12) See Also

Find and Replace Window

Find in Files, Find and Replace Window


Find in Files, Find and Replace Window

Use the Find and Replace window to find and replace text in the selected files.

note Note

The dialog boxes and menu commands you see might differ from those described in Help depending on your active settings or edition.

To access the Find in Files, Find and Replace dialog box:

1. In the Edit menu, click Find and Replace.
2. Select required option from the list.

An alternative way to access the Find in Files, Find and Replace window is by pressing CTRL+F shortcut key, and then select Find in Files from the Find menu.

ExpandedToggleIcon(9x12) Menus

Find
Allows to select Find or Find in Files dialog.

Find
The search will be executed in the opened document.

Find in Files
The search will be executed in the selected files or a project. If this option is selected, the Find and Replace window provides additional options. You can create a set of selected folders, specify search file types, and set result options.

Replace
Allows to select Replace or Replace in Files dialog.

Replace
The search will be executed in the document. The occurrences will be replaced with the replacement string.

Replace in Files
The search will be executed in the files or a project. The occurrences will be replaced with the replacement string.

ExpandedToggleIcon(9x12) General Options

Find what
String that will be searched. This field allows you to use a string or a regular expression that will be matched. You can do the following:

· Reuse the search strings by selecting any from the drop-down list in the field
· Enter a new search string into the field
· Use regular expressions as search strings
· Use wildcards in your search strings

Replace with
Replacement string.

Look in
Select a search location here, either selecting options from the drop-down list or creating a new set of folders in the Choose Search Folders window. The drop-down list contains the following options:

Current document
Search will be executed in the current document only.

All open documents
Search will be executed in all open documents.

Current Project
Search will be executed in the opened project.

Button
Click to open the Choose Search Folders dialog box for creating custom named folder list.

Include sub-folders
Select this check-box to include the sub-folders within the selected folder set in the Look in field.

ExpandedToggleIcon(9x12) Find Options

Match case
Case sensitive search.

Match whole word
The string will not be found/replaced if it is not a whole word.

Use
Select this check-box to activate the use of regular expressions or wildcards in search strings.

Regular expressions
A regular expression is a pattern of text that consists of ordinary characters (for example, letters a through z) and special characters, known as metacharacters. The pattern describes one or more strings to match when searching text. If this option is selected, the arrow button next to the Find what field becomes active. You can click the button and select a required regular expression to add to the Find what field.

Wildcards
This is a list of expressions to replace characters or digits in the Find what field.

Look at these file types
Select the required file types from the drop-down list. The search will be executed only in files of the selected type.

ExpandedToggleIcon(9x12) Result Options

Display file names only
Select this check-box to show one entry per a file containing a search match.

Keep modified files open after Replace All
Select this check-box to leave all modified files open after Replace All is performed. It will allow you to undo or save the changes in the files.

ExpandedToggleIcon(9x12) Buttons

Find Next
Searches the next occurrence in document.

Find All
Searches for all occurrences in the scope. Available for the Find in Files mode.

Replace
Searches the next occurrence in document or replaces the selected one if on replace dialog, shows replace dialog if on search dialog. Available for the Replace in Files mode.

Replace All
Replaces all occurrences in search location. Available for the Replace in Files mode.

ExpandedToggleIcon(9x12) See Also

Find and Replace Window

Choose Search Folders Dialog Box


Choose Search Folders Dialog Box

This dialog allows you to create, save, and revise your own set of search folders, and to specify the order in which they are searched. To open this dialog, click the Button button, next to the Look in field.

Folder set
Shows the folders available for search. To create a new folder set, enter a name, add a set of search folders to the Selected folders list, and then click the Apply button.

Apply
Saves the set of search folders in the Selected folders list as a named folder set. This folder set then can be chosen in the Look in field on all tabs of the Find and Replace window. Leaves the Choose Search Folders dialog box open.

Delete
Removes the selected folder set from the Folder set field, and from the Look in field on all tabs of the Find and Replace window.

Available folders
Select a previously selected folder from the drop-down list to populate the Selected folders list.

List of Folders
Shows the drives and folders available within the folder selected in the Available folders drop-down list. Double-click to expand any drive or folder listed. Select a folder, or hold down the SHIFT or CTRL key to select multiple folders. To add a selected folder to the Selected folders list, click the arrowright right-arrow button. To remove a selected folder, click the arrowleft the left-arrow button.

Up
Moves the selection in the Available folders list one level higher in the folder hierarchy.

Selected folders
Lists folders added from the Available folders list. These folders will be included in the named folder set.

Arrow buttons
arrowright - Moves folders to the Selected folders list.

arrowleft - Selects folders from the Selected folders list.

arrowup - Moves the selected folder to one position higher in the Selected folders list so that the folder will be searched earlier.

arrowdown - Shifts the selected folder to one position down in the Selected folders list so that the folder will be searched later.

OK
Saves the set of search folders listed in Selected folders list as a named folder set. This folder set then can be chosen in the Look in field on all tabs of the Find and Replace window. Closes the Choose Search Folders window.

Cancel
Discards all changes and closes the Choose Search Folders window.

ExpandedToggleIcon(9x12) See Also

Find and Replace Window

Find Results Window


Find Results Window

Find Results window allows you to navigate text search results. It provides you following search results: file name, line number and part of the text, containing the match. You may double-click on matches to navigate to them. Find Results window has following toolbar buttons.

Go to the location on the current line
Moves caret to the selected line location of the match found.

Go to the previous location in the list
Moves caret to the selected line location of the previous match found.

Go to the next location In the list
Moves caret to the selected line location of the next match found.

Clear All
Clears Find Results window.

ExpandedToggleIcon(9x12) See Also

Find and Replace Window


Options

This section describes different options that are available in dbForge Studio.

ExpandedToggleIcon(9x12) In This Section

Environment Options
This section describes Environment options which determine how certain elements of the dbForge Studio display and behave.

Text Editor Options
This section describes Text Editor options that provide a variety of ways to customize the performance and appearance of the editor.

Query Execution Options
This section provides a variety of ways to customize the performance of query execution.

Data Editor
This section describes the Data Editor options.

Data Comparison Options
This section describes options that allows you to change the default behavior of the Data Comparison.


Environment Options

You can use the pages in the Environment folder in the Options dialog box to set how certain elements of the Data Compare for SQL Server display and behave. You can access the Environment pages by clicking Options on the Tools menu, and then clicking Environment.

ExpandedToggleIcon(9x12) In This Section

General, Environment, Options Dialog Box
Lists general environment preferences and explains them.

Keyboard, Environment, Options Dialog Box
Describes the tab where you can customize shortcut keys.

Output, Environment Options Dialog Box
Describes the tab where you can customize application output.

Documents, Environment, Options Dialog Box
Describes the tab where you can customize the document view layout.

Web Browser, Environment, Options Dialog Box
Describes the tab where you can set Data Compare for SQL Server web browser options.

ExpandedToggleIcon(9x12) See Also

Options

Text Editor Options


General, Environment, Options Dialog Box

Use this page of the Options dialog box to change settings for the Data Compare for SQL Server. You can access the Options dialog box by clicking Options on the Tools menu and then selecting the General page in the Environment folder.

Settings

At startup
Select what to do when Data Compare for SQL Server starts up.

Show Startup page
A Start Up page will be opened at startup.
Load Last Opened Project
Last opened project will be loaded at startup.
Create New SQL Document
A new empty SQL document will be created at startup.

Show Empty Environment
No documents or projects will be opened or created at startup.

Check updates on startup once a week
Select this option so that dbForge Data Compare for SQL Server will check if any updates are available for the product every week

Show splash screen on startup
Clear to turn off splash screen displaying.

Stop script execution on the first error
If selected, script execution will be stopped when execution encounters the first error.

Show status bar
Determines whether status bar should be visible.

Open object editors in the same window
If selected, all new object editors will be opened "unpinned". That means, when opening a database object with already opened database object of the same type, object editor of already opened object will be replaced with object editor of the opening object. This option doesn't work with stored procedures and functions.

Open source objects in the same window
If selected, all new source object editors will be opened "unpinned". This option works with stored procedures and functions.

Display X items shown in Window menu
Customizes the number of windows that appear in the Windows list of the Window menu. Type a number between 1 and 24. By default, the number is 10.

Display X items shown in recently used lists
Customizes the number of most recently used projects and files that appear on the File menu. Type a number between 1 and 24. By default, the number is 10. This is an easy way to retrieve recently used projects and files.

ExpandedToggleIcon(9x12) See Also

Environment Options

Keyboard, Environment, Options Dialog Box


Keyboard, Environment, Options Dialog Box

The Keyboard page of the Options dialog box allows you to customize the keyboard scheme for the Data Compare for SQL Server. Use this option to set shortcut keys for frequently used commands or to establish your favorite binding for a particular command. To access this dialog box, select Options from the Tools menu and choosing the Keyboard page from the Environment folder.

ExpandedToggleIcon(9x12) Options

Keyboard mapping scheme
Lists the set of all available collections of shortcut keys:

· Embarcadero RAD Studio
· Microsoft Visual Studio
· Eclipse
· Quest Software SQL Navigator
· Quest Software Toad
· Oracle SQL Developer
· Microsoft SQL Server Management Studio

To load a specific scheme, select it from the list. When you are ready to leave the options dialog box, click OK.

Reset
Resets all shortcuts to the defaults of the selected keyboard mapping scheme.

Show commands containing
Specifies which command is selected and shows a list of all commands available in the Data Compare for SQL Server that contain the specified characters, or all commands if this edit box is empty. As you type a complete word, the result list displays all entries containing the typed word. For example, you can enter save, locate the command, File.Save, and see that the associated shortcut is CTRL+S.

Shortcut(s) for selected command
Lists mapped shortcuts for the command selected in the Show commands containing list. Some commands have more than one mapped shortcut.

Remove
Removes the selected shortcut key combination.

Use new shortcut in
Specifies the scope of the shortcut key. For example, you can use the shortcut key globally in the Data Compare for SQL Server or only within a specific context (or window); Global is the default setting. If you choose a specific context, the shortcut key remains in effect only while the context is active. If you choose Global, the shortcut key works in any active window in the Data Compare for SQL Server, unless the same shortcut is mapped in another editor, in which case the editor overrides the shortcut.

Press shortcut key(s)
Allows you to press a key combination to be used for the currently selected command. You must use one or more modifier keys such as CTRL, ALT, or SHIFT. The modifier keys appear in the order in which you press them. For example, pressing CRTL, then SHIFT, and then F2 creates the shortcut key, CTRL+SHIFT+F2. You can enter one or two key combinations that include a modifier key. For example, you can enter CTRL+Y, or enter CTRL+Y, CTRL+W. Use BACKSPACE to delete the whole shortcut key combination at one time.

note Note

The following keys cannot be assigned: ALT, SHIFT, or CTRL without another key; ESC, PRINT SCRN/SYS RQ, SCROLL LOCK, PAUSE/BREAK, TAB, CAPS LOCK, INSERT, HOME, END, PAGE UP, PAGE DOWN, Windows logo keys, Application key, any of the ARROW keys, or ENTER; NUM LOCK, DEL, or CLEAR on the numeric keypad; or CTRL+ALT+DELETE.

Assign
Binds the new key combination to the selected command in the Keyboard mapping scheme displayed. The new assignment is added to the Shortcut(s) for selected command list and you can specify multiple key combinations for one command. This button is active after you type a key combination in the Press shortcut key(s) box. If you attempt to bind a key in the [Default Settings] scheme, you are prompted to make a copy of the scheme and give it a name.

note Note

Changes made using the Assign button are not canceled if you click the Cancel button.

Shortcut currently used by
Displays the command to which the key combination is currently assigned. Appears only when you assign a key or key combination that is already assigned. To replace the shortcut with a custom shortcut key combination you must define a new Keyboard mapping scheme.

ExpandedToggleIcon(9x12) See Also

Environment Options

Output, Environment, Options Dialog Box


Output, Environment, Options Dialog Box

Use Options window to adjust Data Compare for SQL Server behavior to your needs. To access this dialog box, select Options from the Tools menu and choosing the Output page from the Environment folder.

ExpandedToggleIcon(9x12) Settings

Turn on 'Redirect Data to Output Window' by default
Enables displaying of selected data as text in the Output window instead of the Data view for every SQL document by default.

Show time for output events
If selected, the time stamp is added at the beginning of every line in the Output window.

ExpandedToggleIcon(9x12) SQL Log

Write queries sent by program to the SQL Log
Allows to log all the queries sent by program to a database.

ExpandedToggleIcon(9x12) Event Tracing

Log application errors
Check this option to write all errors and processes that took place during the application work to a file. This file is placed in the directory with the application executable file.

It can help a user to provide more detailed information on the encountered problem to the developers so that they are able to reproduce and fix the problem faster. If you have encountered an error and are going to send us an error report, this file will be attached to the letter with the error report.

Delete application log after closing
Clear this checkbox if you want the application log be available after application closing.

ExpandedToggleIcon(9x12) See Also

Environment Options

Documents, Environment, Options Dialog Box


Documents, Environment, Options Dialog Box

Use the Options window to adjust the Data Compare for SQL Server behavior to your needs.

ExpandedToggleIcon(9x12) In This Section

SQL Documents Dialog Box
Describes options available for SQL document view.

Categories
Displays the list of available document categories.

Restore
Use the topic to customize the automatic files saving.

ExpandedToggleIcon(9x12) See Also

Environment Options

Web Browser, Environment, Options Dialog Box


SQL Documents Dialog Box

The SQL Documents subsection of Environment Documents of the Options window contains the following options:

ExpandedToggleIcon(9x12) Default SQL Document View Layout

One main document view
All views corresponding to the opened SQL document are visible. You can activate the needed view by clicking the corresponding tabs.

All views tabbed
Only one view corresponding to the document is visible, all others are tabbed. Click the needed tab for the corresponding view to be shown on the screen.

note Note

You can also change the document view layout from the shortcut menu that can be called from the lower part of the document view.

Show Data view for every SQL document
Check this option for the Data view tab to be displayed for every opened or newly created SQL document.

Activate Data editor after query execution
Check this option to focus on the Data editor after a query is executed. If this option is unchecked, focus stays in the Text view.

Redirect data to Data window if Data view is closed
If this option is checked, data returned after query execution is displayed into the Data window if the Data view is closed.

ExpandedToggleIcon(9x12) See Also

Documents, Environment, Options Dialog Box

Environment Options


Categories

Displays the list of available document categories.

Name
Category name.

Shape
Category shape.

Color
Category color.

New Category
Adds a new category to the list.

Delete Category
Deletes a selected category.

Reset to Default
Resets all changes to defaults.

ExpandedToggleIcon(9x12) See Also

Documents, Environment, Options Dialog Box

Restore


Restore

Use the topic to customize the automatic files saving. It will allow you to return to the documents which you forgot to save during the last session.

Settings

Save restore information every ... min
Set the time after which the data will be saved automatically.

Restorable file types

SQL files (*.sql)
If checked, the *.sql files will be saved automatically.

Text files
If checked, the text files will be saved automatically.

XML files
If checked, the XML files will be saved automatically.

Data comparison files
If checked, the data comparison files will be saved automatically.

ExpandedToggleIcon(9x12) See Also

Documents, Environment, Options Dialog Box

Web Browser, Environment, Options Dialog Box


Web Browser, Environment, Options Dialog Box

Use the Options window to adjust Data Compare for SQL Server behavior to your needs. To access this dialog box, select Options from the Tools menu and choosing the Web Browser page from the Environment folder.

ExpandedToggleIcon(9x12) Settings

Home page
Set here a home page for Data Compare for SQL Server web browser. It opens when you call Data Compare for SQL Server web browser window or click Home button on Web toolbar.

Use default
Use the product home page.

Search page
Set here a search page for Data Compare for SQL Server web browser. It opens when you click Online Search button on Web toolbar.

Use default
Use Google as a search page.

ExpandedToggleIcon(9x12) See Also

Environment Options

Options


Text Editor Options

The Text Editor options in the Options dialog box provide a variety of ways to customize the performance and appearance of the editor.

ExpandedToggleIcon(9x12) In This Section

General, Text Editor, Options Dialog Box
This dialog box lets you change global settings for the Data Compare for SQL Server.

Tabs, Text Editor, Options Dialog Box
This dialog box allows you to change the default behavior of the Code Editor.

Font & Colors, Text Editor, Options Dialog Box
This dialog box allows you to change the default setting for a custom font and color scheme for various user interface elements.

Printing, Text Editor, Options Dialog Box
This dialog box allows you to change default printing options.

Advanced, Text Editor, Options Dialog Box
This dialog box describes how to set up tabulation and indenting editor preferences.

Code Completion
This section describes statement completion options available in Data Compare for SQL Server.

Formatting
This section describes code formatting options available in Data Compare for SQL Server.

ExpandedToggleIcon(9x12) See Also

Options

Data Editor Options


General, Text Editor, Options Dialog Box

This dialog box lets you change global settings for the Code and Text. To display this dialog box, click Options on the Tools menu, expand the Text Editor node, and then click General.

Settings

Virtual whitespace
When selected, it allows you to move the cursor beyond the physical end of a line of text into character spaces that do not exist. If you move your cursor out into this area and begin typing, the void between your current position and the end of the last word is automatically filled with space characters. When this setting is not selected, you cannot move the cursor beyond the last character in a line.

Bracket matching
If selected, dbForge Data Compare for SQL Server finds a corresponding bracket for the one that is currently near the cursor.

Display

Line numbers
Displays line numbers in the left of Text view of a document.

Indicator margin
Reveals the indicator margin on the left of Text view of a document.

Vertical scroll bar
Shows or hides a vertical scrollbar in Text view of a document.

Horizontal scrollbar
Shows or hides horizontal scrollbar in Text view of a document.
Navigation bar
Check this option to enable a navigation bar. It can be useful if you have a large amount of CREATE TABLE instances in your script and you need to navigate between columns and tables in it.
Hide if empty
Check this option to show navigation bar only when two or more objects are created. If only one object is created in a SQL statement the bar remains hidden as it is not needed.

ExpandedToggleIcon(9x12) See Also

Text Editor Options

Tabs, Text Editor, Options Dialog Box


Tabs, Text Editor, Options Dialog Box

This dialog box allows you to change the default behavior of the Code Editor. To display this dialog box, click Options on the Tools menu, expand the Text Editor node, and then click Tabs.

ExpandedToggleIcon(9x12) Indenting

None
When selected, no automatic indenting occurs when you press ENTER to move to a new line of text, and the cursor is placed at the first column of the next line.

Block
When selected and you press ENTER, the new line of text is automatically indented to the same tab stop as the line preceding it.

Smart
When selected, new lines of text are automatically indented taking into account selecting formatting options.

ExpandedToggleIcon(9x12) Tabs

Tab size
Sets the distance in spaces between tab stops. The default is 2 spaces.

Indent size
Sets the size in spaces of an automatic indentation. The default is 2 spaces. Tab characters, space characters, or both will be inserted to fill the specified size.

Insert spaces
When selected, indent operations insert only space characters, not TAB characters. If the Indent size is set to 5, for example, then five space characters are inserted whenever you press the TAB key or the Increase Indent button on the Formatting toolbar.

Keep tabs
When selected, indent operations insert as many TAB characters as possible. Each TAB character fills the number of spaces specified in Tab size. If the Indent size is not an even multiple of the Tab size, space characters are added to fill in the difference.

ExpandedToggleIcon(9x12) See Also

Text Editor Options

Font & Colors, Text Editor, Options Dialog Box


Font & Colors, Text Editor, Options Dialog Box

The Fonts and Colors page of the Options dialog box lets you establish a custom font and color scheme for various user interface elements in the Data Compare for SQL Server. To access this dialog box, click Options on the Tools menu, and then select the Font &Colors page in the Text Editor folder.

Options

Font (bold type indicates fixed-width fonts)
Lists all the fonts installed on your system. Fixed fonts appear in bold.

Size
Specify the size of the font for the selected display item here.

Use Defaults
Resets text editor font and color settings to the default values.

Display items
Select a display item here to change its font and color settings.

Brace Matching
Matching braces, for example ().
Built-in Data Type
Built-in data type, for example, INT or VARCHAR.
Built-in Function
Built-in function, for example, COUNT.
Call Return
Source statement that indicates call return points when context is switched to a non-top stack frame when debugging.
Comment
Code comment.
Current Statement
Current code line when debugging.
Identifier
Identifier, such as database object name, stored procedure parameter, etc.
Keyword
SQL keyword.
Number
Number.
Operator
Operators and separators (, ;: * + = / - . (<>!~&^%\|{})).
Plain Text
Text, when editing a file as text.
Program Block Label
Labels.
Region
Region or endregion command.
Select Marker
Frame around the select statements.
Selected Line
Line, selected in the Find Results window.
String
SQL string constant.
Visible Whitespace
White space characters when View White Space is turned on.
XML Attribute Name
Tag attribute in XML editor.
XML Comment
Comment in XML editor.
XML Indent
Indent in XML editor.
XML Number
Number in XML editor.
XML Special Tag
Special XML tag.
XML String
String constant in XML editor.
XML Tag Name
XML attribute name.

Bold
Select it to display the text of selected display items in bold.

Italic
Select it to display the text of selected display items in italic.

Item foreground
Font color of a selected display item.

Item background
Background color of a selected display item.

Sample
Sample of a display item appearance.

ExpandedToggleIcon(9x12) See Also

Text Editor Options

Printing, Text Editor, Options Dialog Box


Printing, Text Editor, Options Dialog Box

This dialog box allows you to change default printing options. To access this dialog box, click Options on the Tools menu, and then select the Printing page in the Text Editor folder.

ExpandedToggleIcon(9x12) Settings

Print header
Check it to print the document name.

Print line numbers
Check it to print line numbers in the document.

Print white space
Check it to print white space symbols, tabulation symbols, and symbols of line breaks.

ExpandedToggleIcon(9x12) See Also

Text Editor Options

Advanced, Text Editor Options Dialog Box


Advanced, Text Editor, Options Dialog Box

Use the Options window to adjust Data Compare for SQL Server behavior to your needs. To open it, select Options from the Tools menu.

The Advanced section of the Text Editor options allows you to setup outlining and SELECT statement highlighting. You can use the following options:

ExpandedToggleIcon(9x12) Outlining

Enter outlining mode when files open
If selected, outlining is enabled when you open a file.

Collapse --region blocks when files open
If selected, --region blocks in an opened file will be collapsed.

ExpandedToggleIcon(9x12) Syntax highlighting

Highlight SELECT statements
If selected, a frame will be drawn around SELECT statements.

Underline errors in the editor
If selected, syntax errors will be underlined with a red curved line.

ExpandedToggleIcon(9x12) Editor performance

Enable syntax highlight
Clear a check box to disable syntax highlight.

Max script size
Specify max script size for syntax highlight support.

Max script size
Specify max script size for code completion, navigation and refactoring support.

ExpandedToggleIcon(9x12) See Also

Text Editor Options

Code Completion Options


Code Completion Options

Code Completion

This section explains statement completion options provided in the Options window.

The Code Completion section of the Text Editor options contains the following subsections:

ExpandedToggleIcon(9x12) In This Section

General, Code Completion Text Editor Options Dialog Box
Lists general code completion preferences and explains them.

Advanced, Code Completion Text Editor Options Dialog Box
Describes advanced code completion options.

List Members, Code Completion Text Editor Options Dialog Box
Describes options for list members.

ExpandedToggleIcon(9x12) See Also

Text Editor Options

Formatting


General, Code Completion Text Editor Options Dialog Box

Use the Options window to adjust Data Compare for SQL Server behavior to your needs. To open it, select Options from the Tools menu.

The General subsection of the Code Completion section of the Text Editor options allows you to setup options for automatic code formatting when typing code. Use the following options:

Enable Code Completion
Select to toggle automatic code completion. Selected by default.

Auto-list members
Toggles the display of valid databases, tables, columns, and other database objects in the suggestion box when you are typing. Selected by default.

Auto Parameter Info
Toggles the display of the Parameter Info hint when the left bracket is typed after the procedure or object method name. Selected by default.

Automatically trigger after ... millisec
Defines a delay used by dbForge SQL Complete to show the suggestion box after you stop typing. To change the default value, use the arrow buttons in the field or enter the value.

Highlight Occurrences
Toggles identifier occurrence highlighting.

ExpandedToggleIcon(9x12) See Also

Code Completion Options

Advanced, Code Completion Text Editor Options


Advanced, Code Completion Text Editor Options

Use the Options window to adjust Data Compare for SQL Server behavior to your needs. To open it, select Options from the Tools menu.

The Advanced subsection of the Code Completion section of the Text Editor options allows you to setup options for automatic code completion when typing code. The following options are available:

Qualify column name with table alias
Defines that column names should be committed with table alias.

Qualify column name (no table alias)
Defines how column names should be committed.

With table name
The name of the table the column belongs to is specified before the column name: TableName.ColumnName.
With schema name and table name
The name of the table the column belongs to and the schema name are specified before the column name: SchemaName.TableName.ColumnName.

Reverse order in 'JOIN'-condition
Applies reverse order in JOIN conditions.

Add parentheses when inserting a function
If the option is checked, parentheses are added when you insert functions.

Quote identifiers
Choose the way of identifying a quote here.

Always
If the option is enabled, all the identifiers, aliases, and database objects will be enclosed in parentheses.
If an identifier concurs with a keyword
If the option is enabled, all the identifiers, aliases, and database objects will be enclosed in parentheses, in case their names concur with reserved keywords or system objects.
If quotes are required
If the option is enabled, all the identifiers, aliases, and database objects will be enclosed in parentheses, if required. For instance, if a column name is declared with white spaces.

ExpandedToggleIcon(9x12) See Also

Code Completion Options

List Members, Code Completion Text Editor Options


List Members, Code Completion Text Editor Options

Use the Options window to adjust Data Compare for SQL Server behavior to your needs. To open it, select Options from the Tools menu.

The List Members subsection of the Code Completion section of the Text Editor options allows you to setup options for automatic code completion when typing code. The following options are available:

ExpandedToggleIcon(9x12) Settings

Sort keywords by relevance
When selected, keywords in the suggestion box will be sorted to display the most relevant at the top of the list. It is selected by default.

ExpandedToggleIcon(9x12) Filtering Rule

These options define how to filter the list of suggestions in the suggestion box. If neither of them is selected, Data Compare for SQL Server will display only suggestions that start with the typed character(s).

By Matching
When selected, Data Compare for SQL Server filters the list of suggestions to display those that start with the typed character(s) or contain it in the top of the list.

Camel Case
When selected, Data Compare for SQL Server filters the list of suggestions to display those that are compound word which elements are joined without spaces and start with the typed characters.

ExpandedToggleIcon(9x12) Commit selection in completion list by typing

When you type any of the symbols specified below, Data Compare for SQL Server will insert a highlighted suggestion from the suggestion box into code.

Tab
The highlighted suggestion will be inserted when you press the TAB key.

Whitespace
The highlighted suggestion will be inserted when you press the SPACE key.

Following characters:
Enter characters here, and the highlighted suggestion will be inserted when you type any of the specified characters.

Add new line on enter at end of fully typed word
Cursor will be moved to the new line if you type a word completely and press ENTER.

ExpandedToggleIcon(9x12) See Also

Code Completion Options


Formatting

This section explains code formatting options provided in the Options window. The Formatting section of the Text Editor options contains the following subsections:

ExpandedToggleIcon(9x12) In This Section

General, Formatting, Text Editor Options Dialog Box
Lists general code formatting preferences and explains them.

Profiles, Formatting, Text Editor Options Dialog Box
Describes options to customize case formatting profiles.

ExpandedToggleIcon(9x12) See Also

Text Editor Options

Data Editor Options


General, Formatting, Text Editor Options Dialog Box

Use the Options window to adjust Data Compare for SQL Server behavior to your needs. To open it, select Options from the Tools menu, expand the Text Editor node, and in the Formatting node click General.

ExpandedToggleIcon(9x12) Settings

The General subsection of the Text Editor Formatting section allows you to setup options for automatic code formatting when typing code. You can use the following options:

Automatically format on paste
If checked, pasted code will be automatically formatted. Selected by default.

Automatically format completed statement on delimiter
If checked, code will be automatically formatted when the delimiter is entered (semicolon or backslash). Selected by default.

Automatically format while typing
If the option is checked, code formatting while typing statement elements in SQL editor is supported. Start typing first letters for the required statement, and press TAB or a space to see the result. All objects and keywords are formatted in correspondence with formatting active profile settings. By default, the option is selected.

Right Margin
Line breaks will be inserted automatically after the Right Margin number of characters on a line. 80 is by default.

Put syntax errors to Output window
Select it if you want syntax errors to be redirected to the Output window.

Show syntax error notification window
Select it if you want the syntax error notification window to appear upon formatting a document.

Dictionary file
Specify file with dictionary to adjust formatting to your needs. You can use default dictionary or create a new one. Also you can modify the existing dictionary. This dictionary is used to format identifiers when the Text Case -> Identifier Case option is set to Initial Caps each word.

Available prefixes
Specify prefixes here. If one of the prefixes is used in a word, the application looks in the dictionary for the word that is used after the prefix. If the word is found, its first letter is written in uppercase. These prefixes can be used to format identifiers when the Text Case -> Identifier Case option is set to Initial Caps each word.

Reset Page Defaults
Resets all options on this page to their default values.

ExpandedToggleIcon(9x12) See Also

Formatting

Text Editor Options


Profiles, Formatting, Text Editor Options Dialog Box

Use the Profiles option to customize code formatting provided by Data Compare for SQL Server. To access it, go to Tools menu, select Options, and then click Text Editor. Navigating to Formatting, click Profiles.

ExpandedToggleIcon(9x12) Formatting Profiles

Select a profile from the table.

Name
Profile name.

File
Profile file name.

Edit Profile...
Opens the Edit Profile Options window that allows editing options available in the profile.

New Profile...
Opens the New Profile window to create a new formatting profile.

Activate
Click to activate the selected profile.

Show in Folder
Opens folder containing the selected profile.

ExpandedToggleIcon(9x12) Context Menu

Edit Profile
Click to open the Edit Profile window.

Reset To Defaults
Click to reset settings to the default values.

Activate
Activates the selected profile.

Rename
Click to change the profile name.

Show In Folder
Opens folder containing the file in Windows Explorer.

Copy File Path
Copies file path to the clipboard.

Delete
Click to delete selected formatting profile.

ExpandedToggleIcon(9x12) See Also

Formatting

Text Editor Options


Edit Profile, Formatting Options

Use this window to edit formatting options in the selected formatting profile.

ExpandedToggleIcon(9x12) Edit Profile Window

Filter
Allows to quick search the needed options/option groups.

collapse-all Collapse/Expand all option groups
Click to expand/collapse the option groups tree.

Show white spaces button
Click to toggle white spaces in the formatting profile editor.

Show Original Sample
Click to restore the code sample to its original state.

Format Text
Formats code according to the selected options.

Options tree
Includes various code formatting options. Allows customizing default text formatting options the way user likes.

Code field
Shows how the code looks like after choosing the corresponding text formatting options.

ExpandedToggleIcon(9x12) Edit Profile Context Menu

Format Selection
Formats selected code according to the chosen options.

Cut
Cuts selected text and places it to the clipboard.

Copy
Copies selected text to the clipboard.

Paste
Pastes the clipboard content into the cursor position.

ExpandedToggleIcon(9x12) See Also

Profiles, Formatting, Text Editor Options Dialog Box

New Profile, Formatting Options


New Profile, Formatting Options

Use this window to create and add new formatting profile to the list of profiles.

ExpandedToggleIcon(9x12) New Profile Window

Name
Specify the new profile name here.

Copy settings from
Select an existing profile to copy settings from.

File Path
Set the path to save your new formatting profile.

Set Active
Activate this profile in the Profiles, Options Dialog Box.

ExpandedToggleIcon(9x12) See Also

Profiles, Formatting, Text Editor Options Dialog Box

Data Editor Options


Query Execution Options

The Query Execution options in the Options dialog box provide a variety of ways to customize the performance of query execution.

ExpandedToggleIcon(9x12) In This Section

General, Query Execution, Options Dialog Box
Use the Options window to adjust the query execution to your needs.

ExpandedToggleIcon(9x12) See Also

Options

Data Editor Options


General, Query Execution, Options Dialog Box

Use the Options window to adjust the query exectution behavior to your needs. To access this dialog box, select Options from the Tools menu and choosing the General page from the Query Execution folder.

The Query Execution General section of the Options window contains the following options:

ExpandedToggleIcon(9x12) General

ROWCOUNT
Causes SQL Server to stop processing the qurey after the specified number of rows are returned.

TEXTSIZE
Specifies the size of varchar (max), varbinary (max), text, ntext and image data returned by a SELECT statement.

ExpandedToggleIcon(9x12) Advanced

ARITHABORT
Select it to terminate a query when an overflow or divide-zero error occurs during query execution.

CONTACT_NULL_YIELDS_NULL
Controls whether concatenation results are treated as null or as empty string values.

DEADLOCK_PRIORITY
Specifies the relative importance that the current session continue processing if it is deadlocked with another session.

LOCK_TIMEOUT
Specifies the number of milliseconds a statement waits for a lock to be released. A value of -1 (default) indicates no time-out period (that is, wait forever). When a wait for a lock exceeds the time-out value, an error is returned. A value of 0 means to not wait at all and return a message as soon, as a lock is encountered.

NOCOUNT
Stops the message that shows the count of the number of rows affected by a Transact-SQL statement or stored procedure form being returned as a part of the result set.

NOEXEC
Complies each query, but does not execute it.

PARSEONLY
Examines the syntax of each Transact-SQL statement and returnes any error messages without compiling or executing the statement.

QUERY_GOVERNOR_COST_LIMIT
Overrides the currently configured query governor cost limit value for the current connection. Specifying 0 (the default) for this option turns off the query governor, and all queries are allowed to run indefinitely. The query governor disallows exectution of any query that has an estimated cost exceeding that value.

SHOWPLAN_TEXT
Causes Microsoft SQL Server not to execute Transact-SQL statements. Instead, SQL Server returns detailed information about how the statements are executed.

STATISTICS IO
Causes SQL Server to display information regarding the amount of disk activity generated by Transact-SQL statements.

STATISTICS TIME
Displays the number of milliseconds required to parse, compile and execute each statement.

TRANSACTION ISOLATION LEVEL
Controls the locking and row versioning behavior of Transact-SQL statements issued by a connection to SQL Server.

ExpandedToggleIcon(9x12) ANSI

ANSI_NULL_DFLT_ON
Modifies the behavior of the session to override default nullability of new columns when the ANSI null default option for the database is false.

ANSI_NULLS
Specifies ISO compliant behavior of the Equals (=) and Not Equal To (<>) comparison operators when they are used with null values in SQL Server.

ANSI_PADDING
Controls the way the column stores values shorter, than the defined size of the column, and the way the column stores values that have trailing blanks in char, varchar, binary and varbinary data.

ANSI_WARNINGS
Specifies ISO standard behavior for several error conditions.

CURSOR_CLOSE_ON_COMMIT
Controls the behavior of the Tranasact-SQL COMMIT TRANSACTION statement. The default value for this settign is OFF. This means that the sevrver will not close cursors when you commit a transaction.

IMPLICIT_TRANSACTIONS
Sets implicit transaction mode for the connection.

QUOTED IDENTIFIER
Causes SQL Server to follow the ISO rules regarding the quotation mark delimiting identifiers and literal strings. Identifiers delimited by double quotation marks can be either Transact-SQL reserved keywords or can contain characters not generally allowed by the Transact-SQL syntax rules for identifiers.

ExpandedToggleIcon(9x12) Other

Reset to Default
Click to reset options on this page to their default values.

ExpandedToggleIcon(9x12) See Also

Query Execution Options

Options


Data Editor Options

The Data Editor options in the Options dialog box provide a variety of ways to customize the performance and appearance of the editor.

ExpandedToggleIcon(9x12) In This Section

General, Data Editor, Options Dialog Box
Use the Options window to adjust the products behavior to your needs.

Font & Colors, Data Editor, Options Dialog Box
The Fonts and Colors page of the Options dialog box lets you establish a custom font and color scheme for Data Editor.

Printing, Data Editor, Options Dialog Box
This dialog box allows you to change default printing options.

Formatting, Data Editor, Options Dialog Box
Use the Options window to adjust the products behavior to your needs.

ExpandedToggleIcon(9x12) See Also

Options

Data Comparison Options


General, Data Editor, Options Dialog Box

Use the Options window to adjust the products behavior to your needs. To access this dialog box, select Options from the Tools menu and choosing the General page from the Data Editor folder.

The Data Editor General section of the Options window contains the following options:

ExpandedToggleIcon(9x12) Settings

Automatically adjust column width
Automatically adjusts column width for every data grid.

Use cached updates mode by default
If selected, cached updates mode will be enabled by default in data view of every SQL document created.

Use paginal mode by default
If selected, paginal mode will be enabled by default in data view of every SQL document created.

Initial page size
Default page record count for paginal mode for data view.

Use auto-search mode by default
Activates auto-search in Data view by default.

Show row numbers
Adds a column with row numbers (#) to the data editor grid.

ExpandedToggleIcon(9x12) Data Editing

Open Data Editor in the editing mode
Select to open the Data Editor is opened in the editing mode by default.

Open Data Editor in the read-only mode
Select to open the Data Editor is opened in the read-only mode by default.

Show a dialog window to choose a mode
Select to invoke a dialog window asking to choose the mode in which Data Editor should be opened (editing or read-only).

ExpandedToggleIcon(9x12) See Also

Data Editor

Font & Colors, Data Editor, Options Dialog Box


Font & Colors, Data Editor, Options Dialog Box

The Fonts and Colors page of the Options dialog box lets you establish a custom font and color scheme for Data Editor. You can access this dialog box by clicking Options on the Tools menu, and then selecting the Font &Colors page in the Data Editor folder.

ExpandedToggleIcon(9x12) Options

Data Editor Font & Colors section of the Options window contains the following options:

Font
Select a font for the selected display item here.

Size
Specify a font size for the selected display item here.

Use Defaults
Click this button to reset specified font and color settings to the default values.

Display item
Select a display item here to change its background and foreground color settings.

Item foreground
Select a font color for the selected display item.

Item background
Select a background color for the selected display item.

Sample
Preview the display item appearance here.

ExpandedToggleIcon(9x12) See Also

Data Editor

Printing, Data Editor, Options Dialog Box


Printing, Data Editor, Options Dialog Box

This dialog box allows you to change default printing options. You can access this dialog box by clicking Options on the Tools menu, and then selecting the Printing page in the Data Editor folder.

ExpandedToggleIcon(9x12) General

Auto width
Select to fit the printed data to the page width.

ExpandedToggleIcon(9x12) Grid

Print horizontal lines
Select to print grid horizontal lines.

Print vertical lines
Select to print grid vertical lines.

ExpandedToggleIcon(9x12) Card

Print card captions
Select to prints card captions.

Print empty fields
Select to prints card empty fields.

ExpandedToggleIcon(9x12) See Also

Data Editor

Formatting, Data Editor, Options Dialog Box


Formatting, Data Editor, Options Dialog Box

Use the Options window to adjust the products behavior to your needs. You can access this dialog box by clicking Options on the Tools menu, and then selecting the Formatting page in the Data Editor folder.

ExpandedToggleIcon(9x12) DateTime Format

Data type
Select either Date or DateTime format here.

Edit format
Set the datetime format here. It can be one of the predefined formats or custom format. Predefined formats are described below. The following table contains all available format specifiers and their description.

Format Specifier

Description

d

A placeholder for the day of the month. If the day is a single digit only (1-9), then it's displayed as a single digit.

Note that if the 'd' specifier is used alone, without other custom specifiers, it's interpreted as the standard mask (short date pattern). If the 'd' specifier is passed with other custom specifiers or the '%' character, it's interpreted as a custom mask specifier.

dd

A placeholder for the day of the month. If the day is a single digit only (1-9), it is formatted with a preceding 0 (01-09).

ddd

Displays the abbreviated name of the current day.

The value represented by this specifier cannot be edited.

dddd (plus any number of additional "d" characters)

Displays the full name of the current day.

The value represented by this specifier cannot be edited.

f

A placeholder for seconds fractions represented in one digit.

Note that if the 'f' specifier is used alone without other custom specifiers, it's interpreted as the standard mask (full date/time pattern ). If the 'f' specifier is passed with other custom specifiers or the '%' character, it's interpreted as a custom mask specifier.

ff

A placeholder for seconds fractions represented in two digits.

fff

A placeholder for seconds fractions represented in three digits.

ffff

Displays seconds fractions represented in four digits.

The value represented by this specifier cannot be edited.

fffff

Displays seconds fractions represented in five digits.

The value represented by this specifier cannot be edited.

ffffff

Displays seconds fractions represented in six digits.

The value represented by this specifier cannot be edited.

fffffff

Displays seconds fractions represented in seven digits.

The value represented by this specifier cannot be edited.

g

Displays the era (A.D. for example) for the current date/time value.

The value represented by this specifier cannot be edited.

h

A placeholder for the hour part of the date/time value in the range 1-12.

hh

A placeholder for the hour part of the date/time value in the range 1-12. This pattern inserts two placeholders to enter a value. If a single digit is entered it is preceded with a '0'.

H

A placeholder for the hour part of the date/time value in the range 0-23.

HH

A placeholder for the hour part of the date/time value in the range 0-23. This pattern inserts two placeholders to enter a value. If a single digit is entered it is preceded with a '0'.

m

A placeholder for the minutes of the date/time value in the range 0-59.

mm

A placeholder for the minutes of the date/time value in the range 0-59. This pattern inserts two placeholders to enter a value. If a single digit is entered it is preceded with a '0'.

M

A placeholder for the month in this position, measured as a number in the range 1-12.

MM

A placeholder for the month in this position, measured as a number in the range 1-12. This pattern inserts two placeholders to enter a value. If a single digit is entered it is preceded with a '0'.

MMM

A placeholder for the abbreviated name of the month.

MMMM

A placeholder for the full name of the month.

s

A placeholder for the seconds part of the date/time value in the range 0-59.

Note that if the 's' specifier is used alone without other custom specifiers it's interpreted as the standard mask (sortable date/time pattern). If the 's' specifier is passed with other custom specifiers or the '%' character, it's interpreted as a custom mask specifier.

ss

A placeholder for the seconds part of the date/time value in the range 0-59. This pattern inserts two placeholders to enter a value. If a single digit is entered it's preceded with a '0'.

t

A placeholder for the first character of the A.M./P.M. designator of the date/time value.

Note that if the 't' specifier is used alone without other custom specifiers it's interpreted as the standard mask (short time pattern). If the 't' specifier is passed with other custom specifiers or the '%' character, it's interpreted as a custom mask specifier.

tt

A placeholder for the A.M./P.M. designator of the date/time value.

y

A placeholder for entering the last two digits of the year of the date/time value.

Note that if the 'y' specifier is used alone without other custom specifiers, it's interpreted as the standard mask (year month pattern). If the 'y' specifier is passed with other custom specifiers or the '%' character it's interpreted as a custom mask specifier.

yy

A placeholder for entering the last two digits of the year of the date/time value. This pattern inserts two placeholders to enter a value. If a single digit is entered it is preceded with a '0'.

yyyy

A placeholder for entering the year part of the date/time value including the century.

z

Displays the time zone offset for the system's current time zone in whole hours only. The offset is always displayed with a leading sign (zero is displayed as "+0"), indicating how many hours ahead of Greenwich mean time (+) or hours behind Greenwich mean time (-) the current time zone is. The range of values is -12 to +13. If the offset is a single digit (0-9), it's displayed as a single digit with an appropriate leading sign.

The value represented by this specifier cannot be edited.

zz

Displays the time zone offset for the system's current time zone in whole hours only. The offset is always displayed with a leading or trailing sign (zero is displayed as "+00"), indicating how many hours ahead of Greenwich mean time (+) or hours behind Greenwich mean time (-) the current time zone is. The range of values is -12 to +13. If the offset is a single digit (0-9), it's formatted with a preceding 0 (01-09) with an appropriate leading sign.

The value represented by this specifier cannot be edited.

zzz

Displays the time zone offset for the system's current time zone in hours and minutes. The offset is always displayed with a leading or trailing sign (zero is displayed as "+00:00"), indicating how many hours ahead of Greenwich mean time (+) or hours behind Greenwich mean time (-) the current time zone is. The range of values is -12:00 to +13:00. If the offset is a single digit (0-9), it's formatted with a preceding 0 (01-09) with an appropriate leading sign.

The value represented by this specifier cannot be edited.

:

Time separator.

/

Date separator. The actual date separator is determined by the DateTimeFormatInfo.DateSeparator property of the current culture.

"abc" or 'abc'

Quoted string. Inserts the string enclosed with single or double quotes literally to the edit box. The string cannot be edited.

%c

Where c is one of the standard mask specifiers, makes the specifier be interpreted as a custom mask specifier.

Note that if a mask specifier is used alone as a single character, it's interpreted as a standard mask specifier. Only mask specifiers consisting of two or more characters are interpreted as custom specifiers. In order to use a custom specifier on its own which matches one of the standard specifiers it should be preceded with the % character.

\c

The backslash is used as the escape character. It inserts the following character literally to the edit box.

Any other characters.

The other characters are inserted to the edit box literally.

ExpandedToggleIcon(9x12) Predefined Formats

You can choose one of the predefined datetime formats here. The following table contains their descriptions and samples.

Standard Mask | Name | Sample. Culture: English (USA)
d | Short date | 8/20/2007
D | Long date | Monday, August 20, 2007
t | Short time | 10:23 AM
T | Long time | 10:23:35 AM
f | Full date/time (short time) | Monday, August 20, 2007 10:23 AM
F | Full date/time (long time) | Monday, August 20, 2007 10:23:35 AM
g | General date/time (short time) | 8/20/2007 10:23 AM
G | General date/time (long time) | 8/20/2007 10:23:35 AM
M or m | Month day | August 20
R or r | RFC1123 | Mon, 20 Aug 2007 10:23:35 GMT
s | Sortable date/time | 2007-08-20T10:23:35
u | Universal sortable date/time | 2007-08-20 10:23:35Z
Y or y | Year month | August, 2007

ExpandedToggleIcon(9x12) See Also

Data Editor

Options


Data Comparison Options

ExpandedToggleIcon(9x12) In This Section

General, Data Comparison, Options Dialog Box
This dialog box allows you to change the default behavior of the Data Comparison.

Synchronization, Data Comparison, Options Dialog Box
Choose the editor where to open the synchronization script in.

ExpandedToggleIcon(9x12) See Also

Options


General, Data Comparison, Options Dialog Box

This dialog box lets you change global settings for the Data Comparison. To display this dialog box, click Options on the Tools menu, expand the Data Comparison node, and then click General.

ExpandedToggleIcon(9x12) Settings

The Data Comparison General section of the Options window contains the following options:

Cache Folder
Allows selecting a directory to store temporary data needed during the comparison process.

Windows Temporary Folder
Check to store temporary files to the windows temporary folder.

Custom Folder
Check this option to store temporary files in a custom folder. To choose a folder, click the Browse... button.

ExpandedToggleIcon(9x12) See Also

Data Comparison

Options


Synchronization, Data Comparison, Options Dialog Box

Choose the editor where to open the synchronization script in.

SQL Editor

Internal
Synchronization script will be opened in the internal dbForge Data Compare for SQL Server editor.

Microsoft SQL Server Management Studio 2005
Synchronization script will be opened in the Microsoft SQL Server Management Studio 2005 editor.

Microsoft SQL Server Management Studio 2008
Synchronization script will be opened in the Microsoft SQL Server Management Studio 2008 editor.

Microsoft SQL Server Management Studio 2012
Synchronization script will be opened in the Microsoft SQL Server Management Studio 2012 editor.

ExpandedToggleIcon(9x12) See Also

Data Comparison Options

General, Data Comparison, Options Dialog Box


Service Windows

This section describes user interface elements of service windows and dialogs.

ExpandedToggleIcon(9x12) In This Section

Error List
The topic describes the Error List that helps you speed application development.

Output Window
The topic describes the Output window that displays status messages for various features.

Edit Value Dialog Box
The topic describes the Edit Value dialog box.

Save of Read-Only File Dialog Box
The topic describes the Save Prompt dialog box.

Save Prompt Dialog Box
The topic describes the Save of Read-Only File dialog box.

Windows Dialog Box
This topic describes the dialog box that allows you to display, close, and arrange documents that are open in editors and designers.

Product Update Manager
This topic describes the dialog box that allows you to see the update information of dbForge Data Compare for SQL Server.


Error List

The Error List contains errors, warnings, and messages with their location. To display the Error List, click the Error List button in the View menu. You can double-click error messages to locate errors quickly in multiple files.

The Error List window allows you to:

· Display the Errors, Warnings, and Messages produced as you edit and compile code.
· Find syntax errors
· Double-click any error message entry to open the file where the problem occurs, and move to the error location.
· Filter which entries are displayed, and which columns of information appear for each entry.

ExpandedToggleIcon(9x12) Error List Columns

Icon
Displays error or warning icon for the message.

Description
Display text of error or warning.

Location
Contains name of the document where the error occurred.

Line
Displays the line in the document, where the problem occurs.

Column
Shows the column on the indicated line where the problem begins.

ExpandedToggleIcon(9x12) Error List Shortcut Menu Commands

Goto Error
Opens the document on the place, where the error have occurred.

Copy
Copies the message to the clipboard.

Word Wrap
Enables or disables word wrap in the Description column of Error List.

Clear All
Clears Error List.

ExpandedToggleIcon(9x12) Error List Toolbar

Use the Errors, Warnings, and Messages buttons to select which entries to display.

Errors
Indicates the number of errors in the list. Click to toggle whether errors are displayed.

Warnings
Indicates the number of warnings in the list. Click to toggle whether warnings are displayed.

Messages
Indicates the number of messages in the list. Click to toggle whether messages are displayed.

In Active Document
Allows to review the errors, warnings, and messages either in the current document or in other opened documents.

ExpandedToggleIcon(9x12) See Also

Service Windows

Output Window


Output Window

This window can display status messages for various features. To display the Output window, select Output from the View menu.

Output messages can be divided into several categories. To view messages of the certain category click on its name on the Output window toolbar. If there is no such a name on the toolbar, right-click on the toolbar and select a required name from the shortcut menu.

General
Displays message statuses on general operations.

SQL Log
Displays all SQL queries executed by the application during the current session.

ExpandedToggleIcon(9x12) See Also

Service Windows

Properties Window


Edit Value Dialog Box

Use this dialog box to enter the option value. This dialog can be opened by clicking the button button for corresponding option.

ExpandedToggleIcon(9x12) See Also

Service Windows

Save of Read-Only File Dialog Box


Save of Read-Only File Dialog Box

When an attempt is made to save a read-only file, Save of Read-Only File dialog box appears. It contains following buttons.

Save As
Click to save the file to a different location.

Overwrite
Click to remove file's read-only attribute and replace original file with the changed one.

Cancel
Click to cancel save operation.

ExpandedToggleIcon(9x12) See Also

Service Windows

Save Prompt Dialog Box


Save Prompt Dialog Box

When an attempt is made to close a document or project that is modified and not saved, Save Prompt dialog box appears. It comprises of list, containing modified project and documents, and buttons you can use to proceed. Documents are grouped by project and miscellaneous files.

Yes
Click Yes button to save selected documents and project. If a document is not implicitly named, a Save dialog will appear where you can give a name to the document.

No
Click No to discard all changes made to the documents you are closing.

Cancel
Click Cancel button to return to IDE without closing any of the documents.

ExpandedToggleIcon(9x12) See Also

Service Windows

Windows Dialog Box


Windows Dialog Box

Use this dialog box to activate, save, and close documents. To access this dialog box, in the Window menu, click Windows. Note that you must have at least one document open for this option to be available.

The Windows dialog box allows you to manipulate several documents at single click. The dialog is not closed when you apply any actions, so it is extremely useful when you have many documents currently open.

Windows list
All documents currently open are enumerated in the list. Click on a document's line to select or deselect it. Use Ctrl and Shift keys to perform group operations.

Activate
Click this button to view the selected document without closing the dialog. Available only when single document is selected in the list.

Save
Save selected documents.

Close Window(s)
Close selected documents. If some are not saved, a dialog appears where you can save them if you need.

Close
Close the current dialog.

ExpandedToggleIcon(9x12) See Also

Service Windows

Product Update Manager


Product Update Manager

Use this dialog to see the update information of dbForge Data Compare for SQL Server.

To open the Product Update Manager dialog window, click the Check for Updates button in the Help menu.

To make Data Compare for SQL Server check for updates automatically:

1. In the Tools menu, click Options.
2. Expand the Environment folder in the Options window.
3. Check the Check updates on startup once a week check box.

The Product Update Manager window contains the following details:

Product information
This section shows the product's name, version, and file size.

Refresh
Click it to update the product information.

View revision history
Click it to view the history file of dbForge Data Compare for SQL Server.

Devart authentication
Contains the Login, and the Password text boxes. Allows registered users to pre-save the login credentials.

Save downloaded installation
Check it if you want to save an installation file. Then you should specify the file location in the File name field.

File name
Enter the location of the installation file or click the Browse button to select it in the Browse for Folder dialog.

Browse
Click it to select the installation file location in the Browse for Folder dialog.

Just download a file (do not start installation)
Select it to download the installation file without starting it.

Update
Click it to start downloading the installation file.

Cancel
Click it to close the dialog. Note, this won't stop installation download. To stop downloading, close dbForge Data Compare for SQL Server.

ExpandedToggleIcon(9x12) See Also

Service Windows

Reference


Shortcut Keys

Several pre-defined keyboard shortcut collections are included in Data Compare for SQL Server. All shortcuts can be customized.

ExpandedToggleIcon(9x12) Global Shortcut Keys

The following shortcut key combinations can be used in any Data Compare for SQL Server document or tool window.

Icon | Command Name | Shortcut Keys | Description | Where is used
 | Output | Ctrl+W, O | Reveal the Output window | Global
 | Error List | Ctrl+W, E | Reveal Error List window | Global
 | Data Viewer | Ctrl+W, R | Reveal Data Viewer window | Global
 | Web Browser | Ctrl+W, W | Reveal Web Browser | Global
 | New Connection | Ctrl+D, N | Show Database Connection Properties dialog box for a new connection | Global
 |  | Ctrl+PLUS (+) KEY | Zoom font size in | Global
 |  | Ctrl+MINUS (-) KEY | Zoom font size out | Global
 |  | Ctrl+0 | Reset font size to the default value | Global
 |  | F1 | Show help about current window | Global

ExpandedToggleIcon(9x12) Document Management Shortcut Keys

These are default shortcuts. All shortcuts can be customized.

Icon | Command Name | Shortcut Keys | Action | Where is used
 |  | Ctrl+Tab | Switch to last used document | Global
 |  | Ctrl+Shift+Tab | Cycle through all open documents | Global
 |  | F7 | Cycle through document views | Global
 |  | Shift+F7 | Cycle through document views backwards | Global
Save | Save | Ctrl+S | Save current document | Global
SaveAll | Save All | Ctrl+Shift+S | Save all documents | Global
 | Open | Ctrl+O | Open document | Global
 | Close Document | Ctrl+F4 | Close current document | Global
new-sql-window | New SQL | Ctrl+N | New SQL document | Global
Print | Print | Ctrl+P | Print | Text or data view of a document Data window

ExpandedToggleIcon(9x12) See Also

Reference


SQL Document

This section describes Query Editor user interface elements.

ExpandedToggleIcon(9x12) In This Section

SQL Editor Window
This topic describes the SQL document window interface elements.

Edit Parameters Dialog Box
This topic describes content of dialog box where you can edit query parameters.


SQL Editor

The SQL editor is a word processing utility where you enter and edit SQL statements. The statements are colorized so you can easily read them.

You can open multiple SQL editors to view SQL code and copy and paste among them. A list of all open SQL editors is available in the Windows menu.

Every Data Compare for SQL Server document has Text View that is shown in SQL editor. You can use SQL History to speed up your work. To learn how to use SQL Editor features, see the Writing and Executing SQL Statements section.

You can launch SQL editor in several ways. For example:

1. Click File -> NewSQL New SQL in the application main menu.
2. Click NewSQL New SQL on the Standard toolbar.
3. Open an SQL file by selecting File -> Open File.

You can always save a SQL document for future use.

SQL Editor Interface Elements

Code Pane
An area where SQL code is displayed and edited.

Margin Indicator Bar
A grey area at the left of the editor. Margin indicators, such as bookmarks are displayed there. You can show or hide it by setting the corresponding option in the General, Text Editor, Options dialog box.

Selection Margin
White area between the margin bar and code. Click here to select the line.

Horizontal and Vertical Scroll Bars
Allows scrolling the code. You can show or hide them by setting corresponding options in the General, Text Editor, Options dialog box.

ExpandedToggleIcon(9x12) See Also

SQL Document

Edit Parameters Dialog Box


Edit Parameters Dialog Box

This window allows you to add, delete, or modify existing parameters in the query. Click edit-parameters Edit Parameters button on the SQL toolbar to invoke this window.

Name
Displays the list of parameters that are currently used. Click on a parameter to select it and fill the fields to the right of the list with values that correspond to the selected parameter. Click it again to rename the parameter.

The following fields are specific for every parameter. Their content depends on what parameter is currently selected.

Type
Lets you choose the data type of the parameter.

Direction
Indicates whether the parameter is input, output, or bidirectional.

Nullable
Specifies whether the value of this parameter is NULL. Checking this option clears the Value field.

Value
Value of the parameter. Note that character or date and time values should not be quoted. If you want to set value sample text you should just enter sample text without quotes.

ExpandedToggleIcon(9x12) See Also

SQL Document


Additional Application Features

ExpandedToggleIcon(9x12) In This Section

Writing and Executing SQL Statements
This section describes the guidelines about writing SQL statements and their executing.

Working with Data in Data Editor
This section describes some things you should know about manipulating data.


How To: Save and Load Data Comparisons

After you have created a document with data comparison, you may save it just like any other document. The saved file has the extension 'dcomp'. It stores the following information:

· Source and target settings
· Selected objects and subobjects
· Comparison keys
· Results filter
· Skipped objects

It does not contain data comparison results. Data is recompared when the file is opened. If a target or a source can not be found, the New Data Comparison wizard appears where you should set the source or target options.

ExpandedToggleIcon(9x12) See Also

Getting Started

Comparing Data


SQL Document Overview

Most of the time you interact with a database by writing and executing SQL queries. In this way, SQL document is an essential part of every database tool in dbForge product line. It is a place where you create SQL statements in order to run them against a database server. This topic gives you an overview of SQL document layout, views, and functions.

To create a new SQL Document:

On the Standard toolbar, click New SQL.

The following image is the example of an SQL document.

note Note

Actual document look may slightly vary from the image above, depending on the product you use.

ExpandedToggleIcon(9x12) SQL Document Overview

Each SQL document includes different representations of the content. They are called document views. On the above screen-shot you can see two document views: Text and Data.

· Text view contains SQL editor which allows you to write SQL statements.
· Data view, typically shown after a query is executed, displays a data editor with result sets returned by a database server.

To switch to a specific view:

· Click a button with a view name on the bottom-panel of the document.
· Right-click document bottom-panel to open the shortcut menu and select a view from the list.

ExpandedToggleIcon(9x12) Representing Query Execution Results

The query execution results can be represented in two ways - in text and in grid formats.

To represent results as text, on the SQL toolbar, click the results-as-text Results as Text button before query execution. The following image represents a sample of query execution results in text format.

To represent results as grid, on the SQL toolbar, click the results-as-grid Results as Grid button before query execution. The following image represents a sample of query execution results in grid format.

CollapsedToggleIcon(9x12) Document Layout

SQL document has two types of view layout: Split Layout and Combined Layout. To switch document layout use appropriate buttons at the bottom-right corner of the document.

Split Layout

In the split layout a document has one prominent (main) view which is aligned to the top of the document view port. Other views are called additional, they are displayed in the bottom area of the document view port.

Main view remains always in split layout visible and you can toggle only additional views. But you can see two views at a time to avoid unnecessary switching.

To temporary hide additional document views, click the hideshow-views Hide/Show additional document views button at the bottom-right corner of the document, or just press CTRL+R.

To change the main document view, use the swap-views Swap main and additional documents views button to swap the main view and active additional view.

Combined Layout

In the combined layout you can see only one view at a time. A document view fills entire document view port. Typically, you need this layout when you a focusing on one specific document representation (for example, when you extensively work with data).

ExpandedToggleIcon(9x12) See Also

Writing and Executing SQL Statements

Writing SQL Statements