Skip to Content
0
Former Member
Dec 23, 2014 at 10:07 AM

UPSERT in XSJS Issues

318 Views

Hi Experts

I'm trying to INSERT/UPSERT values into my tables using the following xsjs code

try{

var conn = $.db.getConnection();

var query ="UPSERT \"NEO_EZPCFVLMDTZUPGEXJXXXXX\".\"LinkedIN_Connections\" VALUES('x','x','x','x','x','x','x','x','x')";

$.response.setBody("Success");

$.trace.debug(query);

var pstmt=conn.prepareStatement(query);

var rs=pstmt.execute();

$.response.setBody(rs);

conn.commit();

}

but i'm getting the following error(p.s I'm using a trial system)

dberror(Connection.prepareStatement): 258 - insufficient privilege: Not authorized at ptime/query/checker/query_check.cc:2547