Symptom
‘Exception: com.sap.db.jdbc.exceptions.JDBCDriverException: SAP DBTech JDBC: [601]: too many session variables are set: the maximum number of session variables exceeded\\nError Code: 601’ error occurs for some users upon running story report
Environment
- SAP SuccessFactors HCM Suite
- Analytics & Reporting (Ad Hoc, YouCalc, ORD)
- Story Reports
- Analytics & Reporting (Ad Hoc, YouCalc, ORD)
Reproducing the Issue
- Login to the instance
- Navigate to Report Center
- Run/Edit the affected story report
- The error message pops up "Exception: com.sap.db.jdbc.exceptions.JDBCDriverException: SAP DBTech JDBC: [601]: too many session variables are set: the maximum number of session variables exceeded\\nError Code: 601’"
Cause
This error occurs due to one of the following:
- Excessively complex Role-Based Permission (RBP) configuration
- The RBP structure for the affected user generates more than 2,048 session variables, exceeding the HANA session limit.
- Each user’s permissions determine which data they can see. When a user opens a Story report, the system translates these permissions into “session variables.”
- If the permissions are simple, only a few variables are created.
- If the permissions contain many rules, exceptions, or complex target populations, hundreds or even thousands of variables might be created.
- The SAP HANA database has a strict limit of 2,048 session variables. If a user’s permissions generate more than this limit, the error appears.
- Corrupted or inconsistent HANA database session
- In rare cases, a DB session issue may trigger the same error during query execution.
Resolution
1. If the number of session variables exceeds the HANA limit (2,048)
SAP HANA supports a maximum of 2,048 session variables.
If this limit is exceeded, the issue is caused by the customer’s RBP framework being too complex for the affected user.
- What Support can do:
- Confirm the number of generated session variables for the affected user.
- What can be done by the customer/partner:
- Review and adjust the RBP configuration so that fewer session variables are generated.
- This may involve simplifying the permission structure or reducing the complexity of target populations.
- Support cannot advise on how RBP should be redesigned.
2. If the number of session variables is below the limit
If SAP Support verifies that the session-variable count is below 2,048:
- The issue is not caused by RBP complexity.
- SAP Support will escalate to the HANA team to investigate possible backend or session‑corruption causes.
Important Notes:
- SAP Support does not provide RBP design guidance and cannot recommend how to simplify or restructure roles.
- Customers should work with their internal SuccessFactors administrators or their implementation partner for any RBP redesign or simplification.
- SAP Support’s role is limited to:
- Providing the session-variable count
- Determining whether it exceeds the HANA limit
- Engaging HANA Engineering if the count is within limits.
Keywords
too many session variables, session, variables, many, hana, story, stories, error, exception, successfactors, success, factors, JDBCDriverException, Error Code: 601, errorcode , KBA , LOD-SF-ANA-SAC-RBP , Role Based Permissions & Authorizations , LOD-SF-ANA-SAC , Stories in People Analytics , LOD-SF-ANA-RCT-SAC , People Analytics Stories , Problem
SAP Knowledge Base Article - Public