Exercise: Using a variable to count dinosaurs imported from Excel

This exercise is provided to allow potential course delegates to choose the correct Wise Owl Microsoft training course, and may not be reproduced in whole or in part in any format without the prior written consent of Wise Owl.

The answer to the exercise will be included and explained if you attend the Wise Owl course listed below!

Category ==> SSIS Integration Services  (18 exercises)
Topic ==> Variables  (2 exercises)
Level ==>
Course ==> Integration Services
Before you can do this exercise, you'll need to download and unzip this file (if you have any problems doing this, click here for help).

You need a minimum screen resolution of about 700 pixels width to see our exercises. This is because they contain diagrams and tables which would not be viewable easily on a mobile phone or small laptop. Please use a larger tablet, notebook or desktop computer, or change your screen resolution settings.

Create a new package called Dinosaur recount.  As the package name suggests, we're going to count the number of dinosaurs, so first create a variable called DinoCount to hold this information:

Dinosaur count variable

The variable to hold the number of dinosaurs.


Now create a data flow task for the package:

Data flow import from Excel

The data flow task will pipe the dinosaurs imported into a row count transformation, which should store the count of rows imported in the DinoCount variable.


Add a script control flow task which displays the number of dinosaurs found:

 Importing dinosaurs Message box showing result
The control flow ... ... and what it should show.

Don't forget to assign the DinoCount variable to the script task as a ReadOnly variable, so that you can access its value in code.

Close the package down!

This page has 0 threads Add post