Skip to main content
Inspiring
November 21, 2009
Question

Populate Drop Down with cfquery

  • November 21, 2009
  • 1 reply
  • 475 views

Hi all,

I need to populate my hub select box based on division select box then populate node based on the selection of hub. I know this is combination of js and cf. I dont want f5 the screen though. Thank u all.

Division list:

select  distinct DIVISION

from    OPS$NEW.REF_DIVISION

HUB List:

select  distinct b.HUB

from    OPS$NEW.REF_DIVISION    a,

        OPS$NEW.SUB_COUNT       b

where   a.PRIN          = b.PRIN

and     a.DIVISION      = < DIVISION>

order   by 1

NODE List:

select  distinct b.NODE

from    OPS$NEW.REF_DIVISION    a,

        OPS$NEW.SUB_COUNT       b

where   a.PRIN          = b.PRIN

and     a.DIVISION      = < DIVISION>

and     b.HUB           = <HUB>

order   by 1

This topic has been closed for replies.

1 reply

Inspiring
November 21, 2009

The term you are looking for is related selects.  There is more than one way to do it.  Here is one.  http://www.pathcom.com/~bracuk/code/RelatedSelects.htm

If you google "coldfusion related selects" you'll find some tutorials.

emmim44Author
Inspiring
November 22, 2009

I tried a different way of doing it....Thank you Dan