Archives for the 'Uncategorized' Category

Calling an Oracle function using NHibernate

Tested with NHibernate 2.1.2 and Oracle 11g.
Needs Oracle.DataAccess (not System.Data.OracleClient). Tested with Oracle.DataAccess 2.111.6.0 AMD64.
If your Oracle function returns a scalar value of datatype number, the .NET object will be a Decimal.

NHibernate config:

<hibernate-configuration xmlns=”urn:nhibernate-configuration-2.2″>
<session-factory>
<property name=”connection.driver_class”>
NHibernate.Driver.OracleDataClientDriver
</property>
</session-factory>
</hibernate-configuration>

C# code:

var result […]

17 January 2012 | Uncategorized | No Comments

Problem with Transactions on Windows 64-bit Oracle Client

After upgrading to a 64-bit machine at the office, my Visual Studio 2010 unit tests that were making heavy use of transactions (i.e., hundreds of uncommitted database table insertions within a using (new TransactionScope()) statement) failed with the following error message:
ORA-00603: ORACLE server session terminated by fatal error
ORA-00600: internal error code, arguments: [ktcirs:hds], [0×00F7D8078], [0×006F10BF0], […]

3 August 2011 | Uncategorized | No Comments

Memories of the past

The past doesn’t exist, except in our minds. There is not one past, but many pasts, each belonging to a different person.
If not for memory, there would be no such thing as the past. It is literally all in the mind.
Easy enough to comprehend, but extremely difficult to internalize.

9 January 2011 | Uncategorized | 6 Comments

A fundamentally flawed argument

I believe that everyone has at least one fundamental flaw. Those who think they aren’t fundamentally flawed turn out to have three fundamental flaws: first, their fundamental flaw; second, their ignorance of their fundamental flaw; and third, their belief that they are free of fundamental flaws.
The least fundamentally flawed are those armed with full knowledge […]

8 January 2011 | Uncategorized | No Comments

Tolstoy for bedtime

Last night I read Tolstoy to my four-year-old.
No, it wasn’t Leo Tolstoy’s War and Peace; it was Alexei Tolstoy’s The Enormous Turnip.

24 August 2010 | Uncategorized | 1 Comment