Passing multiple arguments into a SELECT without using a complex object

后端 未结 5 2083
轻奢々
轻奢々 2020-12-15 11:39

I am trying to pass in startSequenceId, stopSequenceId, orderNumber into the SQL map, however, i don\'t wish to use a typed object, i.

5条回答
  •  离开以前
    2020-12-15 12:19

    You can use the built in parameterType 'map' eg

    Map parms = new HashMap();
    parms.put("name", "abc");
    parms.put("phone", "123");
    parms.put("email", "123@email.com");
    
    List list = myBatis.selectList("getContacts",parms);
    
    
    
    
    

提交回复
热议问题