There is no reason you can't use a sql query for any of the form controls within any of the objects (forms, custom tables, page types, etc.) That's what they are meant for.
So are you stating that you have a custom table of "widgets" and you want to have a dropdown list form control that is a list of those widgets without the user having to actually write the query? If so, you should be able to clone the existing dropdown list form control and set default property values for it (query and such) and simply rename it. I don't believe this would involve any coding, just configuring.