Field WorkerName is not compatible with field WorkerName

This post provides insight about a synchronize error received during full AOT for AOT view 'ProjUnpostedTransView' and its resolution.

ProjUnpostedTransView: Synchronize database there is a field mismatch in the union query. Field WorkerName is not compatible with field WorkerName.

As per mentioned in the synchronize database error (1), all the errors have come in the View, 'ProjUnpostedTransView'. Exploring the same yields the composition of the view on following sub views.

1.       ProjLedgerJournalTransUnpostedView
2.       TrvExpTransDistributionsUnposted
3.       ProjJournalTransFeeUnpostedView
4.       projCustInvoiceLineDistsUnpostedView
5.       ProjJournalTransHourUnpostedView
6.       ProjProdJournalRouteUnpostedView
7.       InventJournalTransUnpostedView
8.       ProjProdJournalBOMUnpostedView
9.       VendInvoiceInfoLineDistributionsUnposted
10.   ProjOnAccTransUnpostedView
11.   ProjIntercompanyUnpostedExpView
12.   TSUnpostedTimesheetLinesAllView
13.   ProjIntercompanyUnpostedTSView
14.   ProjIntercompanyUnpostedVendInvLineView

Each of these views comprise of one or more tables. And each of these views as a data source has the HCMWorker data source with in further relating to DirPartyTable to fetch the worker name. Closely monitoring each of them reveals that the following four data sources were returning null for the worker name. Obviously the logic implemented would have required the field (since a union query) to have a consistent schema returned. Further to returning null, the fields were provided the extended type, "Name" which was different from what is returned from DirPartyTable > Name field which extends "DirPartyName" extended type.

Data sources with inconsistent extended types
projCustInvoiceLineDistsUnpostedView
ProjProdJournalBOMUnpostedView
ProjInventJournalTransUnpostedView
ProjOnAccTransUnpostedView

Due to this EDT mismatch, the AOT framework was giving errors.

Providing the correct extended type of DirPartyName to the WorkerName fields for each of these views made the schema fully consistent, hence error removed.
First