Query is truncating Memo Filed Data (1 Viewer)

chapc

New member
Local time
Today, 03:22
Joined
Apr 10, 2012
Messages
2
I'll start out with I'm not real good at building sql queries and the fact that MS Access truncates data from memo fields doesn't help.

I'm building a test generator and some of the questions are greater than 255 (500 words tops though) so they are in a memo field.

I'm trying to randomly grab a number of questions and using this sql to get them.

SELECT TOP 50 * INTO HoldingPen FROM TotalTestBank WHERE Chapter in ( " & WhichChaps & ") and randomizer() = 0 ORDER BY rnd(isnull(ID) * 0 +1);"

WhichChaps is gotten from user input so for example it can be 1,2,5,7 or 1-3

This works - but I can't figure out how to get around the truncating issue. The memo field is called memoQ

Any ideas would be greatly appreciated
 
Last edited:

PNGBill

Win10 Office Pro 2016
Local time
Today, 19:22
Joined
Jul 15, 2008
Messages
2,271
Where is MemoQ in your sql ?
What is HoldingPen ? Memo or Text ?
 

chapc

New member
Local time
Today, 03:22
Joined
Apr 10, 2012
Messages
2
Thanks for the reply

MemoQ is a memo field in the TotalTestBank table collected with the "SELECT TOP 50 * INTO " rather than calling each field seperately and HoldingPen is the name of the table I load the query into.

HoldingPen is pre-built with all the fields defined and MemoQ is a memo field in it.

The interesting thing is TotalTestBank contains the full correct data in the MemoQ field (all 500 or so words) but the query only populates the first 255 chars of the corresonding MemoQ field in the HoldingPen table.
 

Users who are viewing this thread

Top Bottom