Change the Color of the Bottom Border with CSS

Lakshmi Srinivas
Updated on 03-Feb-2020 06:13:49

192 Views

The border-bottom-color changes the color of the bottom border. You can try to run the following code to implement the border-bottom-color property:Example                    p.demo {             border:4px solid;             border-bottom-color:#FF0000;          }                              Example showing border top color property          

Usage of border-top-width Property in CSS

Ankith Reddy
Updated on 03-Feb-2020 06:13:15

58 Views

The border-top-width property changes the width of top border. You can try to run the following code to implement border-top-width property:Example                            This is demo content.          

Manage Start Position in MySQL LOCATE Function

Chandu yadav
Updated on 03-Feb-2020 06:12:45

154 Views

As we know that by default searching in LOCATE() function starts from beginning. We can manage the start position by giving an argument to specify the position from which we want to start the search in string. Following example will demonstrate it −Examplemysql> Select LOCATE('good','Ram is a good boy. Is Ram a good boy?',11)As Result; +--------+ | Result | +--------+ |     29 | +--------+ 1 row in set (0.00 sec)In the above example, we have given the value 11 as the argument for position. It means that MySQL will start searching from 11th position.

MySQL LOCATE Function Returns NULL Output

Kumar Varma
Updated on 03-Feb-2020 06:11:55

334 Views

It will return NULL as the output when the value of either first argument i.e. substring or the value of second argument i.e. substring is NULL. Example below will demonstrate it −Examplemysql> Select LOCATE(NULL,'Ram is a good boy')As Result; +--------+ | Result | +--------+ | NULL   | +--------+ 1 row in set (0.00 sec) mysql> Select LOCATE('Ram',NULL)As Result; +--------+ | Result | +--------+ | NULL   | +--------+ 1 row in set (0.00 sec)

Convert Value Between Number Systems in MySQL

Moumita
Updated on 03-Feb-2020 06:11:19

146 Views

With the help of MySQL CONV() function, a value from one number system can be converted to the other number system.SyntaxCONV(N, from_base, to_base)Here, ‘N’ is the number which is to be converted, ‘from_base’ is the current base of that number and ‘to_base’ is the base in which that number has to be converted. ‘N’ is interpreted as an integer but it may be specified as integer or a string.Examplemysql> Select CONV('10', 10, 2) AS 'DECIMAL TO BINARY'; +-------------------+ | DECIMAL TO BINARY | +-------------------+ | 1010              | +-------------------+ 1 row in set (0.00 sec)In ... Read More

Using Integer Values as Arguments in MySQL LOCATE Function

Manikanth Mani
Updated on 03-Feb-2020 05:54:05

113 Views

MySQL allows us to use integer values as the arguments of the LOCATE() function. We do not need to use quotes. It can be demonstrated with the help of the following example −Examplemysql> Select LOCATE(5,1698235); +-------------------+ | LOCATE(5,1698235) | +-------------------+ |                 7 | +-------------------+ 1 row in set (0.00 sec) mysql> Select LOCATE(56,1698235); +--------------------+ | LOCATE(56,1698235) | +--------------------+ |                  0 | +--------------------+ 1 row in set (0.00 sec) mysql> Select LOCATE(23,1698235); +--------------------+ | LOCATE(23,1698235) | +--------------------+ |                  5 | +--------------------+ 1 row in set (0.00 sec)

Use Enumeration Value in MySQL Expression

varun
Updated on 03-Feb-2020 05:48:16

163 Views

As we know that enumeration values are associated with index values hence if we will use enumeration values in an expression then all the calculations would be done on index numbers. The following example will clarify it −mysql> Select * from Result; +-----+--------+-------+ | Id  | Name   | Grade | +-----+--------+-------+ | 100 | Gaurav | GOOD  | | 101 | Rahul  | POOR  | | 102 | Rahul  | NULL  | | 103 | Mohan  |       | +-----+--------+-------+ 4 rows in set (0.00 sec) mysql> Select SUM(Grade) from result; +------------+ | SUM(Grade) | +------------+ ... Read More

Most Frequently Used Linux iptables Rules with Examples

Sharon Christine
Updated on 31-Jan-2020 12:34:37

11K+ Views

This article will help you to create IPtables rules that you can directly use for your daily or routine needs, These examples will act as basic templates for you to work on iptables with these rules which suit your specific requirement.Deleting the IPtables or Existing RulesBefore you start building new IPtables set of rules, you should clean up all the default rules, and existing rules. Use the IPtables flush command, below are some examples –#iptables --flush (or) # iptables --FDefault Policies ChainThe default policy is ACCEPT, change the policy to DROP for all the INPUT, FORWARD, OUTPUT.# iptables -P INPUT ... Read More

Calling Conventions for Unix and Linux System Calls on i386 and x86-64

Pradeep Elance
Updated on 31-Jan-2020 12:20:25

865 Views

A system call is the fundamental interface between an application and the Linux kernel. When a Unix/Linux program does a file I/O, network data transfer or invokes some process which directly or indirectly interact with the low level instructions, then system call is involved. Making these calls usually involves using a library called glibc which contains the functions.ExamplesBelow is a list of some frequently used system calls and their purpose.Sr.NoSystem CallPurpose1chmodchange permissions of a file2chdirchange working directory3forkcreate a child process4unlinkdelete a name and possibly the file it refers toA systems programmer writes program that will not directly make the systems ... Read More

Linux wc Command Examples to Count Lines, Words, and Characters

Pradeep Elance
Updated on 31-Jan-2020 12:19:34

490 Views

The wc command also known as word count command is a fundamental command any Linux user should be aware of. It is mostly used with the l switch to do a line count, but it can actually give count of multiple things with various arguments supplied to it. Below is a list of what are those possible arguments. The we will see examples on each of them.Sr.NoCommandUsage1wc -cDisplay number of bytes2wc -mDisplay number of characters3wc -wDisplay number of words4wc -lDisplay number of lines5wc -LDisplay length of longest lineLets consider the below file for our examples.ubuntu@ubuntu:~$ cat inspire.txt Mastering anything needs ... Read More

Advertisements