web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Answered

what is different betwean joins and Exists joins in the D365FO

(0) ShareShare
ReportReport
Posted on by 130

Hi, 

i am new in Ax so i wrote small jobs normal joins and Exists joins both output same 10 records shows.

my doubt when to use joins?

when to use Exists joins?  also both joins same concept

HCMIqamaDetails iqamaDetails;
HCMIqamaProcess iqamaProcess; 

while select firstOnly10 iqamaDetails
join iqamaProcess 
where iqamaProcess.RecId == iqamaDetails.IqamaProcessRecId
{

info(strFmt("%1",iqamaDetails.IqamaProcessRecId));

}

HCMIqamaDetails iqamaDetails;
HCMIqamaProcess iqamaProcess; 

while select firstOnly10 iqamaDetails
Exists join iqamaProcess 
where iqamaProcess.RecId == iqamaDetails.IqamaProcessRecId
{

info(strFmt("%1",iqamaDetails.IqamaProcessRecId));

}

thanks

I have the same question (0)
  • Verified answer
    nmaenpaa Profile Picture
    101,166 Moderator on at

    Exist join will not return you the joined table buffer (iqamaprocess)

    Normal join will.

  • Verified answer
    André Arnaud de Calavon Profile Picture
    303,669 Super User 2026 Season 1 on at

    Hi WayToAX,

    The main difference between these option is that the normal join will also fetch the columns with all values from the SQL server whereas the exists join will only check if there is a record linked. The exists join will not fetch data from the joined table. The result: performance. If you don't need the field values of the joined table, then it is recommended to use exists join.

  • WaytoAx Profile Picture
    130 on at

    many thanks quickly replay Nikolaos,

    my doubt exist joins not return it is okay,  innor join & Exist joins both result same  

  • WaytoAx Profile Picture
    130 on at

    Many thanks Andre Sir.

  • Verified answer
    nmaenpaa Profile Picture
    101,166 Moderator on at

    You can try to print something from iqamaprocess (the joined table) to your infolog to notice the difference.

  • WaytoAx Profile Picture
    130 on at

    Info Message (12:47:00 pm) joins : 5637161092

    Info Message (12:47:00 pm) exists joins : 5637161092

    Info Message (12:47:00 pm) joins : 5637161117

    Info Message (12:47:00 pm) exists joins : 5637161117

    Info Message (12:47:00 pm) joins : 5637161116

    Info Message (12:47:00 pm) exists joins : 5637161116

    Info Message (12:47:00 pm) joins : 5637161095

    Info Message (12:47:00 pm) exists joins : 5637161095

    Info Message (12:47:00 pm) joins : 5637161093

    Info Message (12:47:00 pm) exists joins : 5637161093

    Info Message (12:47:00 pm) joins : 5637161098

    Info Message (12:47:00 pm) exists joins : 5637161098

    Info Message (12:47:00 pm) joins : 5637161099

    Info Message (12:47:00 pm) exists joins : 5637161099

    Info Message (12:47:00 pm) joins : 5637161115

    Info Message (12:47:00 pm) exists joins : 5637161115

    Info Message (12:47:00 pm) joins : 5637161100

    Info Message (12:47:00 pm) exists joins : 5637161100

    Info Message (12:47:00 pm) joins : 5637161101

    Info Message (12:47:00 pm) exists joins : 5637161101

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Giorgio Bonacorsi Profile Picture

Giorgio Bonacorsi 617

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 461 Super User 2026 Season 1

#3
Syed Haris Shah Profile Picture

Syed Haris Shah 298 Super User 2026 Season 1

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans