Ramiro,
A few options:
01. Try:
CHOOSE textvar FROM #VALUES FOR textcolumn FROM bigtable +
GROUP BY textcolumn02. Create a pre-defined VIEW with DISTINCT TextColumn values and
then use that view for CHOOSE SET ERROR MESSAGE 677 OFF
DROP VIEW TextValuesView
CREATE VIEW TextValuesView (TextColumn) AS SELECT +
TextColumn FROM BigTable GROUP BY TextColumn
SET ERROR MESSAGE 677 ON CHOOSE TextVar FROM #VALUES FOR TextColumn FROM +
TextValuesView03. You can always narrow the selection by giving user the option to
provide a first few characters using the DIALOG command and
then use the LIKE option fin CHOOSE command:Example:
SET VAR vMany TEXT = (CVAL('MANY'))
SET VAR vQuotes TEXT = (CVAL('QUOTES'))
SET VAR vDialogValue TEXT = NULL
SET VAR vCaption TEXT = 'Text Column Search'
SET VAR vTextValue TEXT = NULL
SET VAR vRows INTEGER = 0 LABEL AskValue
CLS
DIAL 'Enter First Few Characters :' vDialogValue=24 vEndKey +
1 CAPTION .vCaption AT CENT CENT
IF vEndKey = '[Esc]' THEN
GOTO Done
ENDIF
SET VAR vLike = (.vQuotes+.vDialogValue+.vMany+.vQuotes) SELECT COUNT(*) INTO vRows INDIC ivRows FROM BigTable +
WHERE TextColumn LIKE &vLike
IF vRows = 0 THEN
PAUSE 2 USING 'No Matching Record(s)!' CAPTION .vCaption +
AT CENT CENT
GOTO AskValue
ENDIF CLS
CHOOSE vTextValue FROM #VALUES FOR TextColumn +
FROM BigTable WHERE TextColumn LIKE &vLike +
GROUP BY TextColumn +
AT CENT CENT TITLE 'Select Text Column' CAPTION .vCaption +
LINES 18 FORMATTED
IF vTextValue IS NULL OR vTextValue = '[Esc]' THEN
GOTO Done
ENDIF-- Do what you have to do here
LABEL Done
CLEAR VAR iv%,vMany,vQuotes,vDialogValue,vCaption,vTextValue,vRows
RETURNEnjoy and make sure to have fun!
Very Best R:egards,
Razzak.
At 09:50 AM 11/5/2003 -0400, Ramiro M�ndez wrote:
I have the following command:
CHOOSE textvar FROM #VALUES FOR DISTINCT textcolumn FROM bigtable The bigtable is about 17.000 rows, using RBWIN-65 (1.866xRT03) the following message is displayed: "Insufficient memory to continue this function".
How can I manage the memory to avoid this problem? Thanks in advance, cordially,
Ramiro M�ndez Superintendencia General del SIRESE La Paz Bolivia - South America

