Ayyan has Published 60 Articles

How Can MySQL virtual GENERATED COLUMNS work with built-in functions?

Ayyan

Ayyan

Updated on 21-Feb-2020 11:39:09

It can be illustrated with the help of an example in which we are creating a virtual generated column in the table named ‘employee_data’. As we know that virtual generated column can be generated with or without using the keyword ‘virtual’.Examplemysql> Create table employee_data(ID INT AUTO_INCREMENT PRIMARY KEY,     ... Read More

ABAP dump while creating an entry in SAP system using SAP JCO

Ayyan

Ayyan

Updated on 14-Feb-2020 05:43:45

This seems to be a problem at ABAP side and not Java side. This is an ABAP dump and you need to useTransaction code: ST22 on ABAP backend to check functional module inSAP system.Once you get the exact details of ABAP dump you are getting, you need to edit the ... Read More

C++ Program Structure

Ayyan

Ayyan

Updated on 11-Feb-2020 05:49:42

The best way to learn a programming language is by writing programs. Typically, the first program beginners write is a program called "Hello World", which simply prints "Hello World" to your computer screen. Although it is very simple, it contains all the fundamental components C++ programs have. Let's look at ... Read More

How can we use MySQL REVERSE() function on column’s data along with WHERE clause?

Ayyan

Ayyan

Updated on 07-Feb-2020 10:45:56

MySQL REVERSE() function can have the column name as an argument to invert its value. If we want to apply some condition/s then it can be used along with WHERE clause as follows:Examplemysql> Select Name, REVERSE(Name) from Student; +---------+---------------+ | Name    | REVERSE(Name) | +---------+---------------+ | Aarav   | ... Read More

What MySQL TRIM() function returns if 1st argument(i.e. BOTH, LEADING, TRAILING) is not specified?

Ayyan

Ayyan

Updated on 07-Feb-2020 05:56:07

By default MySQL will assume the argument BOTH if the 1st argument is not specified in TRIM() function. Following example will demonstrate it.Examplemysql> SELECT TRIM('A' FROM 'ABCDAEFGAA'); +-----------------------------+ | TRIM('A' FROM 'ABCDAEFGAA') | +-----------------------------+ | BCDAEFG                     | +-----------------------------+ 1 row ... Read More

Which MySQL function returns a specified number of characters of a string as output?

Ayyan

Ayyan

Updated on 06-Feb-2020 10:52:19

MySQL returns a specified number of characters of a string with the help of LEFT() and RIGHT() functions.MySQL LEFT() function will return the specified number of characters from the left of the string.SyntaxLEFT(str, length)Here str is the string from which a number of characters would be returned and the length ... Read More

What MySQL ASCII() function returns if I will provide NULL to it?

Ayyan

Ayyan

Updated on 30-Jan-2020 06:41:55

In this case, the output of ASCII() function depends on the condition that whether we are providing NULL as a string or we are providing simply NULL to it. Following example will demonstrate the difference −mysql> SELECT ASCII(null); +-------------+ | ASCII(null) | +-------------+ | NULL        | +-------------+ ... Read More

What can another keyword be used instead of MODIFY to modify the column/s of MySQL table?

Ayyan

Ayyan

Updated on 29-Jan-2020 05:39:50

We can use keyword CHANGE to modify the column/s of an existing table. With CHANGE keyword we can change the name of the column and its definition both. Its syntax would be a bit different from the syntax of ALTER TABLE with MODIFY keyword.SyntaxAlter table table_name CHANGE old_columnname1 new_columnname1 datatype, ... Read More

Is it necessary to select the database each time we begin a MySQL session?How can it be done?

Ayyan

Ayyan

Updated on 28-Jan-2020 10:23:55

The database is created only once but it is necessary to select it each time we begin a MySQLsession. It can be done with the help of USE db_name statement on MySQL command line tool.mysql> Use Query; Database changedIt shows that we are now using query database.We can also select ... Read More

How to generate Prime Numbers in JavaScript?

Ayyan

Ayyan

Updated on 13-Jan-2020 08:19:16

To generate prime numbers in JavaScript, you can try to run the following codeExampleLive Demo           JavaScript Prime                        for (var limit = 1; limit

Advertisements