1. Olan Knight
  2. PowerBuilder
  3. Wednesday, 1 July 2020 22:18 PM UTC

PB2019R2, b2328
Windows 10, 64 bit platform
32 bit application comprised of a single PBL
No PFC

Summary:
  Why in the world is the retrieval failing?


Details:
This is the first app we are testing using PB2019R2, so please forgive me if I'm making dumb RTFM mistakes.


When the dw_retrieve in our window is executed it runs fine in the IDE, but generates an error from the EXE. The entirety of the error msg is:        "dw_1 retrieval experienced an error:  -1"

The EXE is placed on a network drive, the runtime DLLs are in the same drive.



In addition, the PATH includes this folder:
    C:\Program Files (x86)\Appeon\Shared\PowerBuilder


It's not a complex retrieval:




Thank You,

Olan

 

 

 

 

Olan Knight Accepted Answer Pending Moderation
  1. Monday, 6 July 2020 15:10 PM UTC
  2. PowerBuilder
  3. # 1

Monday, 06-JUL-2020

Many thanks to everyone who contributed to this thread. It is greatly appreciated: Chris, Miguel, Rene, Ricardo, and BKR!


Summary:
   Creating a PBD resolved the retrieve issue! We now have a work-around.

   This is not how PBv12.1 behaves. I would like to know why not having a PBD causes the retrieve error, and what can be done to create a single EXE with no PBD that will work successfully.


Details:
1.  I created a PBR file that included every single datawondow object in the one PBL that comprises the utility.
 
     Since every dwo is included in the PBL, I entered each dwo as follows:
d_input_file
d_output_file
dddw_bill_fccid
.
.
.
      The utility regenerated, and a Full Build was successfull, but during the deploy process I received an error message for every DWO listed in the PBR:   object cannot be found.

 

2. Next, I restored my blank PBR, checked the PBR checkbox in the project file, and deployed.
    This created an EXE with an EXE + PBD file.

     No DLLs were deployed, so the PATH was the only object that pointed to the runtime files located in the Shared directory.

    THIS time the executable has no problems retrieving DW_1.

Comment
  1. Miguel Leeuwe
  2. Monday, 6 July 2020 17:33 PM UTC
Personally I prefer to use PBD's. No need for PBR except for your images, but if for small non-pbd executables, you'd rather not use a pbr file and you don't have too many datawindow objects that you assign dynamically (like when specifying them as the dataobject for a datastore in your code), then there something else you could do:



1) create a dummy userobject / window

2) paste a dw control for each of the datawindows and assign them to the controls.

3) save the userobject / window to a library



That way the compiler should automatically include them in the exe without the need for a pbr file or compiling with pdb.

regards, glad you solved it.
  1. Helpful
  1. Olan Knight
  2. Monday, 6 July 2020 22:07 PM UTC
Thanks for the idea, Miguel!
  1. Helpful
  1. René Ullrich
  2. Tuesday, 7 July 2020 05:16 AM UTC
If you want to add datawindow objects to PBR you have to do it like described in the help file:

"To include a DataWindow object in the list, enter the name of the library (with extension PBL) followed by the DataWindow object name enclosed in parentheses."
  1. Helpful
There are no comments made yet.
Roland Smith Accepted Answer Pending Moderation
  1. Monday, 6 July 2020 14:49 PM UTC
  2. PowerBuilder
  3. # 2

When creating an EXE without PBD files, all DataWindow objects must be listed in a .PBR file. The retrieve fails because the DataWindow object doesn't exist in the EXE.

Comment
  1. Roland Smith
  2. Monday, 6 July 2020 14:51 PM UTC
And as someone else noted, you need ATL100.DLL not ATL71.DLL.
  1. Helpful
  1. Olan Knight
  2. Monday, 6 July 2020 15:58 PM UTC
Got it, thanks for the reminder.
  1. Helpful
There are no comments made yet.
Miguel Leeuwe Accepted Answer Pending Moderation
  1. Sunday, 5 July 2020 05:11 AM UTC
  2. PowerBuilder
  3. # 3

Hi,

