1. James Medick
  2. PowerBuilder
  3. Monday, 17 December 2018 22:47 PM UTC

I have the latest build of PB on windows 10.  I'm using MySQL db and have the aggravating issue of not being able to generate or use the system catalog tables.  I've tried DBA, DBO, Admin, Sys, and blank in the table owner field on the DB profile with no success.  I can access my tables and connect easily - just not the PB tables.

This question has probably been asked 100 times but I can't find it anywhere in the history.

J

Accepted Answer
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Thursday, 20 December 2018 19:53 PM UTC
  2. PowerBuilder
  3. # Permalink

Hi James;

   I worked through the MySQL stuff last night on my Laptop by installing and configuring MySQL 8.0.13 from scratch. Here is what I found and how to make it work with PB2017R3 and PS2017R3 ...

1) The MySQL Installer only allows you to install one ODBC client type - either 32 or 64 bit. It shows you both but, when you pick one - you cannot pick the other. So make sure that you download the alternate ODBC bitness driver MSI as you will need to run this manually.

2) The ODBC drivers and some other MySQL components (ie: WorkBench) may not install and give a C++ 2010 Redistribution files missing message. The actual problem could be a bad C++ 2017 Redistribution installation that corrupted the 2010 registry entries. To correct this, perform a "repair" on the "C++ 2017 Redistribution" package. Make sure that you repair both the 32bit and 64bit packages!

3) Using the 32bit ODBC Administrator, create a MySQL System DSN for your PB IDE connection.

For example:

4) Using the 64bit ODBC Administrator, create a MySQL System DSN for your PowerServer connection.

5) Create a PB IDE DB Profile to connect to MySQL DB using the 32bit DSN. To make sure that the PBCAT tables are created ... make sure that you use the "Schema" name as the DB Owner - as follows:

6) Connect to your MySQL database. You should not get any errors. Then use PB IDE Painter to verify that the PBCat tables were indeed created.

7) You can even use MySQL's "Work Bench" product (DB Console) to re-verify ...

8) In PowerServer, you can try and connect to the newer MySQL DB releases - but the current native driver only supports the older 5.x MySQL releases. If you create a Data Source in AEM and try & connect ... it will fail.

9) Instead, create a 64 bit ODBC System DSN Using the 64 bit MySQL driver

10) Now create an ODBC Data Source connection to MySQL in PowerServer, as follows:

 

  From this point on-wards ..  both the PB IDE, its Apps and PowerServer are working well with the latest MySQL (for me).

 

HTH

Regards ... Chris

Comment
There are no comments made yet.
Louis Arena Accepted Answer Pending Moderation
  1. Thursday, 30 July 2020 19:40 PM UTC
  2. PowerBuilder
  3. # 1

I am having the same problem.  I am using MySQL through AWS, connecting with ODBC 32 bit drivers.  I have the current versions of everything as I installed everything today.  I get the catalog table error when connecting to the database, however the 5 catalog tables exist in the schema.  Additionally, when I connect to a MS SQL server, I do not get the error and the tables also exist in SQL.  In both MySQL and SQL the tables are in lower case so not sure what the previous comment was about PC looking for upper case table names.

 

Comment
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Wednesday, 11 December 2019 17:30 PM UTC
  2. PowerBuilder
  3. # 2

Hi Peter;

  The key for using the PBCATxxx tables in my setting up of MySQL environment was to make sure that I set the "PowerBuilder Catalog System Owner" in the DB Profile connection settings.

HTH

Regards ... Chris

Comment
There are no comments made yet.
moritz nölting Accepted Answer Pending Moderation
  1. Wednesday, 11 December 2019 13:03 PM UTC
  2. PowerBuilder
  3. # 3

hi,

i've got the same problem.

mysql server version 8.0.18, mysql odbc-connector 8.0.18, powerbuilder version 2019.2082.

i've created the database root  and set the catalog table owner to root. at the first connection it works and the pb* tables were created. the second and up connection won't work, i've got the message "catalog tables could not be created and are not available for use."

the user connecting to the database has all possible rights for every database at the server.

 

regards

moritz

Comment
There are no comments made yet.
James Medick Accepted Answer Pending Moderation
  1. Wednesday, 5 June 2019 16:02 PM UTC
  2. PowerBuilder
  3. # 4

Yes, I have the same issues using PB and MYSQL.  Got tired of trying to find the magic configuration so I gave up.  I never connect to the PB tables.

Comment
There are no comments made yet.
Peter Piechutzki Accepted Answer Pending Moderation
  1. Wednesday, 5 June 2019 09:16 AM UTC
  2. PowerBuilder
  3. # 5

Hi Chris,

once again, this Issue is not resolved and although creating totally new schema's including (imho useless) 'root' schema pb just won't use catalog tables. As I see it, pb is mixing table owners and schema names within connection to database. Why else would we have to set Schema name in Database profile as catalog owner on first connect?

