AI in practice: retrieving customer orders in SAP

In our "AI in practice" section, we guide you step by step through a specific use case: from navigation and customizing to functional testing. This article is about setting up a chatbot for the AI-supported retrieval of order progress in SAP based on CDS views.

SAP is complex, and training new employees in sales is time-consuming, especially when there is a shortage of skilled workers. Quickly determining the current status of customer orders in SAP is a decisive factor for planning, service and sales in the company. The use of artificial intelligence in SAP has the potential to easily retrieve order progress using natural language. For example, customer information can be queried and inquiries, quotations and orders can be called up without having to click through complex input screens and transactions. Detailed analyses and evaluations can be displayed in an appealing text, graphic or table format via a UI5-based chat interface and the Markdown format. This not only saves a lot of time, it also significantly increases team productivity and the learning curve for new SAP users.

Milliarum provides the technology, you create the AI application

With the Milliarum AI Construction Kit and the General chatbot IT administrators can use voice-based interaction in SAP to create user guidance using artificial intelligence in just a few steps. This is based on the Core Data Services (CDS) views in SAP, which provide relevant data with high performance. Our unique selling point is maximum flexibility. From OpenAI and European cloud providers to the company's own network: our technology adapts perfectly to your security requirements. The Milliarum AI Construction Kit includes a generic AI chat for interaction with the AI as well as a customizing environment for individual configuration of the applications and for connecting various large language models (LLMs). The General chatbot makes SAP functions easier to use and can be adapted for specific application scenarios, such as calling up sales orders, via customizing. Equipped with individually tailored access to company-specific data, this leads to more efficient knowledge management and supports the processing of SAP functions.

10 steps to an AI chatbot for order progress in SAP:

1. start the App Manager
In the SAP system, open the Construction Kit App Manager (/MILUM/5GCORB_AI_CUA or /MILUM/5GCORB_AI_CUL).
Search for the entry Generic AI chat and open the customizing menu.

2. create Managed Datasource
In the Managed Datasource Manager create a new data source, e.g.
ID: ZSD_DEMO_HOWTO
Designation: SD Expert Demo
Save the entries.

3. define managed entity
Create an entity that describes the business use case.
Example:
ID: ZSALES_ORDER
Designation: Overview of all customer orders
The basis is the CDS view I_SALESORDER.

4. add leading data part with CDS-View
Link the CDS view to your entity:

  • Name: z. E.G. ZSALES_ORD
  • Core: /MILUM/GAGDS_DSRC_CDS_DYN
  • CDS-View: I_SALESORDER

Save the configuration.

5. select attributes
Select the fields that you want the chatbot to display later, e.g:

  • SALESORDER (order number)
  • SALESORDERDATE (date)
  • OVERALLTOTALDELIVERYSTATUS (overall delivery status)
  • TOTALNETAMOUNT (net amount)
  • TRANSACTIONCURRENCY (currency)

Define the primary key, generate and save the attributes.

6. create a persona
Define how the chatbot "thinks" and speaks:

  • Persona ID: SD_HOW_DEMO
  • Designation: SD Expert sales order info
  • LLM: z. e.g. GPT-4o via OpenAI Connector

Formulate the system prompt to focus the chatbot on the SAP SD context.

7. configure function
Specify which data source the chatbot uses:

  • Functional class: /MILUM/5GAICB_F_AI_FUNC_MDSRC
  • Function ID: ZSD_DEMO_HOWTO-ZSALES_ORDER-R
  • Description: z. B. List of all customer orders

Save the function.

8. assign persona
In application customizing, you assign the created persona to the chatbot so that it can access the new function.

9. perform test
Select the persona in the chat and enter e.g:
"Show me all customer orders"
Check whether the table is displayed correctly with the selected attributes.

10. fine-tuning with variants & dependent data parts (optional)

  • VariantsChange the column order, rename fields or set sort orders.
  • Dependent Data PartsInclude additional information from other CDS views, e.g. the continuous text for the delivery status instead of the SAP code.

We go through the individual steps in the "KI-Chatbot SD configuration" documentation, which you can download here. here download, with you.

Published On: 28. August 2025Categories: Allgemein, KI

You might also be interested in

The Milliarum Blog

Would you like to improve portfolio, project and resource management in your company? We have been specializing in the design, integration and operation of SAP solutions for over 15 years.

Subscribe to our newsletter

Recent Posts