Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

how to check if something exists in an sql column java

DatabaseMetaData md = connection.getMetaData();
ResultSet rs = md.getColumns(null, null, "table_name", "column_name");
 if (rs.next()) {
      //Column in table exist
    }
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #check #exists #sql #column #java
ADD COMMENT
Topic
Name
1+2 =