Connecting a PLM Tool to Tableau using REST API - tableau-api

I am trying to connect data from a PLM tool to Tableau using the REST API. I am not super familiar with the REST API, so I am unsure how to connect it to Tableau Desktop. Is it even possible to connect a REST API to Tableau Desktop? Do I need additional tools to build the connection between the API and Tableau? Thanks in advance!

Yes, it is possible to connect REST API to Tableau Desktop. And yes, you'll need additional tools to build the connection.
Steps:
Set up an ODBC connection. Visit this website for this step -> https://kb.blackbaud.com/knowledgebase/articles/Article/41081
Open Tableau Desktop and under connect to a server, select "Other Databases (ODBC)".
Connect and in the "String Extras" box, put in your SDSN, HST, and PRT information.
Choose the database that the RESP API is connected to. You can see how to do that in the REST API documentation of the site you're using.
Filter the data you want to see in Tableau and you should have your data there.
There are so many ways to make this connection and this is one of them.
Thanks!

Actually, Tableau doesn't support REST API as a data source directly. You have to use indirect ways to connect to REST API.
One way is to use Web Data Connector, BUT you have to build a web page for each REST API and paste the web page link in Web Data Connector. (I did this before and it's pretty crazy...)
Another way is to use an ETL tool that supports extracting data from API and loading it to Tableau. This way saves you lots of time although you need to pay for additional costs. (I personally recommend Acho. Its API connector is very powerful and easy-to-use)

Related

Accessing and Updating External Databases From Salesforce

I need to connect Salesforce to an external database we have, and constantly keep both the database and salesforce updated in as close to real time as we can get. I have tired Google searching possible solutions, but nearly all of them have been outdated by over a year. Any ideas?
Thank You!
Depending on your exact scenario it is quite difficult to give you a proper answer.
However off the top of my head I would suggest two Salesforce products.
Salesforce Connect
https://www.salesforce.com/products/platform/products/salesforce-connect/
Salesforce Connect allows you to connect to various data sources and turn the tables / objects of that data source into a SObject. For example MySQL, Microsoft SQL Server, Oracle etc. There are limitations and thus it would be better to talk to a Certified Architect about such an implementation.
Heroku Connect
https://www.heroku.com/connect
Heroku Connect allows you to connect a Heroku data source with a Salesforce Object. The sync is not immediate but there are quite a few customisations inside the product to make the sync as "live" as possible. There are limitations and thus it would be better to talk to a Certified Architect about such an implementation.
Salesforce Connect has limitations.. It's good for presenting data via the interface, but if you need to act on the data and report on the data it might not be the best bet.
For close to real time hand coded sync, look at the streaming API, or using Salesforce Platform Events.
If you want to use an ETL tool, my organization has had decent luck with DBAmp, which is a Sql add on product and fairly inexpensive as compared to a lot of ETL tools ($1625 annually.) http://www.forceamp.com/ We're able to replicate the entire SF database offline in SQL with DBAMP, push changes to the offline Sql copy and upsert changes. It's also a good backup solution via offline full data copy. We got very good support from them as well when we encountered challenges.
Hope this helps.
Not sure if you are syncing one object or multiple objects but there are a few options that you have.
You can try the salesforce provided features Salesforce Connect which allows you to view and update data from your external source In salesforce but there are limitations with reporting and other considerations you should consider.
If you make use of Heroku, Heroku Connect is your best bet
You can also use a middleware ESB solutions like MuleSoft which can orchestrate keeping data in sync across multiple data sources and do batch loads, but depending on how often changes you want to keep an eye out for api limits for inbound calls to salesforce.
You can roll your own solution where you can use Outbound Messages in workflow (or triggers that initiates an apex class that calls out, but that is more cumbersome and you have to do custom error handling and retry logic which you get for free using outbound messages) to send changes from salesforce to your homegrown service that writes to you database and have you homegrown solution write back to salesforce using the soap or rest api. That would probably take you some time to build. You would also still need to be aware of API limits depending on how many updates are made on the non salesforce side.
You crate a Canvas App which displays data from your DB in Salesforce as a Tab and hook it up via SSO so users are auto logged in. But again there would not be reporting, or any salesforce features that you can take advantage of.
But I really think that you should spend some time to determine what system is your source of truth because that would determine how the data should be synced. You should also investigate if you really need the sync to be realtime or near realtime, or if you can manage with something like an hourly true up on the system that is not the source of truth.

Integrating external objects into SF without Salesforce or Lightning connect (from Postgres tables)

I have some tables from Postgres database to be integrated into Salesforce as external objects. I went through some video tutorials and documentations where I was recommended to use Salesforce Connect which supports providers with "OData" protocol support. Is it possible to integrate Postgres tables into Salesforce as external objects without Salesforce Connect?
Thanks.
Be careful with the phrase "external objects". To me, the use of those particular words implies the specific implementation of external data access/federation delivered with Salesforce Connect. I don't believe that there is any alternative if your goal is to create "real" external objects (named "objectname__x") within Salesforce.
There are, though, Salesforce integration solutions from the likes of Progress, Jitterbit, Mulesoft, and Informatica and others that can be used to access PostgreSQL, with varying degrees of coding being required. You won't get "external objects", but you will be able to access data residing off-cloud in a PostgreSQL database from your Salesforce system.
Hope this helps.
Currently the way to integrate data from external storages (Postgres in your case) without Salesforce Connect is implement your custom logic for synchronization using REST or SOAP API, Apex classes and triggers, Salesforce Workflows and Flows. Also you will need to implement appropriate interfaces on side of your data storage. Complexity of all these steps depends on complexity of your existing data model and infrastructure around it.

Can Tableau connect to arbitrary REST APIs as data sources?

I would like to use a REST API as a data source for tableau. Is this possible in any way? The API service returns standard JSON, and I would think that would be an ideal scenario for tableau. Rather than connecting to some backend database behind the API.
Thanks
The web data connector does this and is in beta right now as noted by inox. See: https://www.tableau.com/web-data-connector
"The Web Data Connector will allow you to create a connection to almost any data that is accessible over HTTP. This can include internal web services, JSON data, REST APIs, and many other sources. It will not be supported in the initial launch of Tableau 9.0. Beta participants will be able to use a dedicated product key to continue building and testing connectors until the Web Data Connector officially launches."
Also, you can use the Extract API to create Tableau Extracts from an API: https://www.tableau.com/learn/tutorials/on-demand/extract-api-introduction

How to integrate Oracle APEX and Alfresco via CMIS

A question regarding the integration of the document management system Alfresco into Oracle Application Express (APEX) based on CMIs-repository:
The aim is to use APEX as the portal-page and Alfresco showing it's results (document lists) based on search parameters coming form APEX.
A search result from a CMIS-query should be displayed in an APEX page-region.
Unfortunately I have no experience in this sector (REST, CMIS) - so any advice would be welcome!
A related question regarding user authentication and authorization via CMIS does also arise.
Has anyone out there implemented something like this or used these components together, yet?
The first thing that pops into my mind is making the choice where you want your communication with the repository to take place: client side or server side?
Alfresco supports Web Scripts, so I would be possible to create a javascript-heavy thick client which connects to your repository, get information about your files and redirect to their download links.
The alternative would be to design some way to connect to the repository from the database server. Again there are many ways to do this. You can connect to the repository during your page load and use PL/SQL regions to fire scripts that connect to your repository, get the data you want, and render your region with that information.
Another way would be to periodically check the repository for changes, and maintain a 'shadow copy' of the repository within your oracle database tables.
Of course all of these solutions have their own drawbacks.

Scripts or plug-ins for Tableau?

Can one write plug-ins for Tableau? Is Tableau equipped with any sort of general-purpose scripting language?
e.g., for generating visualizations that cannot be created using the default Tableau tools, or for doing k-means clustering on a dataset using various metrics, etc...
Tableau has several extension points at the moment.
If you publish to Tableau Server, On-Line or Public, then you can use
Tableau's JavaScript API to interact between your web app client and
the Tableau visualization. Your javascript can be notified of events
in the Tableau viz, and also effectively command it.
Instead of using the JavaScript API, you can include URL query parameters to pass filters, adjust the sizes and control a few other aspects. Similarly, you can append a format string like ".png" or ".pdf" or ".csv" to request a static snapshot in a particular format instead of an interactive object. You can't control as much via the URL as you can via the Javascript API, but the URL approach is very simple and easy for common cases.
With both Tableau Server visualizations and Tableau desktop
visualizations, you can create URL actions, so that users can select
data and then cause HTTP GET requests to URLS that are based on info in the selected data.
If you have a data source that Tableau doesn't yet provide a driver
for (there are many including ODBC), then you can write a program
using their data extract API to extract data from your custom source
and make it available to Tableau. You can also publish that source to
Tableau server as frequently as needed to keep your visualizations
current.
If you have specialized functions on your database server, you can
access them from Tableau calculations using their SQL pass through
functions. You can also define a Tableau connection using arbitrary
custom SQL which gives you another place to insert customizations.
Version 8.1 added integration with R so you can call R scripts from
Tableau calculated fields.
Version 8.2 added a REST API to Tableau Server for administrative functions
Version 9.1 adds a Web Connector that is designed to let you provide custom code to connect to web accessible data sources
Version 10.1 Tableau added TabPy a local HTTP Python server that lets you execute Python functions from Tableau in the same way you can call R functions. The same hooks have now been extended to allow calls to Matlab functions.
There are also command line programs, tabcmd and tabadmin, that work with Tableau server that you can use to send commands to the server from your own scripts, but the REST API may be more convenient in many cases.
Tableau released several open source libraries, tools and examples at https://github.com/tableau One of these libraries, the document API, allows you to programmatically modify some attributes of Tableau workbook files.
Tableau released an extensions API in 2018 to allow developers to add custom functionality to Tableau dashboards.
Version 2019.3 adds a MetaData API using GraphQL to allow clients to query for information about the fields, types and attributes available in data sources published to Tableau Server's data catalog.
Hopefully, they'll continue to add additional APIs and integration hooks, but those are most of the options available now.
At present, Tableau does not support plug-ins and does not provide a general-purpose scripting language.
There is a currently an Idea on the Tableau website to add Ruby as a scripting language which may cover some of the functionality that is required. The Ideas section is regularly reviewed by Tableau's Product Management team and is the best way of suggesting new functionality for Tableau's products.