You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: encoder_avro.go
    path of file: ./repos/cockroach/pkg/ccl/changefeedccl
    
    the code of the file until where you have to start completion: // Copyright 2022 The Cockroach Authors.
//
// Licensed as a CockroachDB Enterprise file under the Cockroach Community
// License (the "License"); you may not use this file except in compliance with
// the License. You may obtain a copy of the License at
//
//     https://github.com/cock
    
func (e *confluentAvroEncoder) rawTableName(eventMeta cdcevent.Metadata) (string, error) {
	target, found := e.targets.FindByTableIDAndFamilyName(eventMeta.TableID, eventMeta.FamilyName)
	if !found {
		return eventMeta.TableName, errors.Newf("Could not find Target for %s", eventMeta)
	}
	switch target.Type {
	case jobspb.ChangefeedTargetSpecification_PRIMARY_FAMILY_ONLY:
		return e.schemaPrefix + string(target.StatementTimeName), nil
	case jobspb.ChangefeedTargetSpecification_EACH_FAMILY:
		return fmt.Sprintf("%s%s.%s", e.schemaPrefix, target.StatementTimeName, eventMeta.FamilyName), nil
	case jobspb.ChangefeedTargetSpecification_COLUMN_FAMILY:
		return fmt.Sprintf("%s%s.%s", e.schemaPrefix, target.StatementTimeName, target.FamilyName), nil
	default:
		return "", errors.AssertionFailedf("Found a matching target with unimplemented type %s", target.Type)
	}
}