0

I'm making a Windows Form App that reads Firebird database and displays the data.

I'm using a DLL file a coworker recommended: FirebirdSql.Data.FirebirdClient.dll

Here's an example of how I read the data:

class FBConnect { private FbConnection MyConnection= new FbConnection(); private FbConnectionStringBuilder ConnectionString; //Constructor public FBConnect() { ConnectionString= new FbConnectionStringBuilder(); { var withBlock = ConnectionString; withBlock.Database = "MyFile.fdb"; withBlock.ServerType = FbServerType.Embedded; withBlock.UserID = "USID"; withBlock.Password = "Key"; withBlock.Pooling = true; } MyConnection.ConnectionString = ConnectionString.ToString(); } public DataTable RunQuery(string query) { try { MyConnection.Open(); if (MyConnection.State == ConnectionState.Open) { DataTable dt = new DataTable(); FbDataAdapter da = new FbDataAdapter(query, MyConnection.ConnectionString); da.Fill(dt); return dt; } else { return null; } } catch (FbException err) { MessageBox.Show(err.Message, "Firebird error " + err.ErrorCode, MessageBoxButtons.OK, MessageBoxIcon.Error); return null; } finally { MyConnection.Close(); } } } 

And then, from another class, I call:

FBConnect conn = new FBConnect(); dataGridView1.DataSource = conn.RunQuery("SELECT * FROM table1"); 

and it works just fine, I get to see the data. The problem comes exclusively when I use a JOIN in my query: then I get an exception

Firebird error 335544854
CHARACTER SET ISO8859_1 is not installed

What can be causing this and how do I solve it?

Here's the query I'm using

SELECT FACTF.CVE_DOC AS "Clave de Documento", VENDEDOR.NOMBRE AS "Nombre del vendedor" FROM FACTF01 FACTF LEFT JOIN VEND01 VENDEDOR ON VENDEDOR.CVE_VEND=FACTF.CVE_VEND 
2
  • Are you intentionally using Firebird Embedded instead of a Firebird server? It sounds like your Firebird Embedded is missing the intl folder (+ contents), which restricts character set support. Edit your question and include exactly which files of Firebird Embedded are deployed with your application. Commented Sep 27, 2018 at 8:28
  • Also please post the DDL of the tables involved in your query. Commented Sep 27, 2018 at 8:29

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.