'copybook1' and 'copybook2' are not data names. Data names have level numbers. In your example variable1 is a data name (level 1) and both var-a variables are data names (level 5). You are coding var-a of variable1 twice in your example.
You need to put an intermediate level in eg.
Or you could redefine the shorter field over the longer one - but you woud need some way of knowing which variable you are processing - maybe if the larger variable was set to low values you could check the last two bytes for low values and process accordingly.