Auto fill from database

Auto fill from database

I am trying to create an application, I would like it to auto fill in the text boxes if I have information in the database for that category. So if I select X from the drop down list and there is information on about height, weight I would like that to be filed in, but if its missing length I would like the left blank so someone could add that information. How do I do that?