参考Jerry的博客:
https://blogs.sap.com/2017/05/08/adbc-and-jdbc/
HANA server side JavaScript也能直接访问数据库了,原理同我blog里的JDBC和ADBC,代码如下:
var conn = $.db.getConnection();
var pstmt = conn.prepareStatement( " SELECT * FROM accounts WHERE custID='" +
$.request.parameters.get("id"));
var rs = pstmt.executeQuery();
类似的,MongoDB的连接
要获取更多Jerry的原创文章,请关注公众号"汪子熙":
网友评论