1. marko
  2. Valentina Studio
  3. 土, 6月 01 2024, 03:11 AM
  4.  メールで購読
Hello, I'm having some problems in the diagrammer when working against a postgresql15 server.
There seems to problems with table referencing and it is generating bad sql when hitting the Apply Changes button. This is in studio 13.10
I've tried to change a primary key and the sql references the wrong table. I'm working on ProductCost and the sql references BCOrderTest tables:
BEGIN;

-- CHANGE "PRIMARY KEY" OF "TABLE "ProductCost" ----------------
ALTER TABLE "public"."ProductCost" DROP CONSTRAINT IF EXISTS "BCOrderTest_pkey";
ALTER TABLE "public"."ProductCost" ADD CONSTRAINT "BCOrderTest_pkey" PRIMARY KEY( "ProductId", "CostNum" );
-- -------------------------------------------------------------

COMMIT;

screenshot attached
添付ファイル
コメント
There are no comments made yet.
marko 承諾済みの回答
Further to the previous, I'm finding that the diagrammer is not refreshing and showing the changes on the database. Here I have updated the primary key which is visible in PGAdmin4, yet the diagrammer still shows an asterisk on the table name and (incorrectly) generates sql code to create the primary key again.
添付ファイル
コメント
There are no comments made yet.
marko 承諾済みの回答
Closing the table in the diagrammer and then re-opening it clears the * changes flag. This is using the version14 beta.
コメント
There are no comments made yet.
Sergey Pashkov 承諾済みの回答
Hello Marko,

The "Primary Key Name" property of the "ProductCost" table was retrieved incorrectly; it contains the PK name from a different table. This can be checked in the Property Inspector panel (pk_name.png).

The query generation process uses the PK name only if it was previously defined.

Are there any other tables with the same issue now?

Currently, the Refresh button on the toolbar doesn't refresh the database schema. The schema can be refreshed for a separate schema within the Diagram Editor (refresh_schema.png) or for a database in the Schema Editor (refresh_db.png).
添付ファイル
コメント
There are no comments made yet.
marko 承諾済みの回答
I have not seen the wrong pk info since I moved to version 14beta.
I can work with manual refresh when necessary.
thanks for your help
Marko
コメント
There are no comments made yet.
marko 承諾済みの回答
Hi Sergey, I have been using 14beta quite a lot over the last days. There is still the occasional corrupution in the diagram editor where the wrong entities are presented. Restarting valentina solves the problem.
コメント
There are no comments made yet.
  • ページ :
  • 1


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

Categories

Announcements & News
  1. 0 subcategories
Valentina Studio
  1. 2 subcategories
Valentina Server
  1. 4 subcategories
Valentina Database ADK
  1. 0 subcategories
Valentina Reports ADK
  1. 0 subcategories
Other Discussions
  1. 2 subcategories
BETA Testing
  1. 0 subcategories
Education & Research
  1. 0 subcategories