Announcement Announcement Module
Collapse
No announcement yet.
Syntax question Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Syntax question

    Will queryForList get the data I need without locking a table?

    Can someone please provide a code snippet as an example?

  • #2
    Hi rachel,
    query/select usually doesn't lock db table.

    if you read the SprignAPI for JdbcTemplate, you will see the signature of queryForList return a java.util.List object. Each entry is a java.util.Map that contains each record of your query, wich each key is the column name. You just need to loop over the collection to get the data.

    I believe Spring sample like petstore and clinic has examples on using this class.

    Comment

    Working...
    X