I am using the OpenEdgeDataProvider. I have a PDS defined as follows.
DEFINE DATASET dsPurchaseOrder FOR ttblPurchaseOrder, ttblPoLine, eBusiness, eStore, eVendor
DATA-RELATION ttblPurchaseOrder2ttblPoLine FOR ttblPurchaseOrder, ttblPoLine
RELATION-FIELDS (OrderNum,OrderNum,SeqNum,SeqNum)
Once I populate this PDS I then use the code below but the relation does not come over into LL. I tried using the LL:DataMember and setting to “ttblPurchaseOrder” but then I do not see ttblPoLine.
What am I missing?
oProvider = NEW OpenEdgeDataProvider ().
oDatasetService = NEW OpenEdgeDatasetService (iphDataset).
oDatasetService:TablePrefixToRemove = “e”.
oProvider:ServiceName = oDatasetService:ServiceName.
oProvider:ServiceAdapter = NEW OpenEdgeDatasetServiceAdapter (oDatasetService).
oProvider:Initialize().
The DataProvider registers relations with ListLabel.OpenEdgeAdapter.OpenEdgeSchema.cls
It needs to know who’s the parent of a relation and who’s the child.
The parent is the one that has a unique index on the relation fields. ( Same for database tables).
So in your case this unique index may be missing in your ttblPurchaseOrder.
This code worked for me (LL26).
USING TasteITConsulting.Reporting.OpenEdgeDataProvider FROM ASSEMBLY.
USING combit.Reporting.ListLabel FROM ASSEMBLY.
USING ListLabel.OpenEdgeAdapter.OpenEdgeDatasetService FROM PROPATH.
USING ListLabel.OpenEdgeAdapter.OpenEdgeDatasetServiceAdapter FROM PROPATH.
/* A parent table in a relation needs to have a unique key on the relation-fields.*/
DEFINE TEMP-TABLE ttblPurchaseOrder NO-UNDO
FIELD OrderNum AS INTEGER
FIELD SeqNum AS INTEGER
INDEX pk IS PRIMARY UNIQUE OrderNum SeqNum.
DEFINE TEMP-TABLE ttblPoLine NO-UNDO
FIELD OrderNum AS INTEGER
FIELD SeqNum AS INTEGER
FIELD LineNum AS INTEGER
INDEX pk IS PRIMARY UNIQUE OrderNum SeqNum LineNum.
DEFINE DATASET dsPurchaseOrder FOR ttblPurchaseOrder, ttblPoLine
DATA-RELATION ttblPurchaseOrder2ttblPoLine FOR ttblPurchaseOrder, ttblPoLine
RELATION-FIELDS (OrderNum,OrderNum,SeqNum,SeqNum).
DEFINE VARIABLE oProvider AS OpenEdgeDataProvider NO-UNDO.
DEFINE VARIABLE oDatasetService AS OpenEdgeDatasetService NO-UNDO.
DEFINE VARIABLE oLL AS ListLabel NO-UNDO.
oProvider = NEW OpenEdgeDataProvider ().
oDatasetService = NEW OpenEdgeDatasetService (DATASET dsPurchaseOrder:HANDLE).
oProvider:ServiceName = oDatasetService:ServiceName.
oProvider:ServiceAdapter = NEW OpenEdgeDatasetServiceAdapter (oDatasetService).
oProvider:Initialize().
oLL = NEW ListLabel().
oLL:DataSource = oProvider.
oLL:ForceSingleThread = TRUE.
oLL:Design().
oLL:Dispose().
oProvider:Dispose().
That is odd as your code is exactly the same as mine except I am using LL24.
I will try using LL26.
Thomas,
I downloaded LL26 and then the latest OpenEdgeDataProvider from your site. The BETA version download for LL26 still says v 25. Is this correct?
Hi Roger,
the code is not on my website yet. But you can use everything from the LL distribution. It’s the same I have except some more samples (that are also in LL24 - L25).
I will update my website soon.
Regarding your problem: That the relation is missing is not a problem of DP code (C#, ABL) it’s because of the - probably - missing unique index on the po. Have you checked this?
If you decide to use LL26 please also have a look at this here OpenEdge DataProvider Bug in LL26
You can also send me your entire dataset (via email) and I can have a look at it and try it locally.
Best regards,
Thomas
I have the ABL code from the LL distribution. I was referring to the TasteITConsulting.ListLabel dll.
I do have unique indexes on my TT.
I found the assembly embedded in the LL samples folder…thanks

Then it should work. Otherwise send me the dataset.
Any idea why the OpenEdgeService.cls would not compile with error “Could not find class or interface ListLabel.OpenEdgeAdapter.OpenEdgeCalculatedTableArgs”

I don’t even see this listed in the classbrowser.
If that class should be distributed with the LL distribution it is not. I grabbed the one had from before.
The LL 26 Data Provider full source code (ABL, C#) is now available on my website.
https://www.taste-consulting.de/downloads/
1 Like
Thanks Thomas. This is now working great.
1 Like
Perfect! I couldn’t imagine it wouldn’t work because it always works for me.
Hello Thomas, is there an updated TasteITConsulting.ListLabel29 for the lastest V29 SP? I have downloaded the latest V29 of Combit and now the TasteITConsulting.ListLabel29 will no longer work.
Hi Roger,
What kind of errors do you get?
I am currently using LL30 and there are no problems. When I make changes, I send them to combit and what is in the examples on the distibution should be correct and you have to use it in your application.
C:\Program Files (x86)\combit\LL29\Beispiele\Progress\OpenEdge\Assemblies: combit.ListLabelXX.dll, TasteITConsulting.ListLabelXX.dll (XX = version)
The ABL part:
C:\Program Files (x86)\combit\LL29\Beispiele\Progress\OpenEdge\ListLabel\OpenEdgeAdapter
In PDSOE you may have to replace both DLL in Referenced Assemblies (assemblies.xml) and recompile.
That should work.
1 Like
Hello Thomas,
PDSOE just does not see the TasteITConsulting DLL.
I have downloaded LL 30 and use the TasteITConsulting DLL provided and it is working using V30. We will move to that version.
Thank you.
1 Like