fixed template generate sql. https://groups.google.com/forum/?hl=ja%3Fhl%3Dja#!topic/starbug1-users/fjVJpUQgJuw