Focal Point
[SOLVED] Combine Fields for List Box

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/2847058516

January 25, 2012, 02:24 PM
a415
[SOLVED] Combine Fields for List Box
Currently, I have a POPULATION list box in my fex so users can choose multiple constituent types. For example:
ALL ALUMNI
ALL DONORS
ALL UNDERGRADUATES
ALL GRADUATES

Now, I want to add majors in my report. In my FEX, I want to combine the following fields into one:

DEGREE.UNDERGRAD_MAJOR_CODE
DEGREE.UNDERGRAD_MAJOR_DESCRIPTION
DEGREE.GRAD_MAJOR_CODE
DEGREE.GRAD_MAJOR_DESCRIPTION

So it will look like this in ONE LIST BOX:
MAJOR_DESCRIPTION (MAJOR_CODE)

So it will list all majors and codes REGARDLESS of if it is UNDERGRAD or GRAD. This way, if someone chooses "Undergrad" and specific majors, it will pull all undergrads with that major. OR if they choose "Alumni" and majors - it will list all alumni with those majors regardless of being a grad or undergrad. The reason why I want to include (MAJOR_CODE) is because some of our majors have OLD codes from an older database that we no longer use, however, alumni still have those codes in the DB and some users want to see the specific codes.

I hope this is clear. Is there a way to combine these fields into one list box? I'm trying to avoid TWO major boxes if a user wants to select both GRAD & UNDERGRAD with 20 different majors selected in each box.

This message has been edited. Last edited by: Kerry,


8009
Windows 7
Excel/HTML/AHTML/PDF
January 25, 2012, 02:28 PM
John_Edwards
Consider creating a DEFINE field in your master file that concatenates the two fields together. When you build your dropper select from that field and you should have all the combinations available in your table.



January 26, 2012, 01:16 PM
a415
I understand that I can concatenate the major description with the major code fields... but how do I merge DEGREE.UNDERGRAD_MAJOR_DESCRIPTION with DEGREE.GRAD_MAJOR_DESCRIPTION so that there is only one MAJOR_DESCRIPTION?


8009
Windows 7
Excel/HTML/AHTML/PDF
January 26, 2012, 01:54 PM
Rao D
Create 2 individual hold files for undergrad_major_description and grad_major_description and merge those hold files using FILEDEF. From that you can create a permanent hold file and use that permanent hold file to populate the values into the list box.

You can create a schedule and update that permanent hold file (master file) on a timely basis.


WebFOCUS - ver8201
[ReportingServers: Windows 64bit;
Client: tomcat and IIS on windows 2012
AppStudio

February 02, 2012, 02:18 PM
a415
I will try this. Thank you!


8009
Windows 7
Excel/HTML/AHTML/PDF
February 02, 2012, 03:21 PM
Francis Mariani
You can create two temporary files and use the MORE command to concatenate them.


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
February 06, 2012, 01:21 PM
a415
Thank you, Francis.

I haven't created the HOLD yet, so I'll definitely add the MORE on my list to concatenate. Smiler


8009
Windows 7
Excel/HTML/AHTML/PDF