@Query(value="SELECT relation_contract FROM contract where contract_type=2 and status!='del'",nativeQuery=true)
List<Long>findRelationContractBySideAgre();
@Query(value="SELECT * from contract where (contract_code = ?1 or relation_code = ?1) and create_time <= ?2 and id<> ?3 and contract_type <> '1'",nativeQuery=true)
@Query(value="SELECT * from contract where contract_code = ?1 UNION SELECT * from contract where relation_code = ?1 and create_time <= ?2 and id<> ?3 and contract_type = '2'",nativeQuery=true)