Daniol Thomas has Published 212 Articles

What are the differences between Stored procedures and functions?

Daniol Thomas

Daniol Thomas

Updated on 01-Nov-2023 13:32:08

33K+ Views

Following are the main differences between functions and procedures:FunctionsProceduresA function has a return type and returns a value.A procedure does not have a return type. But it returns values using the OUT parameters.You cannot use a function with Data Manipulation queries. Only Select queries are allowed in functions.You can use ... Read More

How to select a single field in MongoDB?

Daniol Thomas

Daniol Thomas

Updated on 14-Sep-2023 15:35:43

25K+ Views

You can select a single field in MongoDB using the following syntax:db.yourCollectionName.find({"yourFieldName":yourValue}, {"yourSingleFieldName":1, _id:0});In the above syntax "yourSingleFieldName":1, _id:0 means get all data from one field without _id.To understand the above syntax, let us create a collection with document. The query to create a collection with document is as follows:> ... Read More

C++ Program to Solve the Fractional Knapsack Problem

Daniol Thomas

Daniol Thomas

Updated on 17-Feb-2022 13:07:35

5K+ Views

In Fractional knapsack problem, a set of items are given, each with a weight and a value. We need to break items for maximizing the total value of knapsack and this can be done in greedy approach.AlgorithmBegin Take an array of structure Item Declare value, weight, knapsack weight and density ... Read More

How to draw shapes using SVG in HTML5?

Daniol Thomas

Daniol Thomas

Updated on 16-Dec-2021 08:48:41

1K+ Views

SVG stands for Scalable Vector Graphics and is a language for describing 2D-graphics and graphical applications in XML and the XML is then rendered by an SVG viewer. Most of the web browsers can display SVG just like they can display PNG, GIF, and JPG.You can draw shapes like circle, ... Read More

Set the width of the rule between columns with CSS

Daniol Thomas

Daniol Thomas

Updated on 03-Jul-2020 11:39:26

61 Views

Use the column-rule-width property to set the width of the rule between columns.ExampleYou can try to run the following code to implement the column-rule-width property:Live Demo                    .demo {             column-count: 4;         ... Read More

Specify the order of a flexible item relative to the rest of the flex items inside the same container with CSS

Daniol Thomas

Daniol Thomas

Updated on 03-Jul-2020 10:45:06

98 Views

Use the order property to specify the order of a flexible item relative to the rest of the flex items inside the same container.ExampleYou can try to run the following code to implement the order property −Live Demo                    .mycontainer {   ... Read More

Set the speed of the hover effect with CSS

Daniol Thomas

Daniol Thomas

Updated on 03-Jul-2020 07:43:50

10K+ Views

To set the speed of the hover, use the transition-duration property. To set the hover, use the :hover selector.ExampleYou can try to run the following code to speed the hover effect −Live Demo                    .btn {           ... Read More

How to add rounded corners to a button with CSS?

Daniol Thomas

Daniol Thomas

Updated on 02-Jul-2020 14:01:59

2K+ Views

To add rounded corners to a button, use the border-radius property.ExampleYou can try to run the following code to add rounded corners −Live Demo                    .button {             background-color: yellow;             color: black;             text-align: center;             font-size: 15px;             padding: 20px;             border-radius: 15px;          }                     Result       Click below for result:       Result    

Set how many seconds or milliseconds a CSS transition effect takes to complete

Daniol Thomas

Daniol Thomas

Updated on 02-Jul-2020 08:25:03

196 Views

Use the transition-duration property in CSS to set how many seconds or milliseconds a CSS transition effect takes to complete −ExampleLive Demo                    div {             width: 150px;             height: 150px;             background: blue;             transition-property: height;             transition-duration: 2s;          }          div:hover {             height: 200px;          }                     Heading One       Hover over the below box to change its height.          

pprint module (Data pretty printer)

Daniol Thomas

Daniol Thomas

Updated on 27-Jun-2020 14:59:38

1K+ Views

The pprint module (lib/pprint.py) is a part of Python’s standard library which is distributed along with standard Python distribution. The name pprint stands for pretty printer. The pprint module’s functionality enables aesthetically good looking appearance of Python data structures. Any data structure that can be correctly parsed by Python interpreter ... Read More

1 2 3 4 5 ... 22 Next
Advertisements