To my dislike logging with odbc trace brings absolutely no hint (see attached dblog.txt  1st Connection with world , 2nd connection as root, 3rd connection nothing set as pbcat owner.

adding a schema 'root' unluckily does't help whatsoever. If I set catalog table owner in db profile to 'root' it works only on first connect once again, resulting in Pbcat tables in both 'world' and 'root' schema. No matter what i set as catalog table owner after that, i get same result that pbcat tables can not be created...

I'm very frustrated, already having spent hours and usless tries creating a usefull PB connection to current MySQL Database 8 with current MySQL ODBC Drivers.

Any help on this matter would really be appreceated!

regards Peter

 

 

 

Attachments (7)
Comment
  1. Peter Piechutzki
  2. Wednesday, 5 June 2019 10:36 AM UTC
One more thing, try creating a datawindow, all goes fine, data is shown. go into 'specifiy update properties'. change something like 'Use Update' instead of 'Use Delete then Insert', click o.k. result is 'table 'country' not fond, Use table name anyway?'
  1. Helpful
  1. Chris Pollach @Appeon
  2. Thursday, 6 June 2019 17:56 PM UTC


Hi Peter;



No issues for me re-connecting to PostgreSQL at any time and using the PBCATxxx tables without any error messages once I created the extra schema (as previous post above).



One other thing to try .. make sure that in your DB Profile for PG that your have set the "Enclose Table and Column Name in Quotes" property to ON in the "Syntax" tab of the that dialogue.



HTH



Regards ... Chris
  1. Helpful
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Wednesday, 29 May 2019 16:24 PM UTC
  2. PowerBuilder
  3. # 6

Hi Peter;

  Yes, I found that reconnecting to the MySQL DB a 2nd time also came up with the same message that the PBCATxxx tables were not there or useable!

  Here is what I did to fix this problem (not a PB issue .. its MySQL), as follows:

MySQLWorkBench: use RHMB on "root" under Table Privileges and select "Create Schema" from pop-up menu!

 

 Part 2:  Create a new Schema called "root" within your new DB.

 

My PBCATxxx Table access issue then went away and the PB IDE was able to connect and use the PBCATxxx tables without error.

 

HTH

Regards ... Chris

Comment
There are no comments made yet.
Peter Piechutzki Accepted Answer Pending Moderation
  1. Tuesday, 28 May 2019 14:14 PM UTC
  2. PowerBuilder
  3. # 7

I think it may have to to with pbcat tables in schema being lowercase and Powerbuilder looking for Uppercase PBCAT Tables as in following dbtrace log

PB170           31f8-2530    EXIT  SQLTablesW  with return code 0 (SQL_SUCCESS)
        HSTMT               0x047D0CB8
        WCHAR *             0x00000000
        SWORD                        0
        WCHAR *             0x02F93080 [       6] "myschema"
        SWORD                        6
        WCHAR *             0x008FA810 [      -3] "PBCATTBL\ 0"
        SWORD                       -3
        WCHAR *             0x00000000
        SWORD                        0

PB170           31f8-2530    ENTER SQLFetch
        HSTMT               0x047D0CB8

PB170           31f8-2530    EXIT  SQLFetch  with return code 100 (SQL_NO_DATA_FOUND)
        HSTMT               0x047D0CB8

Comment
There are no comments made yet.
Peter Piechutzki Accepted Answer Pending Moderation
  1. Tuesday, 28 May 2019 13:38 PM UTC
  2. PowerBuilder
  3. # 8

Hi Chris,

not really resolved. Have you disconnected and connected again? Using MySql ODBC 8.0 Unicode Driver 8.00.16.00 against a MySQL Server 8.0.16

On the first connect pbcat... Tables are created without errors or messages coming from PB 2017R3 Build 1880

On disconnect and connect again PB gives Error Message, that Catalog Tables Cannot be Created... Although after that all Tables and its Columns. Views and so forth can be seen in PB IDE Database Browser. Even the pbcat if i select "show system tables".

By the way, same scenario using MySQL ODBC 8.0 Unicode Driver 8.00.16.00 against a MySQL Server 5.6.1.0 gives a total mess up. PB gives Error Message, that Catalog Tables Cannot be Created.... After that all Tables but No Columns can be seen in PB IDE Database Browser.

I've attached Imgae of Log file from ODBC Driver but it doesn't help me much. Can't really see whats going wrong on the PB side.

regards

 

Pete

Attachments (1)
Comment
  1. Alexandre Soares Campos
  2. Friday, 8 October 2021 01:13 AM UTC
to resolve this you need to put the PowerBuilder Catalog Table Owner and Table Owner too. In my case both are the name of the schema.
  1. Helpful
There are no comments made yet.
James Medick Accepted Answer Pending Moderation
  1. Wednesday, 19 December 2018 17:14 PM UTC
  2. PowerBuilder
  3. # 9

Yes, I see all 5 PBCAT tables

Comment
  1. Chris Pollach @Appeon
  2. Wednesday, 19 December 2018 17:21 PM UTC
Q1: Who is the "Owner" of the PBCAT tables in the MySQL Console?

Q2: Did you specify the PBCat table access in the current DB profile?

DB Profile => System tab => PowerBuilder Catalog Table Owner





  1. Helpful
There are no comments made yet.
James Medick Accepted Answer Pending Moderation
  1. Tuesday, 18 December 2018 19:51 PM UTC
  2. PowerBuilder
  3. # 10

MySQL 5.7.21

Connection is through ODBC with MySQL Connector 8.0.13 -win32

I connect fine to the DB, just not the PB catalog tables

 

Comment
  1. Chris Pollach @Appeon
  2. Tuesday, 18 December 2018 19:58 PM UTC
Thanks James!



If you connect to MySQL via its console ... do you see the PBCATxxxx tables?
  1. Helpful
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Tuesday, 18 December 2018 16:55 PM UTC
  2. PowerBuilder
  3. # 11

Hi James;

   Can you tell us ...

1) MySQL version & build?

2) Type of DB client that you are using to connect to MySQL with?

Regards ... Chris

Comment
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.