12 KiB
Data Access and Security Reference
Table of Contents
- Data Access Controls Overview
- Single Values Data Access Control
- Operator and Values Data Access Control
- Hierarchy Data Access Control
- Hierarchy with Directory Data Access Control
- Importing BW Analysis Authorizations
- Applying Data Access Controls
- Row-Level Security in Intelligent Applications
- Space Access Control
- Audit Logging
Data Access Controls Overview
Data Access Controls (DACs) implement row-level security in SAP Datasphere.
Purpose
- Restrict data visibility by user
- Implement fine-grained authorization
- Comply with data privacy requirements
- Support multi-tenant scenarios
DAC Types
| Type | Use Case | Complexity |
|---|---|---|
| Single Values | Simple value matching | Low |
| Operator and Values | Complex conditions | Medium |
| Hierarchy | Node-based filtering | Medium |
| Hierarchy with Directory | Complex hierarchical | High |
Architecture
User Request
↓
Data Access Control
↓
Criteria Evaluation
↓
Row Filtering
↓
Result Set
DAC Components
Criteria:
- Columns used for filtering
- User attributes for matching
- Operators for comparison
Permissions Entity:
- Maps users to allowed values
- User IDs must be in the form required by your identity provider
- Supports wildcards (
*for all records) - Hierarchy node references
- Cannot be protected by data access controls themselves
- Cannot contain protected sources
- Must be encapsulated in views when shared across spaces
Performance Considerations
| Factor | Recommendation |
|---|---|
| Source table size | Replicate tables exceeding 500,000 rows |
| Permissions per user | Avoid exceeding 5,000 records for Operator/Values controls |
| Wildcard operator | Use * for all-records access |
| Persisted views | Views with protected sources cannot be persisted |
Security Enforcement Scope
Important: Row-level security can be circumvented while the view remains in its original space.
Security is enforced only when the view is:
- Shared to another space
- Consumed outside the space (e.g., in SAP Analytics Cloud)
Controls filter results in data previews based on current user within the space.
Single Values Data Access Control
Overview
Simple value-based filtering using exact matches.
Creating Single Values DAC
- Data Builder > New Data Access Control
- Select "Single Values"
- Define criteria column
- Configure permissions table
- Deploy
Criteria Configuration
Single Criterion:
criterion: region
column: region_code
Multiple Criteria:
criteria:
- region: region_code
- company: company_code
Permissions Table
Structure:
| User | Region | Company |
|---|---|---|
| user1@company.com | US | 1000 |
| user1@company.com | EU | 1000 |
| user2@company.com | * | 2000 |
Wildcard Support:
*matches all values- Explicit values for specific access
Example
Scenario: Restrict sales data by region
DAC Definition:
type: Single Values
criteria:
- name: region
column: sales_region
permissions:
- user: alice@company.com
region: North America
- user: bob@company.com
region: Europe
- user: charlie@company.com
region: "*" # All regions
Operator and Values Data Access Control
Overview
Complex filtering using comparison operators.
Creating Operator and Values DAC
- Data Builder > New Data Access Control
- Select "Operator and Values"
- Define criteria with operators
- Configure permissions
- Deploy
Supported Operators
| Operator | Symbol | Description |
|---|---|---|
| Equal | = | Exact match |
| Not Equal | != | Exclude value |
| Less Than | < | Below threshold |
| Greater Than | > | Above threshold |
| Between | BT | Range inclusive |
| Contains Pattern | CP | Pattern match |
Criteria Configuration
criteria:
- name: amount_range
column: order_amount
operators: [=, <, >, BT]
- name: status
column: order_status
operators: [=, !=]
Permissions Table
| User | Criterion | Operator | Value 1 | Value 2 |
|---|---|---|---|---|
| user1 | amount | BT | 0 | 10000 |
| user2 | amount | > | 10000 | - |
| user3 | status | != | DRAFT | - |
Example
Scenario: Restrict by amount threshold
DAC Definition:
type: Operator and Values
criteria:
- name: amount_threshold
column: transaction_amount
permissions:
- user: junior_analyst@company.com
criterion: amount_threshold
operator: "<"
value: 10000
- user: senior_analyst@company.com
criterion: amount_threshold
operator: "*" # All amounts
Hierarchy Data Access Control
Overview
Filter data based on hierarchy node membership.
Creating Hierarchy DAC
- Data Builder > New Data Access Control
- Select "Hierarchy"
- Reference hierarchy view
- Configure permissions
- Deploy
Hierarchy Configuration
Hierarchy Reference:
hierarchy:
view: cost_center_hierarchy
node_column: cost_center_id
parent_column: parent_cost_center
Node-Based Permissions
| User | Node | Include Descendants |
|---|---|---|
| user1 | CC1000 | Yes |
| user2 | CC2000 | No |
| user3 | ROOT | Yes |
Example
Scenario: Restrict by organizational hierarchy
DAC Definition:
type: Hierarchy
hierarchy:
view: org_hierarchy
node: org_unit_id
criteria:
- column: responsible_org_unit
permissions:
- user: manager_a@company.com
node: DEPT_A
descendants: true
- user: manager_b@company.com
node: DEPT_B
descendants: true
Hierarchy with Directory Data Access Control
Overview
Complex hierarchical filtering with directory-based node definitions.
Creating Hierarchy with Directory DAC
- Data Builder > New Data Access Control
- Select "Hierarchy with Directory"
- Define directory table
- Configure hierarchy relationship
- Set permissions
- Deploy
Directory Table Structure
Directory Definition:
CREATE TABLE auth_directory (
node_id VARCHAR(50),
node_type VARCHAR(20),
parent_node VARCHAR(50),
level_number INTEGER
)
Configuration
type: Hierarchy with Directory
directory:
table: auth_directory
node_column: node_id
parent_column: parent_node
type_column: node_type
criteria:
- column: cost_center
directory_type: COST_CENTER
Permissions
| User | Node ID | Node Type |
|---|---|---|
| user1 | H_1000 | COST_CENTER |
| user2 | H_2000 | PROFIT_CENTER |
Importing BW Analysis Authorizations
Overview
Import existing SAP BW or BW/4HANA analysis authorizations.
Prerequisites
- BW connection configured
- Authorization objects available
- User mapping defined
Import Process
- Data Builder > New Data Access Control
- Select "Import from BW"
- Choose connection
- Select authorization objects
- Map to local objects
- Deploy
Supported Objects
BW Authorization Objects:
- RSECAUTH (Analysis Authorizations)
- InfoObject restrictions
- Hierarchy authorizations
Mapping Configuration
import:
connection: bw4hana_prod
authorization: ZSALES_AUTH
mapping:
- bw_characteristic: 0COMP_CODE
local_column: company_code
- bw_characteristic: 0REGION
local_column: sales_region
Applying Data Access Controls
Apply to Graphical Views
- Open graphical view
- View properties > Security
- Select data access control
- Map criteria columns
- Deploy
Apply to SQL Views
- Open SQL view
- View properties > Security
- Select data access control
- Map criteria columns
- Deploy
Apply to Analytic Models
- Open analytic model
- Model properties > Security
- Select data access control
- Map to fact/dimension columns
- Deploy
Analytic Model Constraint: Cannot map data access controls to dimensions with:
- Standard variables
- Reference date variables
- X variables
Criteria Mapping
Mapping Configuration:
data_access_control: region_dac
mappings:
- dac_criterion: region
view_column: sales_region
- dac_criterion: company
view_column: company_code
Process Source Changes
When source columns change:
- Open DAC editor
- Process source changes
- Update mappings
- Redeploy
Row-Level Security in Intelligent Applications
Overview
Apply row-level security to data delivered through intelligent applications.
Configuration
- Install intelligent application
- Configure data access
- Apply DAC to exposed views
- Test user access
Supported Applications
- SAP Analytics Cloud
- Third-party BI tools
- Custom applications
Space Access Control
Overview
Control user access at the space level.
Space User Management
Add Users to Space:
- Space > Members
- Add user
- Assign role
- Save
Space Roles:
| Role | Permissions |
|---|---|
| Space Administrator | Full control |
| Integrator | Data integration |
| Modeler | Create/modify objects |
| Viewer | Read-only access |
Cross-Space Sharing
Share Objects:
- Select object
- Share to other spaces
- Define share permissions
- Confirm sharing
Share Permissions:
- Read: View data
- Read/Write: Modify data
- Full: All operations
Audit Logging
Overview
Track data access and modifications for compliance.
Enable Audit Logging
- Space > Settings
- Enable audit logging
- Select audit events
- Configure retention
Audited Events
| Event | Description |
|---|---|
| Read | Data access |
| Insert | New records |
| Update | Record changes |
| Delete | Record removal |
Audit Log Structure
{
"timestamp": "2024-01-15T10:30:00Z",
"user": "analyst@company.com",
"action": "READ",
"object": "sales_data_view",
"rows_affected": 1500,
"filters": "region='US'"
}
Log Retention
Configure Retention:
- Set retention period (days)
- Automatic cleanup
- Archive options
Viewing Audit Logs
- System > Monitoring
- Audit Logs
- Filter by criteria
- Export if needed
Best Practices
DAC Design
- Keep criteria simple
- Use hierarchies for complex org structures
- Test with representative users
- Document authorization model
Performance
- Index criterion columns
- Limit permission table size
- Use wildcards judiciously
- Monitor query performance
Maintenance
- Regular permission reviews
- User offboarding process
- Audit log monitoring
- Documentation updates
Documentation Links
- Data Access Controls: https://help.sap.com/docs/SAP_DATASPHERE/c8a54ee704e94e15926551293243fd1d/a032e51
- Single Values DAC: https://help.sap.com/docs/SAP_DATASPHERE/c8a54ee704e94e15926551293243fd1d/5246328
- Hierarchy DAC: https://help.sap.com/docs/SAP_DATASPHERE/c8a54ee704e94e15926551293243fd1d/0afeeed
- Space Access: https://help.sap.com/docs/SAP_DATASPHERE/c8a54ee704e94e15926551293243fd1d/9d59fe5
Last Updated: 2025-11-22