注釈に基づいて、mybatis を介して mysql に 10 個を超えるプロパティを持つオブジェクトを挿入したいと考えています。しかし、すべてのプロパティを一覧表示する必要があり、不便です。mybatis を介してすべてのプロパティを一覧表示せずに、オブジェクトを簡単に挿入する方法がいくつかあることを知りたいです。これが私のスニペットです。どうもありがとう。
@Insert("insert into poi_shop(name,brand,tags,status,phone,mobile,business_time,address,city,lng,lat,business_type,attribute_json) values(#{name},#{brand},#{tags},#{status},#{phone},#{mobile},#{business_time},#{address},#{city},#{lng},#{lat},#{business_type},#{attribute_json})")
@Options(useGeneratedKeys = true, keyProperty = "id", keyColumn = "id")
public Long insertPoiInfo(PoiBo poiBo);