Java SQL ResultSet Read getValue(ResultSet rs, String sField)

Here you can find the source of getValue(ResultSet rs, String sField)

Description

get Value

License

Open Source License

Declaration

public static String getValue(ResultSet rs, String sField)
            throws SQLException 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import java.sql.ResultSet;
import java.sql.SQLException;

public class Main {
    public static String getValue(ResultSet rs, String sField)
            throws SQLException {
        String sRet = rs.getString(sField);
        sRet = (sRet == null) ? "" : sRet;
        return sRet;
    }/*  w  w w.j  a v  a2  s  .  c  o m*/
}

Related

  1. getURI(ResultSet rs, int col)
  2. getUUIDFromResultSet(ResultSet rset, String name)
  3. getValue(int type, ResultSet resultSet, int columnIndex)
  4. getValue(ResultSet result, String strField)
  5. getValue(ResultSet resultSet, String columnName, E defaultValue)
  6. getValue4Type(ResultSet rs, String column, Class typeClass)
  7. getValueByObjectType(ResultSetMetaData metaData, ResultSet rs, int index)
  8. getValueFromResultSet(int index, final ResultSet resultSet, final Class type)
  9. readBitBoolean(ResultSet result, int index)