Lazarus
Home
Help
TinyPortal
Search
Login
Register
Lazarus
»
Forum
»
Programming
»
Databases
»
[SOLVED]Foreign key in DBgrid shows as (MEMO)
Free Pascal
Website
Downloads
Wiki
Documentation
Bugtracker
Mailing List
Lazarus
Website
Downloads (Laz+FPC)
Packages (OPM)
FAQ
Wiki
Documentation (RTL/FCL/LCL)
Bugtracker
CCR Bugs
GIT
Mailing List
Other languages
Foundation
Website
Useful Wiki Links
Project Roadmap
Getting the Source
Screenshots
How to use the forum
Forum Rules
About donations (wiki)
Bookstore
Computer Math and Games in Pascal
(preview)
Lazarus Handbook
Search
Advanced search
Recent
TSplitter color property ...
by
zeljko
[
Today
at 05:39:09 pm]
Need help with project ma...
by
cdbc
[
Today
at 05:16:55 pm]
ShortStrings vs long stri...
by
marcov
[
Today
at 04:13:11 pm]
could Ardour's YTK be use...
by
robert rozee
[
Today
at 03:18:36 pm]
Synchronizing Lazarus pro...
by
Martin_fr
[
Today
at 03:18:18 pm]
Questions about TFuncSeri...
by
hedgehog
[
Today
at 02:03:29 pm]
Qt6/Wayland clipboard: pa...
by
Thaddy
[
Today
at 01:20:24 pm]
[revisited] triple click
by
Thaddy
[
Today
at 01:08:40 pm]
macOS 14+ Install Instruc...
by
alchymylab
[
Today
at 12:49:31 pm]
Anyway to "embed" Windows...
by
jamie
[
Today
at 11:36:00 am]
Hello! Anything new?
by
JuhaManninen
[
Today
at 11:22:16 am]
C/C++ code to Object Pasc...
by
domasz
[
Today
at 10:44:20 am]
[Solved] Saving a workboo...
by
Kaljakoira
[
Today
at 09:09:59 am]
Pipewire API
by
Thausand
[
Today
at 07:38:06 am]
Good GPU accelerated math...
by
myisjwj
[
Today
at 03:17:06 am]
Debian removes FPC/Lazaru...
by
Fred vS
[March 09, 2026, 11:17:03 pm]
REST Server/Client, how t...
by
valdir.marcos
[March 09, 2026, 10:18:36 pm]
TSpeedButton qt6 styleshe...
by
dsiders
[March 09, 2026, 09:40:21 pm]
Purpose of TProcessUTF8
by
Thaddy
[March 09, 2026, 09:08:03 pm]
Z80 ZX Spectrum and Syste...
by
Thaddy
[March 09, 2026, 09:04:25 pm]
How to remove consoleApp ...
by
Thaddy
[March 09, 2026, 08:51:40 pm]
Fast Canvas Library V1.05...
by
Gigatron
[March 09, 2026, 08:32:15 pm]
[Solved] Set TSpeedButton...
by
jcmontherock
[March 09, 2026, 04:08:22 pm]
[SOLVED] Set horizontal s...
by
rvk
[March 09, 2026, 03:57:47 pm]
How many lines is too man...
by
440bx
[March 09, 2026, 12:51:24 pm]
« previous
next »
Print
Pages: [
1
]
Author
Topic: [SOLVED]Foreign key in DBgrid shows as (MEMO) (Read 4169 times)
Ianspeed
Newbie
Posts: 2
[SOLVED]Foreign key in DBgrid shows as (MEMO)
«
on:
September 16, 2016, 10:34:03 am »
Hi All, sorry if I posted this in the wrong section or something else, my first post! Coming back in to programming from a long break from Delphi! Really impressed with Lazarus! Here's my problem. Have a table with an associated table connected with a foreign key. This just holds the card type (PG5x7, LG5x7, DL and PDL) this associated file is for a lookup on the card type. This works in SQLite Studio but doesn't work in my test project or the Lazarus desktop database, my thoughts are I have set something up wrong in the database, as surely the DBGrid should just see the associated link to card type and create a lookup field? Or maybe I'm wrong and have to code for it? I have scoured the web of all knowledge(think it ran dry with this one!), but there doesn't seem to be a direct answer or problem like this, so I guess it's something simple I'm missing!
«
Last Edit: September 21, 2016, 01:32:06 pm by Ianspeed
»
Logged
vdubeau
New Member
Posts: 27
Re: Foreign key in DBgrid shows as (MEMO)
«
Reply #1 on:
September 17, 2016, 10:18:53 pm »
I'm pretty new to Lazarus myself but I have run across this. You probably have the field defined as TEXT. DBGrid seems to interpret this as a memo field and can't display it. Change the field type to VARCHAR (I know they are really the same to SQLIte) and DBGrid should display it correctly.
Logged
Ianspeed
Newbie
Posts: 2
Re: Foreign key in DBgrid shows as (MEMO)
«
Reply #2 on:
September 19, 2016, 10:46:06 am »
Thanks vdubeau,
This now shows the data in the DBGrid, but unfortunately still won't give me a drop down selection, does this have to be coded manually? Thanks
Logged
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Forum
»
Programming
»
Databases
»
[SOLVED]Foreign key in DBgrid shows as (MEMO)
TinyPortal
© 2005-2018