Getting started - Convert NorthwindEF.MDB to VDB4

Skip Navigation LinksVistaDB.Net > Try It! > Tutorials > Getting Started with VistaDB

This Getting Started section requires no coding and is designed to provide a quick overview of how to migrate existing data to VistaDB. After reading this page, go to Your first VistaDB application to learn how to create an application that uses VistaDB. 

The NorthwindEF database is a customized version of Northwind from Microsoft with added Foreign Keys for use with the Entity Framework.

Please note that the actual Northwind and NorthwindEF sample databases from Microsoft are both included in VistaDB 4 as a part of the normal setup.

Demo Steps

  1. Download and Install VistaDB
  2. Migrate Northwind.MDB to .VDB4 format
  3. Use Data Builder with Northwind.VDB4
  4. Working with your data

DMW screenshot
Data Migration Wizard 4 with Northwind Opening from a SQL Server Express instance.

1. Download and Install VistaDB

To get started, make sure you have the latest version of VistaDB. If you are new to VistaDB, please the Free 30-day Trial. It's fast and easy. Simply enter your valid email address and you will receive an email with download instructions. No files are sent and the download setup is under 10MB.

After downloading the VistaDB Trial setup, run it to install. By default, VistaDB will be installed to C:\Program Files\VistaDB 4.

2. Migrate an existing database

To quickly see VistaDB in action, lets migrate an existing database to VistaDB. The Data Migration Wizard (DMW) allows you to migrate data from SQL Server (All editions), MS-Access (MDB and ACCDB) and SQL Compact Edition (SQL CE 3.5) to the VistaDB .VDB4 format. Run the "VistaDB Data Migration Wizard" shortcut from your start menu.

Steps to migrate NorthwindEF.mdf to Northwind.vdb4

  1. Attach the NorthwindEF.mdf to a SQL Server instance
  2. Run Data Migration Wizard 4
  3. Step 2 - Choose SQL Server
  4. Step 3 - Choose the attached instance you created and select an output filename. 
  5. Step 4 - Select the tables, indexes, etc you wish to migrate (select all by default)
  6. Step 6 - The database is built and diagnostic information is written for each portion of the migration.  If any errors occur you will see them displayed in the output window.
  7. Step 7 - Press the Open Database to launch the newly created database in Data Builder.

3. Use Data Builder with Northwind.VDB4


Data Builder with Northwind EF

Now that you have the data into Data Builder you can navigate through the tables, write SQL statements, etc.

4. Working with your data

With the NorthwindEF.VDB4 database file opened, try the following:

Running SQL commands

Click on SQL Query, which is the first treelist item. In the SQL Expression editor box, enter this statement then press F5 or Ctrl-E.

select * from employees where firstname = 'Anne'

This will display the result set in the Data Grid tab.

select orders.orderid, orders.orderdate, employees.Firstname, employees.Lastname from orders
left join employees on orders.employeeid = employees.employeeid
where employees.employeeid = 
( select employeeid from employees where firstname = 'Anne' );

After you see the results of the above statements, press F6 (History) to display the history of your SQL statements. This history windows makes working with interactive SQL very efficient.

Working with the Schema

  1. Click on Orders in the treelist
  2. Right-click on Orders and select "Alter Table" from the popup menu. You can also perform this task by selecting Alter Table from the Table menu.
  3. Click on the Column Details tab to see the attributes of each individual column.

Data Builder alter table Order from Northwind

More Videos

We also have a YouTube channel for VistaDB Training that includes more data tutorials.

 

Related Links

quotesI've been managing distributed Client/Server applications for many years now and have experienced all the pitfalls of the different database engines available... I decided to go with VistaDB this time and we've not received a single issue with database connectivity!quotes

Read more testimonials


VistaDB 4 box shot

  • Embedded SQL Database
  • 1 MB single Dll
  • Easy SQL Server migration
  • TSQL data types and syntax
  • Royalty free distribution
  • ASP.NET Medium Trust supported for shared hosting