* Type-mapping function translation
*/
public Object visit(ASTLocate node, Object data) {
StringBuffer buf = (StringBuffer) data;
JDBCFunctionMappingMetaData function = typeMapping.getFunctionMapping(JDBCTypeMappingMetaData.LOCATE);
Object[] args = new Object[3];
args[0] = new NodeStringWrapper(node.jjtGetChild(0));
args[1] = new NodeStringWrapper(node.jjtGetChild(1));
if (node.jjtGetNumChildren() == 3) {
args[2] = new NodeStringWrapper(node.jjtGetChild(2));
} else {
args[2] = "1";
}
// add the sql to the current buffer
function.getFunctionSql(args, buf);
return buf;
}