Quantcast
Channel: JDBC
Viewing all articles
Browse latest Browse all 7

How to insert BLOB/CLOB data in DB using JDBC ?

$
0
0

Use the following code to insert LOB data in DB using JDBC.

publicstaticvoid insertLob()throwsException
    {
            String dbUrl ="jdbc:oracle:thin:@<host_name>:<port_number>:<DB_Name>";
            Connection con =null;
            ResultSet rs =null;
            PreparedStatement psIns =null;
           
            try
            {
                    Class.forName("<Driver_Name>");

                    con =DriverManager.getConnection(dbUrl, "<userName>", "<passWord>");

                    psIns = con

Viewing all articles
Browse latest Browse all 7

Trending Articles