Karthikeya Boyini has Published 2383 Articles

Display the warning message when a FLOAT value is inserted into DECIMAL in MySQL?

karthikeya Boyini

karthikeya Boyini

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

103 Views

You can create a temporary table with data type DECIMAL to get a warning when a float value is inserted into an int column. Display the same warning using SHOW WARNINGS.Let us create a table to understand. The query is as follows to create a table.mysql> create temporary table WarningDemo ... Read More

What is session attribute in JSP?

karthikeya Boyini

karthikeya Boyini

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

2K+ Views

The session attribute indicates whether or not the JSP page uses HTTP sessions. A value of true means that the JSP page has access to a builtin session object and a value of false means that the JSP page cannot access the builtin session object.Following directive allows the JSP page ... Read More

Can we test XPath expression in JSP?

karthikeya Boyini

karthikeya Boyini

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

184 Views

The tag evaluates a test XPath expression and if it is true, it processes its body. If the test condition is false, the body is ignored.AttributeThe tag has the following attributes −AttributeDescriptionRequiredDefaultselectThe XPath expression to be evaluatedYesNonevarName of the variable to store the condition's resultNoNonescopeScope of the variable ... Read More

What is isScriptingEnabled Attribute in JSP?

karthikeya Boyini

karthikeya Boyini

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

221 Views

The isScriptingEnabled attribute determines if the scripting elements are allowed for use.The default value (true) enables scriptlets, expressions, and declarations. If the attribute's value is set to false, a translation-time error will be raised if the JSP uses any scriptlets, expressions (non-EL), or declarations.The attribute's value can be set to ... Read More

SecureRandom nextBytes() method in Java

karthikeya Boyini

karthikeya Boyini

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

303 Views

The number of random bytes as specified by the user can be obtained using the nextBytes() method in the class java.security.SecureRandom. This method requires a single parameter i.e. a random byte array and it returns the random bytes as specified by the user.A program that demonstrates this is given as ... Read More

Create an aggregate checksum of a column in MySQL

karthikeya Boyini

karthikeya Boyini

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

448 Views

You can use CRC32 checksum for this. The syntax is as follows −SELECT SUM(CRC32(yourColumnName)) AS anyAliasName FROM yourTableName;To understand the above syntax, let us create a table. The query to create a table is as follows −mysql> create table CRC32Demo    -> (    -> Id int NOT NULL AUTO_INCREMENT ... Read More

IntBuffer slice() method in Java

karthikeya Boyini

karthikeya Boyini

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

96 Views

A new IntBuffer with the content as a shared subsequence of the original IntBuffer can be created using the method slice() in the class java.nio.IntBuffer. This method returns the new IntBuffer that is read-only if the original buffer is read-only and direct if the original buffer is direct.A program that ... Read More

Please share a running example of include directive in JSP

karthikeya Boyini

karthikeya Boyini

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

51 Views

The include directive is used to include a file during the translation phase. This directive tells the container to merge the content of other external files with the current JSP during the translation phase. You may code include directives anywhere in your JSP page.The general usage form of this directive ... Read More

Can we have a switch statement in JSP for XPath expression?

karthikeya Boyini

karthikeya Boyini

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

282 Views

The tag works like a Java switch statement. With this, you can choose between a number of alternatives. Where the switch statement has the case statements, the tag has the tags. In a similar way, a switch statement has the default clause to specify a default action ... Read More

Declare syntax error in MySQL Workbench?

karthikeya Boyini

karthikeya Boyini

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

2K+ Views

The DECLARE syntax must between BEGIN and END. The syntax is as follows −BEGIN DECLARE yourVariableName1 dataType, DECLARE yourVariableName2 dataType, . . . . ENDHere is the query to avoid DECLARE syntax error in MySQL −mysql> DELIMITER // mysql> create procedure declare_Demo()    -> BEGIN    -> DECLARE Name varchar(100); ... Read More

Advertisements