Rishi Raj has Published 119 Articles

How to use JavaScript to hide a DIV when the user clicks outside of it?

Rishi Raj

Rishi Raj

Updated on 18-Sep-2019 08:30:50

1K+ Views

To hide a div when the user clicks outside of it, try to run the following codeExampleLive Demo                    window.onload = function(){             var hideMe = document.getElementById('hideMe');             document.onclick = function(e){                if(e.target.id !== 'hideMe'){                   hideMe.style.display = 'none';                }             };          };             Click outside this div and hide it.    

Java ResultSet findColumn() method with example

Rishi Raj

Rishi Raj

Updated on 30-Jul-2019 22:30:26

1K+ Views

When we execute certain SQL queries (SELECT query in general) they return tabular data.The java.sql.ResultSet interface represents such tabular data returned by the SQL statements.i.e. the ResultSet object holds the tabular data returned by the methods that execute the statements which quires the database (executeQuery() method of the Statement interface in general).The ... Read More

Java ResultSet relative() method with example

Rishi Raj

Rishi Raj

Updated on 30-Jul-2019 22:30:26

940 Views

When we execute certain SQL queries (SELECT query in general) they return tabular data.The java.sql.ResultSet interface represents such tabular data returned by the SQL statements.i.e. the ResultSet object holds the tabular data returned by the methods that execute the statements which quires the database (executeQuery() method of the Statement interface in general).The ... Read More

Java ResultSetMetaData getColumnCount() method with example?

Rishi Raj

Rishi Raj

Updated on 30-Jul-2019 22:30:26

1K+ Views

The getColumnCount() method of the ResultSetMetaData (interface) retrieves the number of the columns of the current ResultSet object.This method returns an integer value representing the number of columns.To get the ResultSetMetaData object, you need to:Register the Driver: Select the required database register the Driver class of the particular database using the registerDriver() ... Read More

Java ResultSetMetaData getCatalogName() method with example

Rishi Raj

Rishi Raj

Updated on 30-Jul-2019 22:30:26

251 Views

In general a catalog is a directory which holds information about data sets, file or, a database. Whereas, in a database, catalog holds the list of all the databases, base tables, views (virtual tables), synonyms, value ranges, indexes, users, and user groups.The getCatalogName() method of the ResultSetMetaData (interface) retrieves the name of the ... Read More

Java DatabaseMetaData supportsStoredProcedures() method with example

Rishi Raj

Rishi Raj

Updated on 30-Jul-2019 22:30:26

109 Views

The supportsStoredProcedures() method of the DatabaseMetaData interface is used to determine whether the underlying database supports stored procedures.This method returns a boolean value which is −True, when the underlying database supports stored procedures.False, when the underlying database doesn't support stored procedures.To determine whether the underlying database supports stored procedures−Make sure ... Read More

Java DatabaseMetaData supportsResultSetConcurrency() method with example

Rishi Raj

Rishi Raj

Updated on 30-Jul-2019 22:30:26

266 Views

While creating a Statement object you can choose the concurrency and the type of the ResultSet object using the following variant of the createStatement() method −Statement createStatement(int resultSetType, int resultSetConcurrency)ResultSet ConcurrencyThe concurrency of the ResultSet object determines whether its contents can be updated or not.The ResultSet interface provides two values to specify ... Read More

How to establish a connection with the database using the properties file in JDBC?

Rishi Raj

Rishi Raj

Updated on 30-Jul-2019 22:30:26

2K+ Views

One of the variant of the getConnection() method of the DriverManager class accepts url of the database, (String format) a properties file and establishes connection with the database.Connection con = DriverManager.getConnection(url, properties);To establish a connection with a database using this method −Set the Driver class name as a system property −System.setProperty("Jdbc.drivers", ... Read More

Java DatabaseMetaData getTableTypes() method with example

Rishi Raj

Rishi Raj

Updated on 30-Jul-2019 22:30:26

349 Views

The getTableTypes() method of the DatabaseMetadata interface is used to find out the type of tables supported by the underlying database.This method returns a ResultSet object holding the names of table types in each row in String format, under the column TABLE_TYPE.To get the description DatabaseMetadata object.Make sure your database ... Read More

How to move the ResultSet cursor to the previous row in JDBC?

Rishi Raj

Rishi Raj

Updated on 30-Jul-2019 22:30:26

921 Views

Whenever we execute SQL statements using the executeQuery() method, it returns a ResultSet object which holds the tabular data returned by the SELECT queries(in general).The ResultSet object contains a cursor/pointer which points to the current row. Initially this cursor is positioned before first row (default position).You can move the cursor ... Read More

Previous 1 ... 5 6 7 8 9 ... 12 Next
Advertisements