greetings,
Previously I was using Firebird .net provider 1.7 in my visual studio 2005
programs and all was well.
However when I installed the FireBird Client 2.0 and use it's fbdataadapter,
a dataset and a datagridview with visual studio 2005 I get the following error ;
"An unhandled exception of type 'System.StackOverflowException' occurred in
mscorlib.dll"
Why does this happen and how do I get over this problem. I tried
uninstalling the Firebird .net provider 1.7 from my visual studio 2005 toolbox
and run the program using the FireBird Client 2.0 but still have the same error.
Thanks.
[EMAIL PROTECTED] wrote:
Send Firebird-net-provider mailing list submissions to
firebird-net-provider@lists.sourceforge.net
To subscribe or unsubscribe via the World Wide Web, visit
https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
or, via email, send a message with subject or body 'help' to
[EMAIL PROTECTED]
You can reach the person managing the list at
[EMAIL PROTECTED]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of Firebird-net-provider digest..."
Today's Topics:
1. Re: records affected is set to true by default
(Carlos Guzm?n ?lvarez)
2. Preparing the sources for the RC 1 (Carlos Guzm?n ?lvarez)
3. Re: Preparing the sources for the RC 1 (Jiri Cincura)
4. Re: Preparing the sources for the RC 1 (Carlos Guzm?n ?lvarez)
5. Re: Preparing the sources for the RC 1 (Jiri Cincura)
6. New GDS ( first thoughts ) (Carlos Guzm?n ?lvarez)
7. Re: New GDS ( first thoughts ) (Roman Rokytskyy)
8. Re: New GDS ( first thoughts ) (Oleg Deribas)
----------------------------------------------------------------------
Message: 1
Date: Mon, 30 Apr 2007 22:49:00 +0200
From: Carlos Guzm?n ?lvarez
Subject: Re: [Firebird-net-provider] records affected is set to true
by default
To: firebird-net-provider@lists.sourceforge.net
Message-ID:
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Hello:
Sorry for the delay.
> Is there a performance hit(if any) by having records affected set to
> true? Currently I'm returning status codes from the SPs, so I really
> don't need records affected information.
Yes, there are a performance penalty, as a new call to the server is
needed in order to obtain the number of rows affected by the query
execution.
------------------------------
Message: 2
Date: Mon, 30 Apr 2007 22:50:44 +0200
From: Carlos Guzm?n ?lvarez
Subject: [Firebird-net-provider] Preparing the sources for the RC 1
To: "For users and developers of the Firebird .NET providers"
Message-ID: <[EMAIL PROTECTED]>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Hello:
I hope to create a new brach for the 2.1. RC 1 tomorrow
After that current trunk will be the development sources for the next
version
--
Carlos Guzm?n ?lvarez
Vigo-Spain
http://carlosga.wordpress.com
------------------------------
Message: 3
Date: Mon, 30 Apr 2007 23:01:39 +0200
From: Jiri Cincura
Subject: Re: [Firebird-net-provider] Preparing the sources for the RC
1
To: "For users and developers of the Firebird .NET providers"
Message-ID: <[EMAIL PROTECTED]>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Carlos Guzm?n ?lvarez wrote:
> Hello:
>
> I hope to create a new brach for the 2.1. RC 1 tomorrow
Just yesterday I fixed version number for web providers. :)
> After that current trunk will be the development sources for the next
> version
>
>
--
Jiri {x2} Cincura
http://blog.vyvojar.cz/jirka/ | http://www.ID3renamer.com
------------------------------
Message: 4
Date: Mon, 30 Apr 2007 23:22:14 +0200
From: Carlos Guzm?n ?lvarez
Subject: Re: [Firebird-net-provider] Preparing the sources for the RC
1
To: firebird-net-provider@lists.sourceforge.net
Message-ID:
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Hello:
> Just yesterday I fixed version number for web providers. :)
Nice !! :)
I have done the branching yet.
I will release 2.1.0 RC 1 from that branch this weekend, all bug fixes
for 2.1.0 will be done in that branch ( along with doing it on the devel
trunk of course )
------------------------------
Message: 5
Date: Mon, 30 Apr 2007 23:31:23 +0200
From: Jiri Cincura
Subject: Re: [Firebird-net-provider] Preparing the sources for the RC
1
To: "For users and developers of the Firebird .NET providers"
Message-ID: <[EMAIL PROTECTED]>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Carlos Guzm?n ?lvarez wrote:
> I have done the branching yet.
OK.
> I will release 2.1.0 RC 1 from that branch this weekend, all bug fixes
> for 2.1.0 will be done in that branch ( along with doing it on the devel
> trunk of course )
I'm now refactoring web providers. But this will take more time and
result of compilation doesn't depend on this. So don't worry.
--
Jiri {x2} Cincura
http://blog.vyvojar.cz/jirka/ | http://www.ID3renamer.com
------------------------------
Message: 6
Date: Tue, 01 May 2007 14:36:30 +0200
From: Carlos Guzm?n ?lvarez
Subject: [Firebird-net-provider] New GDS ( first thoughts )
To: "For users and developers of the Firebird .NET providers"
Message-ID: <[EMAIL PROTECTED]>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Hello:
We are going to need to implement the version 11 of the Firebird
Protocol and review the buffer handling code to make better checks on
buffer lengths and server resposnses.
Now the Firebird server supports batching of messages ( not available
for all of them ), so we can send several messages in the same request
and retrieve all the answers at the same time.
An example will be the statement preparation, in the actual GDS
implementation we make two calls to the server:
1. To prepare the statement
2. To get the statement type
Now we can send them in the same request to the server, something like this:
public override void Prepare(string commandText)
{
// Clear data
this.Clear();
this.parameters = null;
this.fields = null;
lock (this.db)
{
if (this.state == StatementState.Deallocated)
{
// Allocate statement
this.Allocate();
}
try
{
// Prepare the statement
this.db.Send.Write(IscCodes.op_prepare_statement);
this.db.Send.Write(this.transaction.Handle);
this.db.Send.Write(this.handle);
this.db.Send.Write((int)this.db.Dialect);
this.db.Send.Write(commandText);
this.db.Send.WriteBuffer(DescribeInfoItems,
DescribeInfoItems.Length);
this.db.Send.Write(IscCodes.MAX_BUFFER_SIZE);
// Grab statement type
this.db.Send.Write(IscCodes.op_info_sql);
this.db.Send.Write(this.handle);
this.db.Send.Write(0);
this.db.Send.WriteBuffer(StatementTypeInfoItems,
StatementTypeInfoItems.Length);
this.db.Send.Write(IscCodes.STATEMENT_TYPE_BUFFER_SIZE);
// Flush data
this.db.Send.Flush();
// Prepare statement info processing
GdsGenericResponse response =
(GdsGenericResponse)this.db.ReadResponse();
this.fields = this.ParseSqlInfo(response.Data,
DescribeInfoItems);
// Statement type information processing
GdsGenericResponse stmtmTypeResponse =
(GdsGenericResponse)this.db.ReadResponse();
this.statementType =
this.ParseStatementTypeInfo(stmtmTypeResponse.Data);
this.state = StatementState.Prepared;
}
catch (IOException)
{
this.state = StatementState.Error;
throw new IscException(IscCodes.isc_net_read_err);
}
}
}
Another example, could be the statement execution method that makes two
calls ( wehn execution insert, updates, deletes )
1. To execute the statement
2. To retrieve the number of rows affected by the statement execution
Now we can send them in the same request to the server, something like this:
public override void Execute()
{
if (this.state == StatementState.Deallocated)
{
throw new InvalidOperationException("Statment is not
correctly created.");
}
// Clear data
this.Clear();
lock (this.db)
{
try
{
byte[] descriptor = null;
if (this.parameters != null)
{
XdrStream xdr = new XdrStream(this.db.Charset);
xdr.Write(this.parameters);
descriptor = xdr.ToArray();
xdr.Close();
}
if (this.statementType ==
DbStatementType.StoredProcedure)
{
this.db.Send.Write(IscCodes.op_execute2);
}
else
{
this.db.Send.Write(IscCodes.op_execute);
}
this.db.Send.Write(this.handle);
this.db.Send.Write(this.transaction.Handle);
if (this.parameters != null)
{
this.db.Send.WriteBuffer(this.parameters.ToBlrArray());
this.db.Send.Write(0); // Message number
this.db.Send.Write(1); // Number of messages
this.db.Send.Write(descriptor, 0,
descriptor.Length);
}
else
{
this.db.Send.WriteBuffer(null);
this.db.Send.Write(0);
this.db.Send.Write(0);
}
if (this.statementType ==
DbStatementType.StoredProcedure)
{
this.db.Send.WriteBuffer((this.fields == null) ?
null : this.fields.ToBlrArray());
this.db.Send.Write(0); // Output message number
}
// Obtain records affected by query execution
if (this.ReturnRecordsAffected &&
(this.StatementType == DbStatementType.Insert ||
this.StatementType == DbStatementType.Delete ||
this.StatementType == DbStatementType.Update ||
this.StatementType ==
DbStatementType.StoredProcedure ||
this.StatementType == DbStatementType.Select))
{
// Grab statement type
this.db.Send.Write(IscCodes.op_info_sql);
this.db.Send.Write(this.handle);
this.db.Send.Write(0);
this.db.Send.WriteBuffer(RecordsAffectedInfoItems,
RecordsAffectedInfoItems.Length);
this.db.Send.Write(IscCodes.ROWS_AFFECTED_BUFFER_SIZE);
this.recordsAffected = 0;
}
else
{
this.recordsAffected = -1;
}
this.db.Send.Flush();
if (this.db.NextOperation() == IscCodes.op_sql_response)
{
// This would be an Execute procedure
this.outputParams.Enqueue(this.ReadStoredProcedureOutput());
}
this.db.ReadResponse();
if (this.recordsAffected == 0)
{
GdsGenericResponse response =
(GdsGenericResponse)this.db.ReadResponse();
this.ProcessRecordsAffectedBuffer(response.Data);
}
this.state = StatementState.Executed;
}
catch (IOException)
{
this.state = StatementState.Error;
throw new IscException(IscCodes.isc_net_read_err);
}
}
}
For the new GDS implementation, my first thought is that we can make all
the public methods on the current GDS implementation virtual, and
override ( and rewrite ) them in the new GDS implementation ( i will try
to check if that approach will be possible or not ... i think it's but
.. better to be sure XD )
--
Carlos Guzm?n ?lvarez
Vigo-Spain
http://carlosga.wordpress.com
------------------------------
Message: 7
Date: Tue, 01 May 2007 15:40:08 +0200
From: Roman Rokytskyy
Subject: Re: [Firebird-net-provider] New GDS ( first thoughts )
To: firebird-net-provider@lists.sourceforge.net
Message-ID:
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Carlos,
> We are going to need to implement the version 11 of the Firebird
> Protocol and review the buffer handling code to make better checks on
> buffer lengths and server resposnses.
>
> Now the Firebird server supports batching of messages ( not available
> for all of them ), so we can send several messages in the same request
> and retrieve all the answers at the same time.
These two examples that you posted, where did you get them? I ask,
because I think that would be to our (.Net and Java drivers) benefit to
document these changes somehow. Do you think it is worth the effort? Is
it feasible at all?
> For the new GDS implementation, my first thought is that we can make all
> the public methods on the current GDS implementation virtual, and
> override ( and rewrite ) them in the new GDS implementation ( i will try
> to check if that approach will be possible or not ... i think it's but
> ... better to be sure XD )
Looks good. In Jaybird I was thinking about introducing new methods into
GDS interface that would do similar things to your Prepare() and
Execute() methods. However I would need to do some refactorings to be
able to handle different protocol versions.
Also, as I remember from my discussions with Dmitry and Vlad, we need to
have some buffer for the calls that can be delayed (e.g. isc_dsql_free),
but it seems that it can be hidden somewhere in the GDS implementation
(or maybe even in the stream class).
Roman
------------------------------
Message: 8
Date: Tue, 01 May 2007 16:07:20 +0300
From: Oleg Deribas
Subject: Re: [Firebird-net-provider] New GDS ( first thoughts )
To: firebird-net-provider@lists.sourceforge.net
Message-ID:
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Hello,
Carlos Guzm?n ?lvarez said the following on 01.05.2007 15:36:
> For the new GDS implementation, my first thought is that we can make all
> the public methods on the current GDS implementation virtual, and
> override ( and rewrite ) them in the new GDS implementation
Shouldn't these two implementations coexist? I mean, when connection is
creating, - provider should check which server version it connecting to,
and then decide which implementation to use.
--
Oleg
------------------------------
-------------------------------------------------------------------------
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
End of Firebird-net-provider Digest, Vol 13, Issue 1
****************************************************
---------------------------------
Ahhh...imagining that irresistible "new car" smell?
Check outnew cars at Yahoo! Autos.
-------------------------------------------------------------------------
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