SAP HANA interview questions for admins, modelers and developers

SAP HANA interview questions check whether you understand an in-memory, column-oriented database well enough to design, tune and run it: why columns compress and scan fast, what the delta merge does, how data survives a restart, and how replication and tenant databases work. Modeling and developer rounds add calculation views, SQLScript, CDS views and the rule of pushing logic down to the database. Strong answers tie each concept to a symptom you could actually see, such as memory growth, a slow view or a long restart.

By Published 9 min read

Which roles get SAP HANA questions

Three groups meet HANA in interviews, and the questions change with each. HANA database administrators and Basis engineers get installation, backup, replication, memory and tenant questions. Modelers and BI developers get calculation views, joins, hierarchies and performance of reports. ABAP and SQLScript developers get code pushdown, CDS views and procedures. Functional consultants on S/4HANA projects usually need only the why: one in-memory database under the business suite and what that changed. Ask the recruiter which of the three the team means, because a modeling interview spent on backups goes badly.

  1. Architecture talkExplain in-memory columnar storage, main and delta, and the server processes, usually on a whiteboard.
  2. Role-specific depthOperations scenarios for admins, a view or model to design for modelers, a query or procedure to tune for developers.
  3. Troubleshooting storyOut-of-memory dumps, a slow calculation view, a growing log volume, or a failed takeover. They want your order of checks.
  4. Project questionsMigration to HANA, sizing conversations, and how you worked with functional teams and Basis.

SAP HANA fundamentals questions

Fundamentals for freshers and the first round
QuestionWhat it testsWhat a strong answer shows
What makes HANA different from a classic disk-based database?Core ideaPrimary data is held in memory and mostly stored by column, so scans and aggregations run on compressed data without disk reads. Disk is used for persistence and recovery, not as the main working copy.
Column store or row store: when do you use each?Storage choiceColumn store for nearly all business and analytic tables because it compresses well and scans fast. Row store only for small tables read and written as whole rows, often internal or configuration data.
Why do columns compress so well?CompressionValues in one column share a type and repeat a lot. Dictionary encoding replaces each value with a small integer, and further run-length or cluster encoding can shrink those integers again.
What is the delta store?Write pathA write-optimized area per column table where inserts and updates go first, so the read-optimized main store does not have to be rebuilt on every change. Queries read main and delta together.
What is a delta merge?HousekeepingThe process that builds a new, compressed main store from the old main plus the delta, then switches over. It usually runs automatically when thresholds are met; a large delta slows reads and uses memory.
Does HANA lose data if the server loses power?DurabilityNo. Committed changes are written to the redo log on disk at commit, and savepoints periodically write a consistent image of memory to the data volumes. Restart loads the last savepoint and replays the log.
Which server processes should you know?ArchitectureThe index server holds data and runs SQL, the name server knows the topology and where tables live, and the preprocessor handles text work. Others depend on the installed options.
What is a tenant database?MultitenancyOne HANA system can host a system database plus several isolated tenant databases, each with its own users, catalog and data, sharing the same installation. S/4HANA usually runs in a tenant.
Is HANA only for SAP applications?ContextNo. It is a general database with SQL, used under S/4HANA and BW but also as a standalone platform for custom apps, analytics and modeling.
What is code pushdown?Programming modelMoving data-intensive logic out of the application server loops and into the database as set-based SQL, views or procedures, so millions of rows are not shipped across the network to be processed.
Fundamentals for freshers and the first round. Scroll sideways on a small screen.
cities = ["Berlin", "Pune", "Berlin", "Austin", "Pune", "Berlin", "Austin", "Berlin"]

dictionary = sorted(set(cities))                 # sorted distinct values
code_of = {v: i for i, v in enumerate(dictionary)}
value_ids = [code_of[c] for c in cities]         # the column itself: small ints

print("dictionary:", dictionary)
print("value ids: ", value_ids)

# A filter compares integers, not strings: look the value up once, then scan.
target = code_of["Berlin"]
print("rows where city = 'Berlin':",
      [i for i, v in enumerate(value_ids) if v == target])

# Because the dictionary is sorted, a range filter maps to a range of ids.
lo, hi = code_of["Austin"], code_of["Berlin"]
print("rows where city between Austin and Berlin:",
      [i for i, v in enumerate(value_ids) if lo <= v <= hi])
A tiny model of dictionary encoding (run with Python 3). The column becomes small integers, and an equality or range filter on a sorted dictionary turns into an integer comparison. Output: value ids [1, 2, 1, 0, 2, 1, 0, 1], Berlin rows [0, 2, 5, 7].

Interviewers like this question because it explains several things at once: why a column with few distinct values (a country or status code) is cheap, why a column of unique long strings is expensive, and why inserting a brand-new value is costlier than repeating an old one. Mention that the main store's dictionary is sorted, which is part of why changes go to a delta first.

