TDBEdit displays (MEMO) instead of original value lazarus / 16-Databases ---------------------------------------------------------------------- @VladislavL · 2023-03-16 09:10 How to correct this behavior? ---------------------------------------------------------------------- dseligo · 2023-03-17 11:20 In you select statement do this for column that behaves like this in dbedit: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i SQL.Text := 'select ..., cast(your_column as varchar(50)) as your_column, ... ' ---------------------------------------------------------------------- Zvoni · 2023-03-17 13:04 Quote from: @VladislavL on March 16, 2023, 10:10:26 amHow to correct this behavior? By searching the Forum first.... i think this question has been asked and answered at least 5 times in the last two years ---------------------------------------------------------------------- JanRoza · 2023-03-17 14:07 Why use tDbEdit on a memo field, use tDbMemo instead. ---------------------------------------------------------------------- @VladislavL · 2023-03-17 15:01 Quote from: dseligo on March 17, 2023, 12:20:02 pmIn you select statement do this for column that behaves like this in dbedit: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i SQL.Text := 'select ..., cast(your_column as varchar(50)) as your_column, ... 'Thanks, I'll try. ---------------------------------------------------------------------- @VladislavL · 2023-03-17 15:04 Quote from: JanRoza on March 17, 2023, 03:07:28 pmWhy use tDbEdit on a memo field, use tDbMemo instead. I have a simple text field, not a memo. ---------------------------------------------------------------------- JanRoza · 2023-03-17 16:28 If a tdbedit or tdbgrid shows ‘Memo’ it usually means that the source field in the database is a memo field. Have you tried replacing the tdbedit by a tdbmemo, just as a test? ---------------------------------------------------------------------- Zvoni · 2023-03-17 21:08 Quote from: JanRoza on March 17, 2023, 05:28:08 pmIf a tdbedit or tdbgrid shows ‘Memo’ it usually means that the source field in the database is a memo field. Have you tried replacing the tdbedit by a tdbmemo, just as a test? He‘s probably using SQLite, and it‘s a known issue with DBGrid for SQLite text columns that the grid thinks it‘s memo instead of plain text ---------------------------------------------------------------------- JanRoza · 2023-03-17 22:49 But he specifically mentions tdbedit and not tdbgrid, that is why I ask. ---------------------------------------------------------------------- @VladislavL · 2023-03-18 02:31 Quote from: Zvoni on March 17, 2023, 10:08:59 pmQuote from: JanRoza on March 17, 2023, 05:28:08 pmIf a tdbedit or tdbgrid shows ‘Memo’ it usually means that the source field in the database is a memo field. Have you tried replacing the tdbedit by a tdbmemo, just as a test? He‘s probably using SQLite, and it‘s a known issue with DBGrid for SQLite text columns that the grid thinks it‘s memo instead of plain text You're right. ---------------------------------------------------------------------- @VladislavL · 2023-03-18 02:34 Quote from: dseligo on March 17, 2023, 12:20:02 pmIn you select statement do this for column that behaves like this in dbedit: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i SQL.Text := 'select ..., cast(your_column as varchar(50)) as your_column, ... 'It helped, thanks.