Could I initial the "SELECT" control all by myself?(in the OnLoad event)

Because of some reason, I cannot finish all the code in a single SQL. So could I initial the SELECT control all by myself? Using the automatic and manual method either cannot solve my problem.

So could I add all items all by myself in the OnLoad event?

Maybe you give us an example, which supposedly does not work?

Such as a tree saved in the table like this:

id pid name
1 0 a
2 1 b
3 2 c
4 0 d

They should like this:
a
-b
–c
d

I want insert them to a select control just like above.

How could finish that in a SQL( with no stored-procedure).

I think that you may find this link helpful:

http://www.scriptcase.net/forum/showthread.php?4318-Manipulate-Select-Lookup-Values&highlight=tree