private bool TryProcessColumnHeaderNoNBC(SqlMetaDataPriv col, TdsParserStateObject stateObj, out bool isNull, out ulong length)
{
if (col.metaType.IsLong && !col.metaType.IsPlp)
{
//
// we don't care about TextPtrs, simply go after the data after it
//
byte textPtrLen;
if (!stateObj.TryReadByte(out textPtrLen))
{
isNull = false;
length = 0;
return false;
}
if (0 != textPtrLen)
{
// read past text pointer
if (!stateObj.TrySkipBytes(textPtrLen))
{
isNull = false;
length = 0;
return false;
}
// read past timestamp
if (!stateObj.TrySkipBytes(TdsEnums.TEXT_TIME_STAMP_LEN))
{
isNull = false;
length = 0;
return false;
}
isNull = false;
return TryGetDataLength(col, stateObj, out length);
}
else
{
isNull = true;
length = 0;
return true;
}
}
else
{
// non-blob columns
ulong longlen;
if (!TryGetDataLength(col, stateObj, out longlen))
{
isNull = false;
length = 0;
return false;
}
isNull = IsNull(col.metaType, longlen);
length = (isNull ? 0 : longlen);
return true;
}
}