Tom, it looks like the capacity of the RBase Structure that holds the choose is
still at about 50k.  I would guess if you set your choose "Where Limit = 760) it
would work.  In these instances, I have used a bracketed choose that limits the
number of items in the choose like:
*(Note it does require an Int for an index [col Idx] that is applied in a sorted
order.  I know this adds a little overhead when you add a customer to the list,
you have to re-autonumber the table, but it is the workaround for this
limitation of the volume of a choose statement)


*(ChoItem mod 011701 mbyerley)
LABEL bgproc
  CLS
  SET VAR vbgrng INTEGER = 0
  SET VAR vndrng INTEGER = (.vbgrng + 499)
  SELECT COUNT (*) INTO vcnt IND vin0 FROM item
  SET KEYMAP [F2] TO [ESC]
  SET VAR vitem TEXT = NULL
  SET VAR vtrue = 0
  WHILE vtrue = 0 AND vbgrng < .vcnt THEN
    SET VAR vtitle = ((CTXT(.vbgrng)) & '-' & (CTXT(.vndrng)))
    SET VAR vtitle = (.vtitle & 'Items of' & (CTXT(.vcnt)) + +
    '. [F2] Advances To Next Group')
    CHOOSE vitem FROM #VALUES FOR ((LJS(item,18)) & descript) item FROM item +
    WHERE +
    (idx BETWEEN .vbgrng AND .vndrng) ORDER BY idx AT CENTER CENTER +
    TITLE .vtitle CAPTION 'Choose Item' LINES 22 FORMATTED
    SET VAR vbgrng = (.vndrng + 1)
    SET VAR vndrng = (.vndrng + 500)
    IF vndrng > .vcnt THEN
      SET VAR vndrng = .vcnt
    ENDIF
    IF vbgrng >= .vcnt THEN
      BREAK
    ENDIF
    IF (LASTKEY(0)) = '[esc]' AND (LASTKEY(1)) <> '[F2]' THEN
      SET VAR vitem = NULL
      SET VAR vtrue = 1
      BREAK
    ENDIF
    IF (LASTKEY(0)) = '[enter]' THEN
      SET VAR vtrue = 1
      BREAK
    ENDIF
  ENDWHILE
LABEL ndproc
  SET KEYMAP [F2] OFF
  CLEAR VAR vbgrng,vcnt,vin0,vmsg,vndrng,vtitle,vtrue,vres1
  RETURN



----- Original Message ----- 
From: <[EMAIL PROTECTED]>
To: "RBG7-L Mailing List" <[EMAIL PROTECTED]>
Sent: Saturday, October 02, 2004 11:25 AM
Subject: [RBG7-L] - RE: NACHA format


> Good Morning and Happy Weekend to all.
>
> I am having trouble with this Choose Statement. I get an Insufficient Memory
error at the end of the option list. The systax is lifted from R:Docs and it is
drawing the columns out of a table with only about 1500 rows.
>
> any direction would be appreciated. -- code is below
>
> thank you
> Tom
>
> LABEL start
> CLEAR VAR vidnumtxt,vidnum,vlines,vrows,vcaption,vyesno,vendkey,iv%
> SET VAR vidnumtxt TEXT = NULL
> SET VAR vidnum INTEGER = NULL
> SET VAR vlines INTEGER = 0
> SET VAR vrows INTEGER = 0
> SET VAR vcaption TEXT = 'Update Existing Contact(s)'
> SET VAR vyesno TEXT = 'No'
> SELECT COUNT(*) INTO vlines INDICATOR ivlines FROM mailingaddress
> IF vlines = 0 THEN
>   PAUSE 2 USING 'No Customer(s) on File!' CAPTION ' ' icon stop
>   GOTO done
> ENDIF
> IF vlines > 20 THEN
>   SET VAR vlines = 20
> ENDIF
> CLS
> CHOOSE vidnumtxt FOR #VALUES +
> FOR ((LJS(lastname, 20) & (LJS(firstname, 20) & (LJS(homeaddress1,
25))))),idnum +
> FROM mailingaddress  ORDER BY lastname +
> TITLE 'Select Donor and then press [Enter] to continue' +
> CAPTION 'List of Contacts' +
> LINES .vlines +
> FORMATTED +
> OPTION WINDOW_CAPTION SMALLINT +
> |title_back_color WHITE +
> |title_font_name times new roman +
> |title_font_size 24 +
> |title_font_color teal +
> |title_bold OFF +
> |title_italic OFF +
> |title_underline OFF +
> |title_strikeout OFF +
> |list_back_color teal +
> |list_font_name verdana +
> |list_font_size 14 +
> |list_font_color WHITE +
> |list_bold OFF +
> |list_italic OFF +
> |list_underline OFF +
> |list_strikeout OFF +
> |window_back_color WHITE
>

Reply via email to