BookmarkSubscribeRSS Feed
deleted_user
Not applicable
I'm building a web application that uses HtmSql. The first drop down list connects to a SAS data set and populates the drop down list with a list of values. I need the second drop down list to connect to the same SAS data set and populate the drop down list this time excluding the users selection from the first drop down list.

Any suggestions on how to make this happen?
3 REPLIES 3
Cynthia_sas
SAS Super FREQ
Hi:
htmSQL is part of SAS/IntrNet and while SAS/IntrNet does use ODS, very little of htmSQL uses ODS. Usually, you create htmSQL data queries to create custom HTML forms based on SAS data sources.

I remember doing something similar to this when I had access to SAS/IntrNet. As I remember, we built one page, that was the first query -- perhaps querying for Region. Then the results of that query built a second form on a second page that showed what they had just selected and then gave them more choices. As I remember, we used hidden form fields to pass input from the first query and to the second form, so it could be used in a second htmSQL query -- then based on what came back from the second query, they had a choice of what they wanted to run -- and then we kicked off a Graph program using the Application Dispatcher.

For more help with SAS/IntrNet and with htmSQL, your best bet is to open a track with Tech Support.

cynthia
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
Though I have no experience, the SUGI/SGF paper below mentions a two-level drill-down generated by HTMSQL in a single HTML document with multiple queries, although the HTML tags are suppressed. The SAS Support team know their stuff, so like Cynthia mentioned, your quickest route to success would likely be to open a track with your question and provide any / all details about requirements you have collected.

Scott Barry
SBBWorks, Inc.

Experience Learned in Deploying htmSQLâ Based Application
http://www.dc-sug.org/htmsql.pdf
JackHamilton
Lapis Lazuli | Level 10
If I'm understanding the question correctly, I would use JavaScript to selectively populate the second dropdown based on the selection in the first dropdown. You would need to have a hidden list of all the items and populate the second dropdown from that, unless there's something new in HTML since I last did something like this. Keeping a hidden list means that you don't have to go back to the server to populate the second dropdown - you just have an OnClick action.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 662 views
  • 0 likes
  • 4 in conversation