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

Problem with accented letters in charset NONE [DNET712] #662

Closed
firebird-automations opened this issue Nov 4, 2016 · 9 comments
Closed

Comments

@firebird-automations
Copy link

Submitted by: Marcos Gerene Felix Spirito (marcosgerene)

In this version, the ç, ê, ã and others like these are broken and show "?".

So, I downgrade to 5.5.0.0 and it's works ok again.

The example:

StringBuilder stringConnection = new StringBuilder();
stringConnection.AppendLine("User=SYSDBA;Password=masterkey;Database="+caminhoBanco+";DataSource="+ipServidor+";");
stringConnection.AppendLine("Port=" + portaFirebird + ";Dialect=3;Charset=NONE;Role=;Connection lifetime=15;Pooling=true;");
stringConnection.AppendLine("MinPoolSize=0;MaxPoolSize=50;Packet Size=8192;ServerType=0;");

var connection = new FbConnection(stringConnection.ToString().Trim());
connection.Open();
var command = new FbCommand("SELECT EMP_RAZAO FROM EMPRESA WHERE EMP_CODIGO = 2", connection);
var rd = new command..ExecuteReader();
string test = "";
if (rd.Read())
{
test = rd["EMP_RAZAO"].ToString();
}

The string "test" returns "CONSTRU??O" in 5.6.0.0 (bug) and "CONSTRUÇÃO" in 5.5.0.0 (ok).

Commits: 288d55d

@firebird-automations
Copy link
Author

Commented by: @cincuranet

Please add a database (or script) as well.

@firebird-automations
Copy link
Author

Modified by: Marcos Gerene Felix Spirito (marcosgerene)

Attachment: DADOS.zip [ 13032 ]

description: In this version, the ç, ê, ã and others like these are broken and show "?".

So, I downgrade to 5.5.0.0 and it's works ok again.

The example:

StringBuilder stringConnection = new StringBuilder();
stringConnection.AppendLine("User=SYSDBA;Password=masterkey;Database="+caminhoBanco+";DataSource="+ipServidor+";");
stringConnection.AppendLine("Port=" + portaFirebird + ";Dialect=3;Charset=NONE;Role=;Connection lifetime=15;Pooling=true;");
stringConnection.AppendLine("MinPoolSize=0;MaxPoolSize=50;Packet Size=8192;ServerType=0;");

var connection = new FbConnection(stringConnection.ToString().Trim());
connection.Open();
var command = new FbCommand("SELECT * FROM EMPRESA WHERE EMP_ID = 1", connection);
var rd = new command..ExecuteReader();
string test = "";
if (rd.Read())
{
test = rd["EMP_RAZAO"].ToString();
}

The string "test" returns "CONSTRU??O" in 5.6.0.0 (bug) and "CONSTRUÇÃO" in 5.5.0.0 (ok).

=>

In this version, the ç, ê, ã and others like these are broken and show "?".

So, I downgrade to 5.5.0.0 and it's works ok again.

The example:

StringBuilder stringConnection = new StringBuilder();
stringConnection.AppendLine("User=SYSDBA;Password=masterkey;Database="+caminhoBanco+";DataSource="+ipServidor+";");
stringConnection.AppendLine("Port=" + portaFirebird + ";Dialect=3;Charset=NONE;Role=;Connection lifetime=15;Pooling=true;");
stringConnection.AppendLine("MinPoolSize=0;MaxPoolSize=50;Packet Size=8192;ServerType=0;");

var connection = new FbConnection(stringConnection.ToString().Trim());
connection.Open();
var command = new FbCommand("SELECT EMP_RAZAO FROM EMPRESA WHERE EMP_CODIGO = 2", connection);
var rd = new command..ExecuteReader();
string test = "";
if (rd.Read())
{
test = rd["EMP_RAZAO"].ToString();
}

The string "test" returns "CONSTRU??O" in 5.6.0.0 (bug) and "CONSTRUÇÃO" in 5.5.0.0 (ok).

environment: Firebird 2.5.6, Visual Studio Community 2015, C#⁠ 6.0, .Net Framework 4.5.1, Windows 10 Home => Firebird 3.0.0, Visual Studio Community 2015, C#⁠ 6.0, .Net Framework 4.5.1, Windows 10 Home

@firebird-automations
Copy link
Author

Commented by: Marcos Gerene Felix Spirito (marcosgerene)

Can you delete this database after download?

Thanks

@firebird-automations
Copy link
Author

Modified by: @cincuranet

security: Developers [ 10012 ]

@firebird-automations
Copy link
Author

Commented by: @cincuranet

I will. I changed also the security level for this ticket.

@firebird-automations
Copy link
Author

Commented by: Marcos Gerene Felix Spirito (marcosgerene)

Thank you

@firebird-automations
Copy link
Author

Modified by: @cincuranet

Attachment: DADOS.zip [ 13032 ] =>

@firebird-automations
Copy link
Author

Modified by: @cincuranet

security: Developers [ 10012 ] =>

@firebird-automations
Copy link
Author

Modified by: @cincuranet

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

resolution: Fixed [ 1 ]

Fix Version: vNext [ 10790 ]

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

2 participants