Project

General

Profile

Actions

Bug #91178

open

Applying needed DB change fails in BE using PostgreSQL

Added by Tobias Diekershoff over 4 years ago. Updated 4 months ago.

Status:
New
Priority:
Should have
Assignee:
Category:
Database API (Doctrine DBAL)
Target version:
-
Start date:
2020-04-23
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
10
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

On Typo3 9.5.15 using PostgreSQL.

Using "Analyse Database Structure" from the Admin Tools I get the following needed change listed

ALTER TABLE "sys_file_processedfile" ALTER "configuration" TYPE BYTEA 
Current value: configuration TEXT DEFAULT NULL

When applying the change the following error is shown

Database update failed
Error: SQLSTATE[42804]: Datatype mismatch: 7 FEHLER:  Spalte »configuration« kann nicht automatisch in Typ bytea umgewandelt werden
HINT:  Sie müssen möglicherweise »USING configuration::bytea« angeben.

I followed the documented migration from a non-composer installation to composer based installation. After the migration was done, checking the DB structure I encountered this error.

PS: I hope this is the right place to report exceptions found by normal users, if not please redirect me.


Related issues 1 (1 open0 closed)

Related to TYPO3 Core - Epic #90719: PostgreSQL related issuesAccepted2020-03-10

Actions
Actions #1

Updated by Tobias Diekershoff over 4 years ago

Applying

ALTER TABLE "sys_file_processedfile" ALTER "configuration" TYPE BYTEA USING configuration::bytea;

manually in psql clears the needed changes.

Actions #2

Updated by Stephan Großberndt almost 4 years ago

  • Related to Epic #90719: PostgreSQL related issues added
Actions #3

Updated by Stefan Bürk about 2 years ago

  • Assignee set to Stefan Bürk
  • TYPO3 Version changed from 9 to 10
  • PHP Version deleted (7.3)

This is a generic "issue". If a field is changed from "text" to "blob" for example, this error will be thrown during database compare changes on postgres.
This can be also reproduced with current "main" (v12) and doctrine/dbal 3.2.

TYPO3 v9 is out of community support, so I will change the TYPO3 version for now.

Actions #4

Updated by Garvin Hicking 4 months ago

  • Category set to Database API (Doctrine DBAL)

(may need a check to verify this for v13?)

Actions

Also available in: Atom PDF