1. Samuel Schimitzek
  2. PowerBuilder
  3. Friday, 23 August 2019

Hello,

is there a tool to check the sql in all Datawindows in a workspace against the database?

We are migrating a huge project from Oracle to Postgres (sql join syntax has changed from (+) to "left outer join"). In some of the existing Datawindows Powerbuilder created a wrong join syntax.

The Advanced Powerbuilder Utilities from Bruce Armstrong didn't work.

 

Thanks

Samuel Schimitzek Accepted Answer Pending Moderation
0
Votes
Undo

Thanks for the useful hint.

PBLPeeper works great if i am connect to an oracle database (oracle native driver).

If i am connect to a postgres database via odbc, pblpeeper shows no errors.

But there should be many error messages, for example in dw's with "select sysdate cdate, col2, col3,... from table..." as postgres can't handle sysdate.

Comment
There are no comments made yet.
  1. Monday, 2 September 2019
  2. PowerBuilder
  3. # 1
Matthew Balent Accepted Answer Pending Moderation
1
Votes
Undo

Not that it helps you now, and I am involved in a very similar endeavor currently (and will be speaking about it at ELEVATE 2019) but if we had all switched to ANSI 92 compliant syntax (using JOIN syntax) 'back in the day' this wouldn't be much of an issue  today...

Hindsight is a beautiful, haunting thing...

Comment
There are no comments made yet.
  1. Friday, 23 August 2019
  2. PowerBuilder
  3. # 2
Andreas Mykonios Accepted Answer Pending Moderation
2
Votes
Undo

Hi.

For that I use PBLPeeper, which has a function like that.

You can try it. It's free...

http://www.techno-kitten.com/PBL_Peeper/Download/download.html

If it help's you, credits should go to Terry Voth.

 

Andreas.

Comment
There are no comments made yet.
  1. Friday, 23 August 2019
  2. PowerBuilder
  3. # 3
Chris Pollach Accepted Answer Pending Moderation
0
Votes
Undo

Hi Samuel;

1) I developed a PB utility many years ago that reconstitutes DW SQL exactly as it would be executed in production. The extracted SQL can then be saved to an external file. The utility is called SQLExtract

2) Once I extract the working SQL from any DWOs, I would then run this through Quest Software's SQL Optimizer product which would a) check the SQL and b) evaluate it for performance. The Quest utility would then recommend and even rewrite for me the SQL with the necessary changes.

Note: There are other products on the market that can help perform SQL syntax validation as well (see release notes link below)

HTH

Regards ... Chris

FYI: SQLExtract release.

Comment
There are no comments made yet.
  1. Friday, 23 August 2019
  2. PowerBuilder
  3. # 4
  • Page :
  • 1


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