run query on sqldatasource or datalist

M

mharness

Hello,

Not sure if what I'm trying to do is possible or even a good idea. I have
a datalist that can contain maybe 100 items shared among perhaps 20
accounts. Looks something like this:

accountid itemid
a 1
a 2
b 5
b 6
a 8
c 9

I would like to provide a dropdown unique list of accountids for the user to
choose from and then apply an accountid filter to the datalist so the user
only sees items belonging to the chosen accountid.

The dropdown list would look like this:
a
b
c

and when the user makes a choice--like "a"-- the datalist would look like
this:

a 1
a 2
a 8

Pretty sure I can do all that but (I think) I need to be able to run a
grouped query on the datalist contents to populate the dropdown list and
that's where I'm stuck.

Any comments, suggestions, or alternatives would be appreciated.

Thanks,

Mike
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,432
Messages
2,571,682
Members
48,796
Latest member
Greg L.

Latest Threads

Top