Page 1 of 1

Maximum length of %FACT.NOTES2& (or {note}), information being truncated

Posted: 19 Jul 2022 08:13
by phillip_leslie
Hi All,

I appear to have an issued with fact notes being truncated in the Individual Narrative report. They appear to be truncated at the 510th character position. They also appear truncated in the sentence window of the Properties fact tab at the same position. I have tried to modify the sentence structure in the Fact Type using both {note} and {%FACT.NOTE2%} and neither fix the problem. I have also added additional simple text either side of the 510 position and this has not effect either, it is still truncated at 510.

This is my sentence structure in the Fact Definition: {individual} was registered for birth {date} {place}. {%CUR_PRIN.NAME:FIRST%}'s {%FACT.NOTE2%}

Also attached is a screen shot from the Profile sentence and clip from the Individual Narrative Report.

Does anyone have any suggestions about the length, or why the formatting (carriage-returns) is changed in the report as well?

Thanks, Phillip
S1.jpg
S1.jpg (138.01 KiB) Viewed 765 times
S2.jpg
S2.jpg (84.91 KiB) Viewed 765 times

Re: Maximum length of %FACT.NOTES2& (or {note}), information being truncated

Posted: 19 Jul 2022 08:55
by Gowermick
Sounds very much like a programme restiction, (512 being an exact multiple of 2.)
I suggest you raise it with Calico, perhaps they can explain why and perhaps even extend the limit.

Re: Maximum length of %FACT.NOTES2& (or {note}), information being truncated

Posted: 19 Jul 2022 09:22
by ColeValleyGirl
You can try the techniques here: Display long text such as Notes (the limit used to be 150 characters).

Re: Maximum length of %FACT.NOTES2& (or {note}), information being truncated

Posted: 19 Jul 2022 09:38
by tatewise
That truncation of long text in Notes and other multiline text fields is a well-known and deliberate phenomenon.

Since you are just appending the Note text to the Fact, try using the Narrative Report > Options > Main tab, and tick the setting Inc. Event/Attribute Notes on the left. That always includes the full Note text.

You will have to modify the Note text in the example you provided to include the name Joyce's at the beginning.

Re: Maximum length of %FACT.NOTES2& (or {note}), information being truncated

Posted: 19 Jul 2022 09:49
by RS3100
I have not experienced this issue and have some long notes attached to various facts, but I tend to individually customise the fact sentence for each fact where I want to include a note attached to the fact, and just use {note} in the customised fact sentence template, rather then referencing it via an expression.

I did find a number of issues with formatting in narrative reports when I started adding notes also - spurious carriage returns, additional spaces appearing in sentences, unwanted paragraph indentations, italic or bold text in notes having strange affects on formatting in narrative reports. I was able to demonstrate them to CP and they reproduced them. I was told that some were only occurring where specific fact types appeared in a particular order, but in any event CP fixed them all to my satisfaction in one of the v7 minor updates. I haven't encountered any issues since, but that's not to say that there aren't circumstances I haven't personally encountered where bugs might still be lurking!

Edit: Mike posted whilst I was typing my reply - interrupted by a phone call.

Re: Maximum length of %FACT.NOTES2& (or {note}), information being truncated

Posted: 19 Jul 2022 10:01
by tatewise
Yes, instead of using data ref {%FACT.NOTE2%} use template code {note} and the Note text should appear in full.
I did not double-check the {note} code as the OP, Phillip, said he had tried it. However, that should work.

Remember to use Refresh Report while the Narrative Report is displayed, to ensure any changes to Sentence Templates are honoured in the Report.

BTW: The {note} code and the Inc. Event/Attribute Notes option both fully honour the layout and style of the Note text, whereas {%FACT.NOTE2%} will always render it as plain text without new lines.

Re: Maximum length of %FACT.NOTES2& (or {note}), information being truncated

Posted: 19 Jul 2022 13:41
by RS3100
tatewise wrote:
19 Jul 2022 10:01
Yes, instead of using data ref {%FACT.NOTE2%} use template code {note} and the Note text should appear in full.
I did not double-check the {note} code as the OP, Phillip, said he had tried it. However, that should work.
Just as an example, almost the whole page of text in the attachment, following the burial sentence at the end of the first paragraph, is a single rich text note inserted using {note} in a custom fact sentence. It continues on the following page as well and is 5,396 characters in length.

Re: Maximum length of %FACT.NOTES2& (or {note}), information being truncated

Posted: 19 Jul 2022 14:02
by phillip_leslie
I first switched from {note} to {%FACT.NOTE%} as {note} appeared to automatically insert an <br> before the actual note which was breaking the sentence after the principals.first.name. I understand now that {note} does retain the formatting correctly, which is a better option in my scenario than fact.note.

More bizarrely (and I am sure that I QA tested the truncation of both methods several times, I'll have to start documenting my test scenarios for my own sanity) now I have switched back to {note} the automatic <br> no longer appears to be an issue. I wonder if I have changed some other text setting in the Individual Narrative options, but I cannot find one. But as Mike has suggested, I'll use {note} and this is the solution I'll stick with for the moment.

I have too many birth registration records to amend them all and insert the mother's maiden name, when I get chance and little more proficient with scripting, I may have a go at automating the insertion. Unfortunately I have too many other notes fields as well, formatted from my previous TMG system to enable me to use the Narrative report "Inc. Event/Attr Notes" as they will duplicate the ones that I have formatted into my fact sentence structure.

Thanks again everyone.

Re: Maximum length of %FACT.NOTES2& (or {note}), information being truncated

Posted: 19 Jul 2022 14:41
by tatewise
If you use {note} code and enable the Inc. Event/Attribute Notes option then the Report will not duplicate the Note text.
The Inc. Event/Attribute Notes option is automatically inhibited wherever a Sentence Template uses the {note} code.

Since the {note} code is performing as required you do not need to insert the mother's maiden name into the Note text and can continue using {%CUR_PRIN.NAME:FIRST%}'s