January 26, 2008


One nice thing about my trip was that I was able to catch up with my parents for the first time in a long while.

My parents

I don't get a chance to get back to Utah often enough to keep up with my family, so it was weird finding out that my brother got married just before we got there and about family squabbles between my sister and brother and other family trivia.

The downside of not being around your family is that it makes it difficult to keep up with them.

Still Alive

No, I'm not talking about the song. I'm talking about me.

I've been a bit swamped with work and life over the last month. Lots of feature deliverables due for this coming Friday, the rewrite of VistaGameDoctor.com, the pending launch of my other site, and a few other items have kept me from posting much lately.

A quick summary of the events of the past month...

I turned down an offer to work back in Utah again. It was a great offer at a great company with a stellar staff, but you can get the right offer at the wrong time and that's what happened here.

I celebrated my one-year anniversary at my place of employment. I also found out that if all goes well, I'll be going to two conferences this year. Either SD West or TechEd Developers first, then PDC 2008 later this year. I've been to many QA conferences in the past, and even spoken at a couple, so it will be interesting to see what happens at developer conferences.

I started to go noticeably gray. I was getting dressed in a dark room so I wouldn't wake the wife when I looked over at a mirror and noticed a section of hair that seemed to be glowing in the dark. When I went into the bathroom and looked at that section in the mirror, a patch of silver hair was shining out at me. Makes me wonder if I'll have different tones for each section of my head like I do now (brown hair, blond eyebrows and a red beard).

My anti-piracy stance came up again in a recent article over at Shacknews. I actually need to finish a letter to my congressman I've been working on regarding piracy. No, I'm not asking for increased penalties or armed thugs to go door to door looking for burned Britney Spears CD's. I'm actually hoping for a repeal of the DMCA. Piracy is bad, but the DMCA makes many things that should be legal illegal and the justification that many idiots use when they pirate is that the penalty for piracy is in many cases less than the penalty for violating the DMCA.

I'm trying to unify our data tiers at work. We have data split between three different tiers for a variety of security and legacy reasons and it makes some front-end work a bit of a pain in the butt, so we're going to try to get around that.

Finally, I'm moving VistaGameDoctor.com away from Project Wonderful back to Google AdSense at the end of this month. If you run a webcomic, PW is going to be your best friend...but for VGD, it has resulted in a major financial loss during the 60 day experiment.

That's it...I'll try to post more often. In the meantime, if you are into sports and other such miscellanea, go check out Ick's Corner. It's a site run my one of my neighbors who is as much a sports fan as I am not...and that's saying something.

January 18, 2008

HOWTO: Write to an Oracle NCLOB using .NET

Note: These instructions are for if you are using the Microsoft-provided provider for Oracle for .NET, not ODP.NET.

You have a blank NCLOB field in your Oracle database, but any time you try to save more than 32Kb of data to it, you get an error about an invalid conversion. The solution is a bit hackish, but here goes:
using (OracleConnection conn = 
new OracleConnection(connectionString))

OracleTransaction tx = conn.BeginTransaction();

OracleCommand cmdLob = new OracleCommand(
"PK = {0} FOR UPDATE", pk), conn, tx);
cmdLob.CommandType = CommandType.Text;
using (OracleDataReader dr = cmdLob.ExecuteReader())
while (dr.Read())
OracleLob lob = dr.GetOracleLob(0);
lob.Seek(0, System.IO.SeekOrigin.Begin);
lob.Write(System.Text.Encoding.Unicode.GetBytes(textToSave), 0,
textToSave.Length * 2);

A quick walkthrough of the code...
Open your connection to the Oracle database.
Start a transaction on that connection.
Get an OracleDataReader that points to the NCLOB field. Make sure that you suffix your query with FOR UPDATE, or you won't be able to update your CLOB.
Get the LOB object from the OracleDataReader.
At that point, the Lob object is essentially a stream, but to write your string, you need to write it in a format that Oracle won't complain about, hence getting the Unicode-encoded bytestream for the text.
Commit the transaction.
Close the connection.

January 14, 2008

Oracle Error ORA-01460

Symptom: When calling an Oracle stored procedure with either a CLOB or an NCLOB parameter using the Oracle provider that ships with the .NET Framework, you get the following error message:

ORA-01460: unimplemented or unreasonable conversion requested

Cause: You are passing more than 32Kb of data to either a CLOB or NCLOB parameter.

I'm looking for a workaround.

Update: Evidently, you have to insert a small record into the database, then open that row in an OracleDataReader using a "SELECT * FROM ___ FOR UPDATE," get the LOB and then stream into the LOB. Thanks to Sarkie for shortcutting my search.

January 2, 2008

uTest: Feedback Requested

I just received a "blog kit" about a new QA company called uTest, and I'm looking for information from people in the community who have dealt with them.

From first glance, it appears to have a bit of a unique set of strengths and weaknesses compared to traditional QA firms.

On the upside, they're trying to take advantage of the "many eyes" philosophy of testing and they seem to be trying to match testers to products within their areas of expertise. It does seem to be a nice, low-impact means of getting your foot in the door of software QA.

On the downside, they're a "pay-per-bug" place, which leads one to ask who determines whether or not it's a bug, do you get paid for duplicate bugs, and are all bugs created equal in the eyes of the payor? (In other words, am I going to get the same for finding a crash bug as I am for a misplaced comma?)

For the unknowns, how do they handle build security/watermarking for firms, can we remove testers from our products that don't "get" QA, how do they handle firms that reject bugs to prevent payment while fixing them anyway, etc.?

A lot of questions, and hopefully some good answers.