Twitter List Followers Task
Twitter List Followers Task extracts a list of users (i.e. user ID, Twitter handlers) that follows a given screen name (Twitter handler).
Configuring Twitter List Followers Task
Similarly to adding other SQL Server Integration Services (SSIS) tasks, the Twitter List Followers Task shown in Figure 1 can be added into the Control Flow pane in the following manner;
- Drag-and-drop the Twitter List Followers Task into the Control Flow, or
- Double clicking the Twitter List Followers Task
By default the Twitter List Followers Task will throw validation errors shown in Figure 2.
To resolve the validation errors, we need to configure the Twitter List Followers Task by using its editor (Twitter List Followers Task Editor).
The Twitter List Followers Task has four parameters:
- Screen Name – The screen name of the user for whom to return results for with a maximum character value of 500 and default value is set to trevornoah
- Count – Number of tweets to return. The maximum value is 200 and the default value is 5
- Save To – path wherein the generated file will be stored
- Save As – which can either be JSON of TEXT file – by default, the results will be saved as TEXT file
Set Absolute Values
Providing absolute values for the parameters refers to hardcoding the values into the textboxes i.e. manually enter dstv as the Screen Name.
Dynamically Set Values using Expressions
Instead of manually capturing values for the parameters, we can dynamically set them using package expressions. Expressions reads data from package variables at runtime. To configure expressions, click the Ex button. This will open up a Choose Variable dialog box. You can then select the variable you want to use and click the OK button.
Once you have clicked the OK button, you will be redirected back to the Twitter List Followers Task with textboxes set to variable names.
Executing Twitter List Followers Task
The execution of the Twitter List Followers Task is usually quick. Similarly to executing other SSIS tasks, the simplest way of executing Twitter List Followers Task is to right-click your mouse button, navigate to and click Execute Task option as shown in Figure 7.
If the configuration is done correctly, the Twitter List Followers Task execution should be successful as shown in Figure 8.
The file generated after executing the Twitter List Followers Task is shown in Figure 9 and it is prefixed with SST_TwitListFollowers_ followed by a date and time stamp.
Additional Informational Events
As the Twitter List Followers Task is being executed, it is important to take notes of custom additional information and Progress events that will appear in the Execution Results tab in the designer, shown in Figure 10. This information could be useful during troubleshooting, especially in cases where package variables are used to set parameter values.