SAP Knowledge Base Article - Public

2748971 - Error: "Access to XMLHttpRequest at <URL> from origin <tenant> has been blocked by CORS policy...", when connecting SAP Analytics Cloud (SAC) to BW

Symptom

  • After configuring CORS within BW the following error is thrown:

"Access to XMLHttpRequest at 'https://.../sap/bw/ina/GetServerInfo?sap-client=045'
from origin '<tenant URL>' has been blocked by CORS policy: Response to preflight
request doesn't pass access control check: No 'Access-Control-Allow-Origin' header
is present on the requested resource."

2748971.png

Environment

  • SAP Analytics Cloud
  • SAP NetWeaver

Reproducing the Issue

  1. Enable CORS on SAP NetWeaver as per the SAP Analytics Cloud Help; Enable CORS on SAP NetWeaver releases lower than 7.52
  2. Attempt to connect SAP Analytics Cloud to a BW system.

Cause

  • the CORS_LIVE_REWRITE file was not configured as per the steps outlined in SAP Analytics Cloud Help

Resolution

  • Ensure that the steps in the SAP Analytics Cloud Help are followed.
  • In this instance, the HostName in the following line was blank:

if %{HEADER:ORIGIN} regimatch ^(https:\/\/)?<HOSTNAME> [AND]

  • HOSTNAME must be replaced with the correct SAP Analytics Cloud host. For example: mytenant.us1.sapanalytics.com.

See Also

Your feedback is important to help us improve our knowledge base.

Keywords

SAP, Cloud for Analytics, Cloud4Analytics, CloudforAnalytics, Cloud 4 Planning, BOC, SAPBusinessObjectsCloud, BusinessObjectsCloud, BOBJcloud, BOCloud., SAC, SAP AC, Cloud-Analytics, CloudAnalytics, SAPCloudAnalytics, cross, origin, script, host, name, live rewrite, edit, bex, business, warehouse , KBA , LOD-ANA , SAP Analytics Cloud (SAC) , LOD-ANA-BI , Business Intelligence Functionality, Analytic Models , LOD-ANA-PL , Planning , LOD-ANA-BR , SAC Boardroom , LOD-ANA-PR , SAC Predicitive , Problem

Product

SAP Analytics Cloud 1.0