Two principal methods of determining the conformation of short pieces of polypeptide backbone in proteins have been developed: using a database of known structures and systematically generating all conformations. In this paper, we compare the effectiveness of these two techniques. The completeness of the database for segments of different lengths is examined and it is found to contain most conformations for segments seven residues long, but to deteriorate rapidly for longer regions. When the database segment is to be incorporated into the rest of a structure, at least seven residues are required to build four new residues, because of the need to position the segment relative to the rest of the structure. It is found that such positioning using flanking residues results in large errors in the inserted region. We conclude that the database method is currently not effective for comparative modeling, even for short segments. The systematic search procedure is found to generate almost all structures of short segments found in proteins. In contrast to the database method, low root mean square error structures are obtained for a set of trial segments embedded in the rest of a protein structure. Thus, it should be considered the method of choice.