- Trending Categories
- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- MS Excel
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP
- Physics
- Chemistry
- Biology
- Mathematics
- English
- Economics
- Psychology
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Found 4336 Articles for Java 8
251 Views
The tag is used to specify the encoding type used by forms that post data back to the Web application.AttributeThe tag has the following attributes −AttributeDescriptionRequiredDefaultkeyName of character encoding you want to apply when decoding request parameters.YesNoneYou use the tag when you want to specify the character encoding for decoding data posted from forms. This tag must be used with character encodings that are different from ISO-8859-1. The tag is required since most browsers do not include a Content-Type header in their requests.The purpose of the tag is to specify the content type of the request. ... Read More
141 Views
The tag maps key to the localized message and performs the parametric replacement.AttributeThe tag has the following attributes −AttributeDescriptionRequiredDefaultkeyMessage key to retrieveNoBodybundleResource bundle to useNoDefault bundlevarName of the variable to store the localized messageNoPrint to pagescopeThe scope of the variable to store the localized messageNoPageExample JSTL fmt:message Tag You will receive the following result −One Two Three
2K+ Views
SQL's use of NULL values and Java's use of null are different concepts. So, to handle SQL NULL values in Java, there are three tactics you can use:Avoid using getXXX( ) methods that return primitive data types.Use wrapper classes for primitive data types, and use the ResultSet object's wasNull( ) method to test whether the wrapper class variable that received the value returned by the getXXX( ) method should be set to null.Use primitive data types and the ResultSet object's wasNull( ) method to test whether the primitive variable that received the value returned by the getXXX( ) method should ... Read More
332 Views
The ResultSet interface provides a method named getTime() this method accepts an integer parameter representing the index of the column, (or, a String parameter representing the name of the column) from which you need to retrieve the time value. To retrieve time value from a table −Register the driver class using the registerDriver() method of the DriverManager class. Pass the driver class name to it, as parameter.Connect to the database using the getConnection() method of the DriverManager class. Passing URL (String), username (String), password (String) as parameters to it.Create a Statement object using the createStatement() method of the Connection interface.Execute ... Read More
240 Views
The core group of tags is the most commonly used JSTL tags. Following is the syntax to include the JSTL Core library in your JSP −Following table lists out the core JSTL Tags −S.No.Tag & Description1Like , but for expressions.2Sets the result of an expression evaluation in a 'scope'3Removes a scoped variable (from a particular scope, if specified).4Catches any Throwable that occurs in its body and optionally exposes it.5Simple conditional tag which evalutes its body if the supplied condition is true.6Simple conditional tag that establishes a context for mutually exclusive conditional operations, marked by and .7Subtag of that ... Read More
228 Views
You can insert time values in SQL using the time datatype, The java.sql.Time class maps to the SQL Time type.The PreparedStatement interface provides a method named setTime(). Using this you can insert time into a table. This method accepts two parameters −An integer representing the parameter index of the place holder (?) to which we need to set date value.A Time object representing the time value to be passed. The constructor of java.sql.Time class accepts a variable of long type representing the number of milliseconds from the epoch (standard base time I.e. January 1, 1970, 00:00:00 GMT).ExampleAssume we have created ... Read More
4K+ Views
The ResultSet interface provides a method named getDate() this method accepts an integer parameter representing the index of the column, (or, a String parameter representing the name of the column) from which you need to retrieve the date value. To retrieve date value from a table −Register the driver class using the registerDriver() method of the DriverManager class. Pass the driver class name to it, as parameter.Connect to the database using the getConnection() method of the DriverManager class. Passing URL (String), username (String), password (String) as parameters to it.Create a Statement object using the createStatement() method of the Connection interface.Execute ... Read More
6K+ Views
You can insert date values in SQL using the date datatype, The java.sql.Date class maps to the SQL DATE type.The PreparedStatement interface provides a method named setDate(). Using this you can insert date into a table. This method accepts two parameters −An integer representing the parameter index of the place holder (?) to which we need to set date value.a Date object representing the date value to be passed. The constructor of java.sql.Date class accepts a variable of long type representing the number of milliseconds from the epoch (standard base time I.e. January 1, 1970, 00:00:00 GMT).ExampleAssume we have created ... Read More
1K+ Views
You can insert date values in SQL using the date datatype, The java.sql.Date class maps to the SQL DATE type.The PreparedStatement interface provides a method named setDate(). Using this you can insert date into a table. This method accepts two parameters −An integer representing the parameter index of the place holder (?) to which we need to set date value.a Date object representing the date value to be passed. The constructor of java.sql.Date class accepts a variable of long type representing the number of milliseconds from the epoch (standard base time I.e. January 1, 1970, 00:00:00 GMT).ExampleAssume we have created ... Read More
164 Views
A BLOB is binary large object that can hold a variable amount of data with a maximum length of 65535 charactersThese are used to store large amounts of binary data, such as images or other types of files.A CLOB stands for Character Large Object in general, an SQL Clob is a built-in datatype is used to store large amount of textual data. Using this datatype, you can store data up to 2, 147, 483, 647 characters.Blob and Clob data types together are known as LOB (Large Object) datatypes. Following are the restrictions on these datatypes.Cannot compare: We cannot compare CLOB ... Read More