1. ATK Gimmy Susan
  2. PowerBuilder
  3. Saturday, 4 April 2020 17:16 PM UTC

hello Community

I have to carry out a massive conversion of the datawindows of my application to bring it from oralce to postgresql.

Unfortunately, the application was developed by setting the parameter of 'Outer Join Syntax' to 'PB'.

This annoys PostgreSQL. I have to convert that parameter to 'ANSI'.

 

Which is the best strategy?

 

Thanks in advance for your reply

 

GMY

Accepted Answer
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Saturday, 4 April 2020 18:02 PM UTC
  2. PowerBuilder
  3. # Permalink

Hi Gimmy;

   The LibraryExport () and LibraryImport () commands work on DW objects. So you could write a utility to walk through all the DWOs  via the libraryDirectory() command. Changing all the PB join syntax to ANSI.

Food for thought. HTH

Regards... Chris

Comment
  1. ATK Gimmy Susan
  2. Saturday, 4 April 2020 19:22 PM UTC
Hi Chris thanks for answer



Cool.

It sounds nice.



For changing all pb jo to an ansi jo; is there some to do it or I have to do it my self .....

It is not really easy.



  1. Helpful
  1. Chris Pollach @Appeon
  2. Saturday, 4 April 2020 20:34 PM UTC
The only caveat is if the DWO uses a real SQL statement vs a "PBSELECT". The latter means that the DWO creates the various DML commands "on-the-fly". So changing the join type in the DWO source should be all you need to do. However, if the previous PB developers "hard coded" the SQL statement then you would need to *manually* rewrite the SQL statement. When I taught the PB courses for PowerSoft & then Sybase, I always stressed about using the PBSELECT and never hard coding the SQL in a DWO for just this type of reasons. At least with your utility though, you can identify the non-PBSelect DWOs and then create a manual ToDo list.

BTW, I created a PB utility for doing almost all of what I described. You are welcome to download & modify it for your purposes.

FYI: http://chrispollach.blogspot.com/2017/11/sqlx.html



HTH

Regards ... Chris
  1. Helpful
There are no comments made yet.


There are replies in this question but you are not allowed to view the replies from this question.
We use cookies which are necessary for the proper functioning of our websites. We also use cookies to analyze our traffic, improve your experience and provide social media features. If you continue to use this site, you consent to our use of cookies.