
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Karthikeya Boyini has Published 2193 Articles

karthikeya Boyini
674 Views
Let us first create a table −mysql> create table DemoTable1 -> ( -> Id int NOT NULL AUTO_INCREMENT PRIMARY KEY, -> FirstName varchar(100) -> ); Query OK, 0 rows affected (0.57 sec)Insert some records in the table using insert command −mysql> insert into DemoTable1(FirstName) values('John'); Query ... Read More

karthikeya Boyini
1K+ Views
Let us first display all users and host from the table MySQL.user −mysql> select user, host from Mysql.user;This will produce the following output −+------------------+-----------+ | user | host | +------------------+-----------+ | Bob | % ... Read More

karthikeya Boyini
2K+ Views
Here we will see how to print long int value using the putchar() function in C. We can easily print the value of some variables using printf() in C, but here the restriction is, we cannot use any other function except putchar().As we know that the putchar() is used to ... Read More

karthikeya Boyini
235 Views
Yes, you can achieve this with ORDER BY FIELD() from MySQL. Let us first create a table −mysql> create table DemoTable -> ( -> Number int -> ); Query OK, 0 rows affected (0.54 sec)Insert some records in the table using ... Read More

karthikeya Boyini
203 Views
Use SHOW GRANTS for this. Following is the syntax −SHOW GRANTS FOR 'yourUserName'@'yourHostName';Let us display the user name and host name from MySQL.user table.mysql> select user, host from MySQL.user;This will produce the following output −+------------------+-----------+ | user | ... Read More

karthikeya Boyini
704 Views
To split a column after hyphen, use the SUBSTRING_INDEX() method −select substring_index(yourColumnName, '-', -1) AS anyAliasName from yourTableName;Let us first create a table −mysql> create table DemoTable -> ( -> StreetName text -> ); Query OK, 0 rows affected (0.60 sec)Insert ... Read More

karthikeya Boyini
380 Views
For this, use substring_index() function from MySQL. Let us first create a table −mysql> create table DemoTable -> ( -> StudentId varchar(100) -> ); Query OK, 0 rows affected (0.60 sec)Insert some records in the table using insert command −mysql> insert ... Read More

karthikeya Boyini
3K+ Views
Here we will see how to implement memcpy() function in C. The memcpy() function is used to copy a block of data from one location to another. The syntax of the memcpy() is like below −void * memcpy(void * dest, const void * srd, size_t num);To make our own memcpy, ... Read More

karthikeya Boyini
1K+ Views
Let’s say we have a list of phone numbers and from that we want to get the area codes. These area codes are for example, the first 3 digits of the phone number. Use LEFT() function from MySQL for this.Let us first create a table −mysql> create table DemoTable -> ... Read More

karthikeya Boyini
915 Views
You can use text data type to store large strings. Following is the syntax −CREATE TABLE yourTableName ( yourColumnName text, . . N );Let us first create a table −mysql> create table DemoTable -> ( -> MyStringValue text ... Read More