Feedback

I'm only ever going to need to name 1 movie, so I changed the select query to just output 1 name at random (sort of).

select Top 1 a.name +case when right(a.name,1) not like '[aeiouy]' and b.pre is not null then b.pre else '' end +b.namefrom #pre a cross join #post bwhere a.name<>b.name -- optional, to eliminate the "SharkShark" optionorder by NEWID()