Administration and operations questions

  • How does backup and recovery work? Data backups (full, and optionally delta: incremental or differential) plus log backups taken automatically as log segments fill. Recovery restores a data backup and replays log backups to a point in time. Without log backups you can only return to the data backup itself.
  • What is the log mode, and why does it matter? In normal mode, log segments are backed up and then freed. If log backups fail, the log volume keeps growing until the disk fills and the database stops accepting writes, a classic on-call scenario.
  • Explain system replication. A secondary system receives the primary's changes continuously and keeps data preloaded, so a takeover is fast. Modes differ in when the primary considers a commit done: synchronous to disk, synchronous to memory, or asynchronous. Shorter distance and stricter mode mean less possible data loss and more latency.
  • System replication or storage replication? System replication is database-aware, can keep the standby warm and supports near-zero data loss. Storage mirroring copies disks underneath HANA and needs a full start on the other side. Many landscapes use system replication for high availability and add a third site for disaster recovery.
  • What happens on an out-of-memory error? A statement asks for more memory than its allocation limit or the global limit allows and is cancelled, and a dump is written. Check which statement and which heap allocator used the memory, whether a missing filter caused a huge intermediate result, and whether statement memory limits are set.
  • How do you find the largest tables in memory? Query monitoring views for column table sizes, check how many records sit in delta, and look for tables that never unload. Unused large tables can be partitioned, archived or moved to warm storage options if the landscape offers them.
  • Scale-up or scale-out? Scale-up uses one bigger host and keeps joins local. Scale-out spreads tables or partitions over several hosts, useful for very large analytic data such as BW, at the cost of network traffic for joins across nodes. Many OLTP systems stay scale-up.
  • Why partition a column table? To spread a very large table across hosts, to let queries prune partitions they do not need, to make delta merges smaller, and because a single non-partitioned column table has a hard upper limit on rows (about two billion). Hash, range and round-robin are the main schemes, and they can be combined.
  • How do you secure a HANA system? Separate technical and named users, grant privileges through roles, restrict the SYSTEM user after setup, encrypt data and log volumes and backups, enable auditing for sensitive actions, and keep the system database separate from tenant administration.
Operations scenarios interviewers describe
ScenarioLikely causeWhat to say you would check
The log volume is almost full.Log backups failing or not configuredBackup catalog for failed log backups, the backup target's free space, and whether log mode was changed. Fix the backup path first; never delete log segments by hand.
Restart after maintenance takes a very long time.Large tables loading, long log replayHow long since the last savepoint, how much log must be replayed, and which tables are set to preload. Lazy column loading shortens time to first query.
Reads on one table get slower through the day.Delta growingRecords in delta and merge history. A failed or disabled auto merge, or a mass load that suppressed merges, leaves a big delta to scan.
Memory use climbs until statements fail.Expensive statements or cachesExpensive statement trace, the largest allocators, and big intermediate results from joins without filters. Then statement memory limits for the worst workload class.
The secondary site is behind.Network or disk on the secondaryReplication status and shipping delay, bandwidth between sites, and whether the mode fits the distance.
Operations scenarios interviewers describe. Scroll sideways on a small screen.

Modeling and SQLScript questions

Intermediate questions for modelers and developers
QuestionWhat it testsWhat a strong answer shows
What is a calculation view?ModelingA graphical or scripted model in the database that combines tables and other views with projections, joins, unions, aggregations and ranks, exposed as a dimension or cube for reporting tools and applications.
Why did calculation views replace attribute and analytic views?HistoryOne flexible view type covers what the older types did, and the older ones are deprecated. A migration tool converts them; an interviewer wants to hear you know the direction, not the release.
Join types in a calculation view, and why referential joins exist?Join pruningInner, left and right outer, text and referential joins. A referential join assumes integrity, so the engine can skip it when no column from the joined table is requested, which speeds queries.
What is join cardinality and why set it?Optimizer hintsDeclaring 1:1 or n:1 lets the optimizer prune joins safely. A wrong setting gives wrong results, so it must match the data.
What is an input parameter versus a variable?FilteringA variable filters the result after it is computed and is offered to the user. An input parameter is passed into the model and can change its calculation, such as a currency or a date used inside.
What is SQLScript?LanguageHANA's extension of SQL for procedures and table functions: table variables, control flow and declarative blocks that the optimizer can parallelize.
Why avoid cursors and row-by-row loops in SQLScript?Set thinkingThey serialize work the engine could run in parallel. Express the logic as table variable assignments so the optimizer sees the whole data flow.
Table function or procedure?DesignA table function is read-only and returns one table, so it can be used in a FROM clause or a view. A procedure can change data and return several outputs.
What are CDS views and AMDP from the ABAP side?S/4HANA developmentCDS views define data models with annotations in the ABAP layer and push their joins and calculations to HANA. AMDP lets an ABAP class method contain SQLScript that runs in the database.
How do you read an execution plan?TuningRun EXPLAIN PLAN or capture the statement in the plan visualizer, find the step with the largest row counts or time, and check whether filters were pushed below joins and which engine ran each part.
Intermediate questions for modelers and developers. Scroll sideways on a small screen.
CREATE FUNCTION open_items_by_customer (IN p_company NVARCHAR(4))
RETURNS TABLE (customer_id NVARCHAR(10), open_amount DECIMAL(17,2))
LANGUAGE SQLSCRIPT SQL SECURITY INVOKER READS SQL DATA AS
BEGIN
  items  = SELECT customer_id, amount
             FROM ar_items
            WHERE company_code = :p_company AND cleared = 'N';
  active = SELECT customer_id FROM customers WHERE blocked = 'N';

  RETURN SELECT i.customer_id, SUM(i.amount) AS open_amount
           FROM :items AS i
           JOIN :active AS a ON a.customer_id = i.customer_id
          GROUP BY i.customer_id;
