CUBRIDOID에 해당하는 GLO에 주어진 stream을 저장한다. length를 지정할 경우, 주어진 stream을 length 바이트 만큼 저장한다.
void saveGLO(InputStream stream)
void saveGLO(InputStream stream, int length)
CUBRIDConnection
con = (CUBRIDConnection)DriverManager.getConnection(url,user,passwd);
//
filename : testin1, classname : filetest
FileInputStream
inputfile = new FileInputStream("testin1");
CUBRIDOID
oid = con.getNewGLO("filetest", inputfile);
inputfile.close();
//
filename : testin2, classname : filetest
FileInputStream
inputfile = new FileInputStream("testin2");
System.out.println("saveGLO..");
oid.saveGLO(
inputfile );
inputfile.close();
con.commit();
// 이 트랜잭션을
커밋해야 한다.
// CUBRIDOID를 사용시에는 자동 커밋
기능을 사용할
수 없다.
CUBRIDConnection
con = (CUBRIDConnection)DriverManager.getConnection(url,user,passwd);
//
filename : testin1, classname : filetest
FileInputStream
inputfile = new FileInputStream("testin1");
CUBRIDOID
oid = con.getNewGLO("filetest", inputfile);
inputfile.close();
//
filename : testin2, classname : filetest
FileInputStream
inputfile = new FileInputStream("testin2");
System.out.println("saveGLO..");
oid.saveGLO(
inputfile, 100 ); // save just 100 byte
inputfile.close();
con.commit();
// You
must commit this transaction
// NOT
AUTO COMMIT on CUBRIDOID