Ready to get started?

Download a free trial of the Adobe Analytics Data Provider to get started:

 Download Now

Learn more:

Adobe Analytics Icon Adobe Analytics ADO.NET Provider

Rapidly create and deploy powerful .NET applications that integrate with Adobe Analytics data including Metrics, Users, Reports, Segments, and more!

Connect to Adobe Analytics Data from PowerBuilder



This article demonstrates how to access Adobe Analytics data from Appeon PowerBuilder using the CData ADO.NET Provider for Adobe Analytics.

This article demonstrates using the CData ADO.NET Provider for Adobe Analytics in PowerBuilder, showcasing the ease of use and compatibility of these standards-based controls across various platforms and development technologies that support Microsoft .NET, including Appeon PowerBuilder.

This article shows how to create a basic PowerBuilder application that uses the CData ADO.NET Provider for Adobe Analytics to retrieve data.

  1. In a new WPF Window Application solution, add all the Visual Controls needed for the connection properties. Below is a typical connection string:

    GlobalCompanyId=myGlobalCompanyId; RSID=myRSID; OAuthClientId=myOauthClientId; OauthClientSecret=myOAuthClientSecret; CallbackURL=myCallbackURL;

    Adobe Analytics uses the OAuth authentication standard. To authenticate using OAuth, you will need to create an app to obtain the OAuthClientId, OAuthClientSecret, and CallbackURL connection properties. See the "Getting Started" section of the help documentation for a guide.

    Retrieving GlobalCompanyId

    GlobalCompanyId is a required connection property. If you do not know your Global Company ID, you can find it in the request URL for the users/me endpoint on the Swagger UI. After logging into the Swagger UI Url, expand the users endpoint and then click the GET users/me button. Click the Try it out and Execute buttons. Note your Global Company ID shown in the Request URL immediately preceding the users/me endpoint.

    Retrieving Report Suite Id

    Report Suite ID (RSID) is also a required connection property. In the Adobe Analytics UI, navigate to Admin -> Report Suites and you will get a list of your report suites along with their identifiers next to the name.

    After setting the GlobalCompanyId, RSID and OAuth connection properties, you are ready to connect to Adobe Analytics.

  2. Add the DataGrid control from the .NET controls.
  3. Configure the columns of the DataGrid control. Below are several columns from the Account table: <DataGrid AutoGenerateColumns="False" Margin="13,249,12,14" Name="datagrid1" TabIndex="70" ItemsSource="{Binding}"> <DataGrid.Columns> <DataGridTextColumn x:Name="idColumn" Binding="{Binding Path=Id}" Header="Id" Width="SizeToHeader" /> <DataGridTextColumn x:Name="nameColumn" Binding="{Binding Path=Page}" Header="Page" Width="SizeToHeader" /> ... </DataGrid.Columns> </DataGrid>
  4. Add a reference to the CData ADO.NET Provider for Adobe Analytics assembly.

Connect the DataGrid

Once the visual elements have been configured, you can use standard ADO.NET objects like Connection, Command, and DataAdapter to populate a DataTable with the results of an SQL query:

System.Data.CData.AdobeAnalytics.AdobeAnalyticsConnection conn conn = create System.Data.CData.AdobeAnalytics.AdobeAnalyticsConnection(connectionString) System.Data.CData.AdobeAnalytics.AdobeAnalyticsCommand comm comm = create System.Data.CData.AdobeAnalytics.AdobeAnalyticsCommand(command, conn) System.Data.DataTable table table = create System.Data.DataTable System.Data.CData.AdobeAnalytics.AdobeAnalyticsDataAdapter dataAdapter dataAdapter = create System.Data.CData.AdobeAnalytics.AdobeAnalyticsDataAdapter(comm) dataAdapter.Fill(table) datagrid1.ItemsSource=table.DefaultView

The code above can be used to bind data from the specified query to the DataGrid.