Re: [Firebird-net-provider] Mapping a database char column to
Carlos Guzmán Álvarez escribió: > Hello: > >> But, then, I can't use DataAdapter to fill a DataTable with boolean = > > Try setting the column in the DataTable structure as boolean > do you mean that? tablasEstaticasDeUsuario.Tables.Add("Especificaciones"); tablasEstaticasDeUsuario.Tables["Especificaciones"].Columns.Add("UBICABLE",System.Type.GetType("System.Boolean")); this is the exception: System.ArgumentException: System.FormatException: String was not recognized as a valid Boolean. at System.Boolean.Parse(String value) at System.String.System.IConvertible.ToBoolean(IFormatProvider provider) at System.Convert.ToBoolean(Object value) at System.Data.Common.BooleanStorage.Set(Int32 record, Object value) at System.Data.DataColumn.set_Item(Int32 record, Object value)Couldn't store in CONTENIBLE Column. Expected type is Boolean. at System.Data.DataColumn.set_Item(Int32 record, Object value) at System.Data.DataTable.NewRecordFromArray(Object[] value) at System.Data.DataTable.LoadDataRow(Object[] values, Boolean fAcceptChanges) at System.Data.Common.SchemaMapping.LoadDataRow(Boolean clearDataValues, Boolean acceptChanges) at System.Data.Common.DbDataAdapter.FillLoadDataRow(SchemaMapping mapping) at System.Data.Common.DbDataAdapter.FillFromReader(Object data, String srcTable, IDataReader dataReader, Int32 startRecord, Int32 maxRecords, DataColumn parentChapterColumn, Object parentChapterValue) at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, String srcTable, IDataReader dataReader, Int32 startRecord, Int32 maxRecords) at System.Data.Common.DbDataAdapter.FillFromCommand(Object data, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord,Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, String srcTable) at PF.DbMm.ConexionMm.fillTablasEstaticasDeUsuario() I'm using .Net 1.1, Fb 1.5 and Firebird Net Provider 1.7 maybe it works with new versions? Muchas Gracias. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
Re: [Firebird-net-provider] Mapping a database char column to a DataTable boolean column
Andres F. Moschini escribió: > I wish to map a the "BOOLEANO" domain column as a boolean column in a > datatable. > > CREATE DOMAIN BOOLEANO AS > CHAR(1) CHARACTER SET NONE > DEFAULT 'F' > NOT NULL > CHECK (value in ('T', 'F')) > COLLATE NONE > > is it posible? > > thanks, sorry about my bad english... Jiri Cincura escribió: > You've to do it on client side by casting it to true/false. But, then, I can't use DataAdapter to fill a DataTable with boolean values instead char? - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
[Firebird-net-provider] Mapping a database char column to a DataTable boolean column
I wish to map a the "BOOLEANO" domain column as a boolean column in a datatable. CREATE DOMAIN BOOLEANO AS CHAR(1) CHARACTER SET NONE DEFAULT 'F' NOT NULL CHECK (value in ('T', 'F')) COLLATE NONE is it posible? thanks, sorry about my bad english... - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
Re: [Firebird-net-provider] Bug in FbDataAdapter exception handling
marzena escribio: > Hi, > > I am using Provider 2.0 RC 5 downloaded on Friday last week. I'm sure this > is not new bug previous versions (at least RC3 and RC4) was doing it the > same way. > > Marek > > >> Date: Wed, 7 Jun 2006 09:14:53 -0700 >> From: "JCardinal" <[EMAIL PROTECTED]> >> Subject: Re: [Firebird-net-provider] Bug in FbDataAdapter exception >> handling >> To: firebird-net-provider@lists.sourceforge.net >> Message-ID: <[EMAIL PROTECTED]> >> >> Which version of the provider are you using? I reported a >> long time ago that >> it was throwing a null reference exception instead of >> reporting the non >> existant column in an exception and I thought it was fixed. >> > > > > OK, will send test case today. > > >> Date: Wed, 07 Jun 2006 18:10:39 +0200 >> From: Carlos Guzm?n ?lvarez <[EMAIL PROTECTED]> >> Subject: Re: [Firebird-net-provider] Bug in FbDataAdapter exception >> handling >> To: "For users and developers of the Firebird .NET providers" >> >> Message-ID: <[EMAIL PROTECTED]> >> >> Hello: >>> The conclusion: >>> 1) Could you please correct the exception handling in this >> method in order >>> to obtain always the correct exception with correct message? >>> >> I have committed a change to CVS hope it's correct, let me >> know if not. >>> 2) And next - when I found the "correct" message "dataType' >> argument cannot >>> be null. Parameter name: dataType" I was bit confused >> because in my program >>> is no such parameter! IMHO there must be another bug when >> generating this >>> exception message. >>> >> Could you send a tets case please. >> >> >> -- >> Carlos Guzm?n ?lvarez >> Vigo-Spain > > > > > ___ > Firebird-net-provider mailing list > Firebird-net-provider@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/firebird-net-provider > (Sorry for my bad English) What was happen with this problem? Becose I'm using 1.7 Provider, and I have a problem that seems to be related: Unhandled Exception: System.NullReferenceException: Referencia a objeto no establecida como instancia de un objeto. at FirebirdSql.Data.Firebird.FbDataAdapter.Update(DataRow[] dataRows, DataTableMapping tableMapping) at System.Data.Common.DbDataAdapter.Update(DataTable dataTable) at PF.WinForms.Usuario.Form1..ctor(MmConnection conexion) at sigeme.ContextoAplicacion..ctor(Boolean loginAutomatico) at sigeme.ContextoAplicacion.Main(String[] args) And my code is this: dataadapter.SelectCommand = new FbCommand("Select NOMBRE, TIPO, VALOR from SPESTADOSARTICULO(@IdArticulo)",connection); FbParameter parameterTmp = dataadapter.SelectCommand.Parameters.Add("@IdArticulo", FbDbType.Integer); parameterTmp.Value = 1118; dataadapter.UpdateCommand = new FbCommand("CAMBIARESTADOARTICULO",connection); dataadapter.UpdateCommand.CommandType = CommandType.StoredProcedure; dataadapter.UpdateCommand.Parameters.Add("@IdArticulo", dataadapter.SelectCommand.Parameters["@IdArticulo"].Value); parameterTmp = dataadapter.UpdateCommand.Parameters.Add("@NombreEstado", FbDbType.VarChar, 20); parameterTmp.SourceColumn = "NOMBRE"; parameterTmp.SourceVersion = DataRowVersion.Original; parameterTmp = dataadapter.UpdateCommand.Parameters.Add("@Valor",FbDbType.VarChar,20); parameterTmp.SourceVersion = DataRowVersion.Current; parameterTmp.SourceColumn = "VALOR"; dataadapter.Fill(datatable); datatable.PrimaryKey = new DataColumn[] {datatable.Columns["NOMBRE"]}; datatable.Rows[0]["VALOR"] = "0"; dataadapter.Update(datatable); Well, maybe my code is bad, please correct me. Thanks, and sorry for my English again. - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
Re: [Firebird-net-provider] Cannot attach to services manager service [host]:service_mgr is not defined
Hola Carlos, si ese gsec se ejecuta en las mismas condiciones que mi fbSecurity.DisplayUser(nombre) pero el resultado del gsec es exitoso mientras que el del DisplayUser da el error antes mencionado. Hay un router (con ip dinámico 200.127.218.24) que redirige el puerto 3050 a una máquina de la red local. Todas las pruebas realizadas desde la red local (sin pasar por el router) son exitosas, mientras que si las realizo desde otra red (contra el ip del router) el gsec funciona y el DisplayUser no. En pruebas anteriores la conexion remota a traves del router usando FbConnection me funciono sin problemas. Estaba pensando, FBsecurity utiliza otro puerto o algo asi? Carlos Guzmán Álvarez escribió: Hola: C:\Archivos de programa\Firebird\Firebird_1_5\bin>gsec -user ADMINCLAVES -passwo rd 123 -database 200.127.218.24:Security -a X -pw 123 En google no pude encontrar nada parecido salvo un bug del beta de la version 2 del provider... Huummm asumo q ese gsec se esta ejecutando desde una maquina q no es el servidor al q realmente quieres acceder ;) Puedes establecer una conexion remota contra el servidor usando FbConnection ?? Estas seguro de q no hay un firewall bloqueando la conexion ??