Getting Started with C9 Active Insights
In this article you will learn about the key tasks associated with building Widgets and Tabs in Active Insights. To do so you will need to complete the following three activities:
- Generate a data set using the C9 Query Builder
- Make the data set available for use in Active Insights
- Create a tab and Widget in Active Insights
Once you have completed these activities, you will understand the basic steps involved in creating dashboards. You can then build on this knowledge by accessing additional articles and videos in the Active Insights Knowledge Base.
Activity 1: Generate a data set using the C9 Query Builder
- Log into C9 Query Builder
- Click on the SQL Script Tab
- Paste the following query into the script editor (Note: this query will return total revenue by sales rep and by SalesForce.com forecast category. It assumes that you are running a vanilla instance of SalesForce.com and that you are using the forecast category. If either of these assumptions are not true, you may chose to modify the query. Alternatively you can move directly to Activity 3 where you will find instructions for completing this exercise using sample data from an excel spreadsheet)
Select “security”.”User”.”Name”,Sum(If(“ads”.”Opportunity”.”ForecastCategory” = ‘Closed’, “ads”.”Opportunity”.”Amount”,0)) As “WonAmt”,Sum(If(“ads”.”Opportunity”.”ForecastCategory” = ‘Forecast’, “ads”.”Opportunity”.”Amount”,0)) As “CommitAmt”,Sum(If(“ads”.”Opportunity”.”ForecastCategory” = ‘BestCase’, “ads”.”Opportunity”.”Amount”,0)) As “UpsideAmt”,Sum(If(“ads”.”Opportunity”.”ForecastCategory” = ‘Pipeline’, “ads”.”Opportunity”.”Amount”,0)) As “PipelineAmt”,Sum(If(“ads”.”Opportunity”.”ForecastCategory” = ‘Omitted’, “ads”.”Opportunity”.”Amount”,0)) As “LostAmt”From “ads”.”Opportunity”
Inner Join “security”.”User” On “ads”.”Opportunity”.”OwnerId” = “security”.”User”.”Id”
Where “ads”.”Opportunity”.”CloseDate” Between SFBeginningOfYear(Current_Date) And
SFEndOfYear(Current_Date)
Group By *

- Click on the Execute Query button on the Query Builder tool bar
- Click on File>Save As>C9R Query
- In the “Save as Cloud9 Reports Query” window, click on the “Uncategorized” node of the file tree
- Name the query “Active Insights Forecast Categories”

Activity 2: Make the Dataset available for use in Active Insights
- Log into C9 and navigate to the homepage
- Click on the Queries link in the Tools pane
- Expand the “Uncategorized” node of the file tree
- Click on “Active Insights Forecast Categories” query
- Click on the “Edit Properties” button on the Properties Applet
- Check the box next to “Make this Query available for Active Insights”
- Click the OK button

Activity 3: Create a tab and Widget in Active Insights
Step 1: Create a tab
- From the homepage in the C9 application, click on the Active Insights link in the Tools pane
- Click on the tab with the “Plus” sign
- Click on the “Add a Blank Tab” button
- Click on the gear icon next to “New Tab”
- Click on “Rename”
- Call the Tab “Sales Activity”

Step 2: Create a Bar Chart Widget
- Click on the “Add a Widget” button in the center or the Sales Activity Tab
- Click on the “Build a New Widget” button
- Click on “Bar/Line” Chart on the screen titled “What style of widget do you want to start with?”

- If you will be using sample data (recommended in order to more easily follow tutorial)
- Download the excel file called “Active Insights Forecast Category” from the “Connecting to Data Sources” section of the Active Insights Knowledge Base http://www.c9inc.com/activeinsights-kb/ to your local machine
- Click on “Create a new data source
- Click on “Upload a File
- Click on the “Choose File” button and navigate to the saved Excel file
- If you will be using the data source generated by C9 Query Builder, click on “Use an existing data source from the library”
- Choose the data source called “Active Insights Forecast Category”
- Skip to Step 6

- In the Widget Editor, click on the “Widget” node of the Widget Component Tree
- In the Properties tab, enter “Revenue By Forecast Category” as the Widget Title

- Click on the Series node of the Widget Component Tree
- Click on the Series Data tab
- Click on Column B (Click directly on the “B” to highlight the entire column)Note: Cell B:1 contains the name of the column while the rest of the cells in the column contain values. Follow steps 11-12 to remove the column name from the array of values that is represented in the bar chart
- Click on the “Wrap current value in a function” button

- Click on Data Manipulation>Slice
- Click on the X Axis node of the Widget Component Tree
- Click on the X Axis Properties tab
- Enter “Reps” as the Axis Title and click “Show axis title”
- For Label Angle, click on the vertical orientation

- Click on the X Axis Data tab
- Highlight Column A to add the names of the reps to the X axis
- Click on the “Wrap current value in a function” button
- Click on Data Manipulation>Slice

- Click on the Save button
- Select “All Users” and the select “use and edit” from the drop down
- Scroll to the bottom of the page and click the Save button
