On Feb 13, 2017, at 6:51 PM, Jeffrey Kain wrote:
> There seems to be about a 383K character limit in text variables on a form.
> I have a text document that's about 670K characters (670,092 characters to be
> exact) and when I try to paste it into a 4D form (v15.4/Mac/Unicode) it
> truncates at exactly 383,046 characters.
>
> Can anyone confirm this? Is there a workaround other than loading the data
> into a blob or text from a file? I'd like to allow the user to paste this in.
>
> In case you're wondering, it's a very long series of SQL INSERT statements
> generated by another application.
This is an interesting observation. I did a quick test on my own to see what
results I got.
Test environment was 4D v14.4 on macOS 10.9.5. (Sorry, don’t have any v15.4
databases to test on.)
I have a “notes” table that has a text field. Basic input form displayed via a
double-click on a listbox row. Window is set to resizable and the text field
grows with the window resize. Vertical scrollbar is enabled for the text field.
Standard stuff.
I put a button on the form with the following code: ALERT ("Length =
"+String(Length([CaseActivityNotes]Comments);”###,###,##0"))
I grabbed about 100K of text off the web and then performed the following:
- Double-click the listbox row to show the input form for the record
- Paste the 100K of text
- Click the button
- Note the “Length” value
- Save the record
- Repeat
I got up to “Length = 2,401,918” and stopped testing.
So I had no problem saving over 2MB of text in a field with v14.4. Scrolling
got progressively slower to the point of being unusable. It was also impossible
to scroll to the very bottom of this giant text field. But it did appear to
save all the text in the field based on what was reported by the Length command
on the field.
Tim
********************************************
Tim Nevels
Innovative Solutions
785-749-3444
[email protected]
********************************************
**********************************************************************
4D Internet Users Group (4D iNUG)
FAQ: http://lists.4d.com/faqnug.html
Archive: http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub: mailto:[email protected]
**********************************************************************