Skip to content
Using OpenAI to write AL code for Business Central

Writing code with a text-based AI for Business Central

Daniel Gorski
Daniel Gorski 03. Dezember 2022
2 Min. Lesezeit

What/Who is OpenAI?

OpenAI was founded in 2015 by a group of leading researchers and tech industry figures, including Elon Musk and Sam Altman. The organization's mission is to develop and promote friendly AI that will benefit humanity as a whole. To achieve this goal, OpenAI conducts cutting-edge research in areas such as machine learning, natural language processing, and computer vision.

https://openai.com/

How does it work?

Login or register on openai.com and start a new thread:

Ask anything you want:

Nice :)!

So lets go for the next one:

Pretty cool! And what about some specific requirements?

And now AL code:

Wow, not bad or? Ok you need to adjust some properties but overall it's pretty cool:

table 50100 "Gift Card"
{
    DataClassification = CustomerContent;
    fields
    {
        field(1; "Gift Card ID"; Code[20])
        {
            DataClassification = CustomerContent;
        }
        field(2; "Card Number"; Code[20])
        {
            DataClassification = CustomerContent;
        }
        field(3; "Expiration Date"; Date)
        {
            DataClassification = CustomerContent;
        }
        field(4; "Card Value"; Decimal)
        {
            DataClassification = CustomerContent;
        }
        field(5; "Customer ID"; Code[20])
        {
            DataClassification = CustomerContent;
        }
    }
    keys
    {
        key(PK; "Gift Card ID")
        {
            Clustered = true;
        }
    }
}

page 50100 "Gift Card Details"
{
    layout
    {
        area(Content)
        {
            group("Card Information")
            {
                field("Card Number"; "Card Number")
                {
                }
                field("Expiration Date"; "Expiration Date")
                {
                }
                field("Card Value"; "Card Value")
                {
                }
                field("Customer"; "Customer ID")
                {
                }
            }
        }
    }
}

how-to
tools & ai
business central
al development
openai
ai tools
productivity
GoBD-konforme Archivierung mit Business Central und SharePoint ohne DMS

Architektur

Revisionssicher archivieren ohne DMS? Wie weit Business Central, SharePoint und Azure Blob Storage wirklich tragen

Warum „GoBD" oft vorschnell zum K.O.-Kriterium wird – und wie weit Business Central, SharePoint und Azure Blob Storage wirklich tragen.

Read More: Revisionssicher archivieren ohne DMS? Wie weit Business Central, SharePoint und Azure Blob Storage wirklich tragen
Read More: Revisionssicher archivieren ohne DMS? Wie weit Business Central, SharePoint und Azure Blob Storage wirklich tragen
Modulare ERP-Architektur für skalierbare Unternehmenssoftware

Architektur

Mehr als nur Warenwirtschaft - die Landtechnik Lösung

ERP-Systeme wurden jahrelang als Monolithen verkauft. Die eigentliche Stärke moderner Plattformen wie Business Central liegt jedoch in der Modularität - und gen

Read More: Mehr als nur Warenwirtschaft - die Landtechnik Lösung
Read More: Mehr als nur Warenwirtschaft - die Landtechnik Lösung