using 12 code c as the example, 12 would be your summary field. "code" would be layout text and "c" would be your code field.
You can just have [summaryfield] code [code field], where [ ] denotes standard fields or you can use merge fields created by selecting that option from the Insert menu to produce:
<<SummaryField>> code <<CodeField>>
which will look like:
12 code c
when you leave layout mode.