END;
A SQLScript table function (not executed): set-based steps in table variables, no loops, filters applied before the join.

Senior and scenario questions

  • A report on a calculation view takes a minute. How do you approach it? Reproduce it with the same filters, capture the plan, and look for filters applied late, calculated columns evaluated on every row before aggregation, joins that cannot be pruned, and unions pulling more partitions than needed. Fix the model before adding hardware.
  • How would you size memory for a migration to HANA? Use SAP's sizing reports against the source system rather than guessing, plan for working memory on top of the data footprint, and allow for growth and for the space a delta merge needs while it runs.
  • A custom ABAP report loops over millions of rows. What do you change? Move filtering and aggregation into a CDS view or an Open SQL statement with GROUP BY, read only needed columns, and fall back to AMDP only when SQL alone cannot express the logic.
  • How would you design high availability across two data centers? System replication to a standby in the second site with automatic or scripted takeover, a cluster manager for host failures, tested runbooks, and backups that still run from the active side.
  • **What does SELECT * cost on a column table?** Each column must be reassembled into rows, so wide selects throw away the column store's advantage. Ask only for the columns you need.
  • How do you keep a HANA landscape patched? Plan revisions per landscape tier, test in sandbox and quality first, read the release notes and SAP Notes for the target revision, and use replication to cut downtime where supported.

Fictional example

Answering "Memory on our HANA system keeps growing. What do you do?"
Interviewer
Operations says HANA memory grows every week and a few big statements failed last night with out-of-memory errors. Where do you start?
Candidate
I would separate data growth from working memory first. For data, I check the largest column tables and how many records sit in delta; a table with a huge delta usually means a mass load switched merges off and nobody turned them back on. For the failures, I open the out-of-memory dumps and the expensive statement trace to see which statements and allocators used the memory. Last night's failures look like a reporting job joining two big tables without a selective filter, which builds an enormous intermediate result. Short term I would set a statement memory limit for that workload so one query cannot starve the system. Then I would fix the model or query with the developer, and finally review archiving for old data so growth is planned instead of discovered.

How to prepare for SAP HANA interview questions

  • Draw the architecture from memory: main and delta, savepoints and logs, the index server and name server, tenants under a system database. Practice explaining it in two minutes.
  • Pick your lane: admins rehearse backup, replication and memory scenarios; modelers build a calculation view with a join, a union and an input parameter; developers rewrite a loop as set-based SQL.
  • Use whatever access you have: a trial or training system from a course or employer. Be honest about whether your experience is hands-on or from study.
  • Learn the monitoring views and traces by purpose: which one answers memory, which answers expensive statements, which answers merges. Names matter less than knowing what to ask the system.
  • Prepare one migration or tuning story with a before and after you can explain without inventing numbers.

HANA questions overlap with the rest of the SAP stack. SAP ABAP interview questions covers CDS and AMDP from the developer side, SAP Basis interview questions covers the system administration around the database, and SQL interview questions is useful for the set-based thinking every HANA round rewards.

Architecture explanations get tighter when you hear yourself give them. Natively, an AI interview assistant for Mac and Windows, transcribes a mock HANA round on your own machine so you can check whether your delta merge answer actually reached the point. While practicing it can read a plan visualizer screenshot or a SQLScript procedure and suggest what to look at, and with Pro or the free trial it uses the résumé and job description you add. Each session leaves a transcript and notes to study.

Questions people ask

What are common SAP HANA interview questions?

Column store versus row store, dictionary compression, the delta merge, savepoints and redo logs, backup and recovery, system replication, tenant databases, partitioning, calculation views, SQLScript and how you would tune a slow query.

What is the delta merge in SAP HANA?

Changes to a column table first go to a write-optimized delta store. The delta merge builds a new compressed main store from the old main and the delta, which keeps reads fast and memory in check.

How does SAP HANA keep data safe if it runs in memory?

Each commit writes to the redo log on disk, and savepoints regularly write a consistent image of memory to the data volumes. After a restart HANA loads the last savepoint and replays the log.

Do HANA modeling interviews ask SQL?

Usually yes. Expect calculation view design, join types and cardinality, input parameters, and set-based SQL or SQLScript instead of row-by-row loops, plus reading an execution plan.

Where to go next

Practice with the same assistant you would use on a call: it listens, transcribes and suggests answers from your own resume and the job description.

Facts on this page were last checked on . Product details come from the Natively app itself; if something here is out of date, tell us at hello@heynatively.com.

Keep reading

Put it on your own machine.

A live-conversation assistant that runs locally. Your conversations stay on your machine.

macOS 12+ · Windows 10/11

© 2026 Natively AI Private Limited

Source-available under the Natively Personal Use Source License v1.0 · IP geolocation by DB-IP