The first thing that comes to mind is a missing entry for your datawindow's dataobject in the PBR file, like Rene already said.

Just as a test: create your executable as PCode, marking the PBD checkbox(es) and see if the retrieve still fails.

By any change, you wouldn't have 2 datawindows with long names of which only the last part of the names are different? (so the first big part of the names are the same? I've seen that fail quite a few times).

I'm wondering if you have powerbuilder DLL's in the shared folder and also some in the folder of you executable, there might be something going wrong. See what happens if you take the shared folder out of the PATH or even better: delete the powerbuilder dlls from the folder where your executable is (and do leave the shared folder in the path).

regards

Comment
There are no comments made yet.
Ricardo Jasso Accepted Answer Pending Moderation
  1. Sunday, 5 July 2020 01:45 AM UTC
  2. PowerBuilder
  3. # 4

There are some really old files in your DLL folder like atl71.dll and Otsw32.dll. Besides, PB2019 now uses atl100.dll.

Comment
There are no comments made yet.
Sivaprakash BKR Accepted Answer Pending Moderation
  1. Thursday, 2 July 2020 06:41 AM UTC
  2. PowerBuilder
  3. # 5

Though not specific to PB2019xx

I've experienced this type of error in earlier PB's.  You could try,

1.   Re-compile, after deleting all PDB's, and check.
2.   Check whether the runtime matches the IDE and there is no conflict.  Check for old / beta runtime files elsewhere.
3.   See the PBD contains the required DW and is there in the folder.

HTH

 

 

Comment
  1. Olan Knight
  2. Friday, 3 July 2020 22:43 PM UTC
Thank you for your reponse!



We have JUST NOW started the conversion of out code from PBv12.1 to PB2019. This is the first application to be fully migrated and executed - and it's not working. :(



It works in the IDE, you've seen the list of DLLs (above) deployed with the EXE, we always do a FULL BUILD, then a DEPLOY. There are no olders versions of Appeon PB.
  1. Helpful
There are no comments made yet.
René Ullrich Accepted Answer Pending Moderation
  1. Thursday, 2 July 2020 05:24 AM UTC
  2. PowerBuilder
  3. # 6

Hi Olan,

I see no PBD in your screenshot. Maybe the Datawindow Object is missing in your compiled exe? Try to add it in PBR file so the compiler adds it to the exe. (see "Creating a PowerBuilder resource file").

HTH,

René

Comment
  1. Olan Knight
  2. Friday, 3 July 2020 22:44 PM UTC
Correct: we compile everything into the EXE, so no PBD is created or required.



We do this with the small utilities that we have; our Giganto Mondo main app is created with PBDs.
  1. Helpful
  1. René Ullrich
  2. Monday, 6 July 2020 05:15 AM UTC
So I guess the datawindow object is missing in your EXE. Have you checked the return code of SetTransObject function? If it is -1 the missing datawindow object could be the reason. If is is 1 there must be another problem.
  1. Helpful
  1. Ricardo Jasso
  2. Monday, 6 July 2020 14:09 PM UTC
A surefire way to know if the dwo is missing in the EXE will be to select all the PBD checkboxes in the Libraries tab of the application project and build the EXE again. Just make sure to copy all the EXE and PBD files to the runtime folder before running it.
  1. Helpful
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Wednesday, 1 July 2020 22:42 PM UTC
  2. PowerBuilder
  3. # 7

Hi Olan;

 Did you code the DC/DS "Error" and "DBError" events in order to catch the specific DBMS error?

  Also, if the above is done and still no useful information is found to resolve your issue - then don't forget to try an SQL Trace (sqlca.dbms " TRACE xxx").

Regards ... Chris

Comment
  1. Olan Knight
  2. Friday, 3 July 2020 22:46 PM UTC
This is a DW on a window, and code in the DBERROR event ofthe DW control was never triggered.

Sadly, code in the SystemError event of the window did not generate anything either. I'm at a complete loss!



I'll try the SQL TRACE, but I think this is a deployment issue of some sort because it works in the IDE without error.
  1. Helpful
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.