Tuesday, 19 November 2013

How to generate Arrows using pure css without images

Its very simple to generate arrows using pure css and html alone without using any images. Use the following code as markup.
<div class="arrow-up"></div>
<div class="arrow-down"></div>
<div class="arrow-left"></div>
<div class="arrow-right"></div>

Now use the following css and you are done!!!

.arrow-up {
       width: 0;
       height: 0;
       border-left: 10px solid transparent;
       border-right: 10px solid transparent;      
       border-bottom: 10px solid black;
}

.arrow-down {
       width: 0;
       height: 0;
       border-left: 10px solid transparent;
       border-right: 10px solid transparent;
       border-top: 10px solid #f00;
}

.arrow-right {
       width: 0;
       height: 0;
       border-top: 20px solid transparent;
       border-bottom: 20px solid transparent;
       border-left: 20px solid green;
}

.arrow-left {
       width: 0;
       height: 0;
       border-top: 20px solid transparent;
       border-bottom: 20px solid transparent;
       border-right:20px solid blue;
}


Monday, 18 November 2013

Interview Question: What are Magic Tables in SQLServer


Magic tables are internal tables called ‘inserted’ and ‘deleted’ which are created and managed by SQL server.
Inserted‘ table holds the values that have been recently inserted.
Inserted‘ table also holds the updated values from a update operation on a table.
Deleted‘ table holds the values that have been recently deleted.
Deleted‘ table also holds the previous values from a update operation on a table.
These virtual tables are usually used with triggers to retrieve the inserted, deleted or updated rows.