Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide name of read-only column incorrectly referenced in UPDATE ... SET xxx [CORE5874] #6133

Closed
firebird-automations opened this issue Jul 12, 2018 · 11 comments

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: Maxim Kuzmin (cybermax)

When preparing UPDATE-query with updating calculated column, FB return error:
"This column cannot be updated because it is derived from an SQL function or expression.
attempted update of read-only column."

And here not known what a "This" column.
The message should look like
"Column "CALCULATED_FIELD" cannot be updated because it is derived from an SQL function or expression."

Commits: 32ca23b

@firebird-automations
Copy link
Collaborator Author

Modified by: Sean Leyne (seanleyne)

summary: Provide name of read-only column => Provide name of read-only column incorrectly referenced in UPDATE ... SET xxx

@firebird-automations
Copy link
Collaborator Author

Modified by: @asfernandes

assignee: Adriano dos Santos Fernandes [ asfernandes ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @asfernandes

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

Fix Version: 4.0 Beta 1 [ 10750 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Resolved [ 5 ] => Resolved [ 5 ]

QA Status: No test => Done successfully

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Resolved [ 5 ] => Closed [ 6 ]

@CyberMaxRu
Copy link

I'm test a ticket. FB 4.0.2.2770.
CREATE TABLE TEST_UPDATE_RC_COLUMN (
ID INTEGER,
NEXT_ID COMPUTED BY (id + 1))

UPDATE TEST_UPDATE_RC_COLUMN SET NEXT_ID = 1

"This column cannot be updated because it is derived from an SQL function or expression.
attempted update of read-only column."

And there no name of column.

@mrotteveel
Copy link
Member

@CyberMaxRu Please create a new issue for regressions, and reference this issue for context.

However, please provide exact reproduction steps, as I cannot reproduce this using ISQL (4.0.1 and 4.0.2.2775).

@mrotteveel
Copy link
Member

Also double check the version you're using with

select rdb$get_context('SYSTEM', 'ENGINE_VERSION') from rdb$database;

@CyberMaxRu
Copy link

@mrotteveel In isql works fine. Apparently, the access components (FIB+) and the IBExpert do not see that there is also a column name there. I'm embarrassed - the ticket seems to have been made, but in fact I can't use it.

@asfernandes
Copy link
Member

Do you have updated (v4) firebird.msg and fbclient in the client?

@CyberMaxRu
Copy link

CyberMaxRu commented Jun 9, 2022

@asfernandes On all our servers of client application, after the update to 4.0, there was a firebird.msg from 3.0 (in system32 and SysWOW64). After replace, column name appeared. Thanks for help!
P.S. It lacks the ability to check which firebird.msg is being used by the fbclient.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants