I’ve discovered a bug with memo fields and MSSQL Text columns.
If you have an MSSQL table with a column of type Text, this is brought into the schema as a Memo field, quite correctly.
If you then attempt to append a new record to this table, the text in this field is corrupted. Looking at it, it appears as if there are null characters in between each of the original characters which suggests a unicode/non-unicode mismatch problem somewhere.
Obviously, as both MSSQL Text columns and schema Memo fields are non-unicode, this should work correctly. I appreciate that the Text column type is deprecated but it should still work and there are some places where we’re not yet able to migrate over to unicode NVARCHAR(MAX) columns.
I’ve reproduced this with a small text app created using the VCL Application wizard which I’ll mail over in a moment. There’s also an SQL script file in there to create the database.
I’m using DA 18.104.22.1681 on Delphi 10.2 Tokyo with FireDAC.