Jim,
RawContent is just a property to be used for SQL queries, and inspection. Here is the documentation on the property:
/// The raw text content of the document.
Note that this is a truncated version suitable for use in SQL results and
visual inspection,
/// but not a complete or definitive
representation of the document.
Property RawContent As %String(MAXLEN
= 10000) [ Calculated, ReadOnly, SqlComputeCode
= { Set
{RawContent}=##class({%%CLASSNAME}).getSegsAsString({ID}) }, SqlComputed, Transient
];
Regards,
Dan
Jim,
The data (segments) for HL7 messages is stored in the ^EnsHL7.Segment global. EnsLib.HL7.Segment has no SQL view to it (it is not a persistent class).
RawContent is generated using this method:
/// This method is for use from the
RawContent property's SQL Compute invocation
ClassMethod getSegsAsString(pId As %CacheString, pMaxLen As %Integer = 10000, pStartOffset As %Integer = 1)
As %String
{
#; Use delimiters from first segment,
translate all subsequent delims to those
Set str="" For
index=1:1:+$G($$$vaExtentGbl(pId,"segs")) { Set data=$$$vaSegmentGbl($$$vaExtentGbl(pId,"segs",index))
Set:index=1 tSeparators=$E(data,1,5)
Set:tSeparators'=$E(data,1,5)
data=##class(EnsLib.HL7.Segment).replaceSeparators(data, tSeparators)
If pStartOffset>1 {
If pStartOffset>($L(data)-5+1)
{ Set pStartOffset=pStartOffset-($L(data)-5+1)
}
Else { Set
pStartOffset=1, data=$E(data,pStartOffset,*) }
}
If pMaxLen-$L(str)>=($L(data)-5+1) { Set
str=str_$E(data,6,*)_$C($$$HL7DefSegTerminatorAscii) }
Else { Set
str=str_$E(data_$C($$$HL7DefSegTerminatorAscii),6,5+pMaxLen-$L(str)) }
Quit:$L(str)>=pMaxLen
}
Quit str
}
So, you can see that it quits the loop once the string of data is greater than 10,000. I do not know how much deeper into this topic I want to go. What is the end game here? Are you just trying to see messages in the portal using the SQL browser?