Issue Details (XML | Word | Printable)

Key: CORE-2227
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Adriano dos Santos Fernandes
Reporter: Rui Cruz
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Firebird Core

Problem with column names with Accents and triggers

Created: 04/Dec/08 07:38 AM   Updated: 27/Apr/11 12:55 PM
Component/s: Engine
Affects Version/s: 2.1.0, 2.5 Alpha 1, 2.1.1
Fix Version/s: 2.1.2, 2.5 Beta 1

Time Tracking:
Not Specified

Environment: All
Issue Links:
Relate
 

Planning Status: Unspecified


 Description  « Hide
Triggers don't recognize column names with accents.

Test case:

/* ---------- x ---------------- */

RECREATE TABLE TESTING (
  "CÓDIGO" INTEGER
);

SET TERM §;
CREATE TRIGGER TESTING_I FOR TESTING
ACTIVE BEFORE INSERT POSITION 0
AS
BEGIN
  NEW."CÓDIGO" = 1;
END§

/* ---------- x ---------------- */

This gives the following error:

ISC ERROR CODE:335544343

ISC ERROR MESSAGE:
invalid request BLR at offset 22
column CÓDIGO is not defined in table TESTING


 All   Comments   Work Log   Change History   Version Control   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Dmitry Yemanov added a comment - 04/Dec/08 07:52 AM
What is your connection charset used?

Rui Cruz added a comment - 04/Dec/08 08:11 AM
ISO8859_1

Philippe Makowski added a comment - 04/Dec/08 07:05 PM - edited
Firebird version ?
Platform ?
tool ?

because under FB2.1 I can't reproduce it
(using isql and edit, so vi under MacOsx)

SQL> show trigger TESTING_I;

Triggers on Table TESTING:
TESTING_I, Sequence: 0, Type: BEFORE INSERT, Active
AS
BEGIN
  NEW."CÓDIGO" = 1;
END
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Rui Cruz added a comment - 05/Dec/08 06:56 AM
ISQL Version: WI-V2.1.1.17910 Firebird 2.1
Server version:
Firebird/x86/Windows NT (access method), version "WI-V2.1.0.17798 Firebird 2.1"
Firebird/x86/Windows NT (remote server), version "WI-V2.1.0.17798 Firebird 2.1/tcp (phobos)/P11"
Firebird/x86/Windows NT (remote interface), version "WI-V2.1.1.17910 Firebird 2.1/tcp (bacuz)/P11"
on disk structure version 11.1

...using IBOConsole or an ODBC driver and any client aplicattion...

Rui Cruz added a comment - 05/Dec/08 07:04 AM - edited
.. noticed that server version was different from client version and upgrade it.. same problem:

Philippe Makowski added a comment - 05/Dec/08 02:07 PM
The problem is related to the tool you are using
I tested again under Win32
isql
edit;
type in the editor :
SET NAMES ISO8859_1;
RECREATE TABLE TESTING (
 "CÓDIGO" INTEGER,
 "àéèù" INTEGER
);
COMMIT;
SET TERM ^;
CREATE TRIGGER TESTING_I FOR TESTING
ACTIVE BEFORE INSERT POSITION 0
AS
BEGIN
 NEW."CÓDIGO" = 1;
 NEW."àéèù" = 1;
END^
SET TERM ;^
COMMIT;

save the file, quit the editor

no problem
table and trigger are there.


Adriano dos Santos Fernandes added a comment - 05/Dec/08 02:20 PM
Philippe, MacOSX build should have a problem, because there is a problem and that test case doesn't work in Windows.

Rui Cruz added a comment - 05/Dec/08 02:55 PM
Philippe is right.. that test case works using =>ISQL<=.
The problem is using other tools or an ODBC driver I cannot create the trigger.

Suggestions?

Thanks,
Rui Cruz

Philippe Makowski added a comment - 05/Dec/08 02:55 PM
hum, see my other post (test under Vista 32 Firebird 2.1.1)
I have to say that with Databaseworkbench the bug is there, but not with isql and notepad

Adriano dos Santos Fernandes added a comment - 06/Dec/08 02:29 PM
It doesn't work in isql either. If it's working for you, I believe you are not using a connection charset.

Philippe Makowski added a comment - 06/Dec/08 03:44 PM
Adriano read what I posted :
>isql
>edit;
>type in the editor :
>SET NAMES ISO8859_1;

isn't using a charset ?

Adriano dos Santos Fernandes added a comment - 06/Dec/08 06:14 PM - edited
> isn't using a charset ?

If it's just before RECREATE TABLE, no. Because SET NAMES should be *before* CONNECT or CREATE DATABASE.

Pavel Cisar added a comment - 27/Apr/11 12:55 PM
QA test added.