Home
Search results “Oracle stored procedure if example”
PL/SQL tutorial 9: IF THEN ELSE (IF-ELSE) Statement in PL/SQL by Manish Sharma
 
04:12
3rd tutorial in the series explaining IF-THEN-ELSE statement in Oracle PL/SQL with Example. Enjoy ------------------------------------------------------------------------ ►►►LINKS◄◄◄ Blog : http://bit.ly/if-then-else Previous Tutorial ► IF THEN Statement https://youtu.be/IWvuFD6eD30 ------------------------------------------------------------------------- ►►►Let's Get Free Uber Cab◄◄◄ Use Referral Code UberRebellionRider and get $20 free for your first ride. ------------------------------------------------------------------------- ►►►Help Me In Getting A Job◄◄◄ ►Help Me In Getting A Good Job By Connecting With Me on My LinkedIn and Endorsing My Skills. All My Contact Info is Down Below. You Can Also Refer Me To Your Company Thanks ------------------------------------------------------------------------- ►Make sure you SUBSCRIBE and be the 1st one to see my videos! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ►►►Find me on Social Media◄◄◄ Follow What I am up to as it happens on https://twitter.com/rebellionrider https://www.facebook.com/imthebhardwaj http://instagram.com/rebellionrider https://plus.google.com/+Rebellionrider http://in.linkedin.com/in/mannbhardwaj/ http://rebellionrider.tumblr.com/ http://www.pinterest.com/rebellionrider/ You can also Email me at for E-mail address please check About section Please please LIKE and SHARE my videos it makes me happy. Thanks for liking, commenting, sharing and watching more of our videos This is Manish from RebellionRider.com ♥ I LOVE ALL MY VIEWERS AND SUBSCRIBERS
Views: 59458 Manish Sharma
Stored Procedure - IF ELSE IF ELSE
 
03:13
Stored Procedure - IF ELSE IF ELSE by Professor Saad Yousuf DB2 UDB, Oracle, SQL Server, MySQL
Views: 5120 Professor Saad
IF Statements in Oracle PL SQL with example
 
07:40
Complete Oracle PL/SQL Tutorial for Beginners Playlist here https://www.youtube.com/playlist?list=PLI5t0u6ye3FE_9SZcS0cQZDU2qn0uB1Oi ************************************************** This Video shows how to use IF THEN , ELSIF THEN and ELSE Statements in Oracle with examples for Beginners.
Views: 1701 yrrhelp
Calling a stored procedure with output parameters   Part 7
 
20:13
Text version of the video http://csharp-video-tutorials.blogspot.com/2012/10/calling-stored-procedure-with-output.html Slides http://csharp-video-tutorials.blogspot.com/2013/09/part-7-calling-stored-procedure-with.html All ADO .NET Text Articles http://csharp-video-tutorials.blogspot.com/p/free-adonet-video-tutorial.html All ADO .NET Slides http://csharp-video-tutorials.blogspot.com/p/adonet-slides.html All Dot Net and SQL Server Tutorials in English https://www.youtube.com/user/kudvenkat/playlists?view=1&sort=dd All Dot Net and SQL Server Tutorials in Arabic https://www.youtube.com/c/KudvenkatArabic/playlists In this video, we will learn about calling a stored procedure with output parameters from an asp.net web application.
Views: 182962 kudvenkat
SQL Stored Procedure - If Condition
 
03:38
SQL Stored Procedure - If Condition Calculate Salary Overtime by: Professor Saad Yousuf DB2 UDB, Oracle, SQL Server, MySQL
Views: 3183 Professor Saad
PL/SQL tutorial 11: PL/SQL Simple Loop in Oracle Database by Manish Sharma RebellionRider.com
 
04:21
First tutorial in Iterative statement series explaining concepts of Simple Loop in PL/SQL With a quick brief intro of Loops in Oracle PL/SQL ------------------------------------------------------------------------ ►►►LINKS◄◄◄ Blog : http://bit.ly/simple-loop Previous Tutorial ► IF-THEN : https://youtu.be/IWvuFD6eD30 ► Simple CASE Statement https://youtu.be/DMlDwOmqAzo ► Searched CASE Statement https://youtu.be/jk7k4TDs3F0 ► DECODE Statement https://youtu.be/lKXqXINCNLo ------------------------------------------------------------------------- ►►►Let's Get Free Uber Cab◄◄◄ Use Referral Code UberRebellionRider and get $20 free for your first ride. ------------------------------------------------------------------------- ►Make sure you SUBSCRIBE and be the 1st one to see my videos! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ►►►Find me on Social Media◄◄◄ Follow What I am up to as it happens on https://twitter.com/rebellionrider https://www.facebook.com/imthebhardwaj http://instagram.com/rebellionrider https://plus.google.com/+Rebellionrider http://in.linkedin.com/in/mannbhardwaj/ http://rebellionrider.tumblr.com/ http://www.pinterest.com/rebellionrider/ You can also Email me at for E-mail address please check About section Please please LIKE and SHARE my videos it makes me happy. Thanks for liking, commenting, sharing and watching more of our videos This is Manish from RebellionRider.com ♥ I LOVE ALL MY VIEWERS AND SUBSCRIBERS
Views: 63076 Manish Sharma
HOW CAN WE CALL FUNCTION IN PROCEDURE
 
07:39
WE CAN CALL FUNCTION IN PROCEDURE
Views: 1951 SAINAATTH PITTLA
CHECKING IF EXISTS IN SQL SERVER
 
13:39
This video for the beginner of SQL server programmer who are not fully understand how to checking if data exists do the correct condition and if data not exists do other transaction
Views: 13868 Sourn Sarim
Creating a Stored Procedure
 
03:56
This tutorial teaches you how you can create a DB2 UDB, Oracle, SQL Server, MySQL store procedure.
Views: 1824 Professor Saad
Dynamic SQL in Stored Procedure
 
09:32
In this video we will discuss, using dynamic sql in a stored procedure and it's implications from sql injection perspective. We will discuss performance implications of using dynamic sql in a stored procedure in a later video. Text version of the video http://csharp-video-tutorials.blogspot.com/2017/04/dynamic-sql-in-stored-procedure.html Slides http://csharp-video-tutorials.blogspot.com/2017/04/dynamic-sql-in-stored-procedure_11.html All SQL Server Text Articles http://csharp-video-tutorials.blogspot.com/p/free-sql-server-video-tutorials-for.html All SQL Server Slides http://csharp-video-tutorials.blogspot.com/p/sql-server.html All SQL Server Tutorial Videos https://www.youtube.com/playlist?list=PL08903FB7ACA1C2FB All Dot Net and SQL Server Tutorials in English https://www.youtube.com/user/kudvenkat/playlists?view=1&sort=dd All Dot Net and SQL Server Tutorials in Arabic https://www.youtube.com/c/KudvenkatArabic/playlists Consider the following stored procedure "spSearchEmployees". We implemented this procedure in Part 139 of SQL Server tutorial. This stored procedure does not have any dynamic sql in it. It is all static sql and is immune to sql injection. Create Procedure spSearchEmployees @FirstName nvarchar(100) = NULL, @LastName nvarchar(100) = NULL, @Gender nvarchar(50) = NULL, @Salary int = NULL As Begin Select * from Employees where (FirstName = @FirstName OR @FirstName IS NULL) AND (LastName = @LastName OR @LastName IS NULL) AND (Gender = @Gender OR @Gender IS NULL) AND (Salary = @Salary OR @Salary IS NULL) End Go Whether you are creating your dynamic sql queries in a client application like ASP.NET web application or in a stored procedure, you should never ever concatenate user input values. Instead you should be using parameters. Notice in the following example, we are creating dynamic sql queries by concatenating parameter values, instead of using parameterized queries. This stored procedure is prone to SQL injection. Let's prove this by creating a "Search Page" that calls this procedure. Create Procedure spSearchEmployeesBadDynamicSQL @FirstName nvarchar(100) = NULL, @LastName nvarchar(100) = NULL, @Gender nvarchar(50) = NULL, @Salary int = NULL As Begin Declare @sql nvarchar(max) Set @sql = 'Select * from Employees where 1 = 1' if(@FirstName is not null) Set @sql = @sql + ' and FirstName=''' + @FirstName + '''' if(@LastName is not null) Set @sql = @sql + ' and LastName=''' + @LastName + '''' if(@Gender is not null) Set @sql = @sql + ' and Gender=''' + @Gender + '''' if(@Salary is not null) Set @sql = @sql + ' and Salary=''' + @Salary + '''' Execute sp_executesql @sql End Go Add a Web Page to the project that we have been working with in our previous video. Name it "DynamicSQLInStoredProcedure.aspx". Copy and paste the HTML and code available on my blog at the following link http://csharp-video-tutorials.blogspot.com/2017/04/dynamic-sql-in-stored-procedure.html At this point, run the application and type the following text in the "Firsname" text and click "Search" button. Notice "SalesDB" database is dropped. Our application is prone to SQL injection as we have implemented dynamic sql in our stored procedure by concatenating strings instead of using parameters. ' Drop database SalesDB -- In the following stored procedure we have implemented dynamic sql by using parameters, so this is not prone to sql injecttion. This is an example for good dynamic sql implementation. Create Procedure spSearchEmployeesGoodDynamicSQL @FirstName nvarchar(100) = NULL, @LastName nvarchar(100) = NULL, @Gender nvarchar(50) = NULL, @Salary int = NULL As Begin Declare @sql nvarchar(max) Declare @sqlParams nvarchar(max) Set @sql = 'Select * from Employees where 1 = 1' if(@FirstName is not null) Set @sql = @sql + ' and [email protected]' if(@LastName is not null) Set @sql = @sql + ' and [email protected]' if(@Gender is not null) Set @sql = @sql + ' and [email protected]' if(@Salary is not null) Set @sql = @sql + ' and [email protected]' Execute sp_executesql @sql, N'@FN nvarchar(50), @LN nvarchar(50), @Gen nvarchar(50), @sal int', @[email protected], @[email protected], @[email protected], @[email protected] End Go On the code-behind page, use stored procedure spSearchEmployeesGoodDynamicSQL instead of spSearchEmployeesBadDynamicSQL. We do not have to change any other code. At this point run the application one more time and type the following text in the "Firstname" textbox and click the "Search" button. ' Drop database SalesDB -- Notice "SalesDB" database is not dropped, So in this case our application is not succeptible to SQL injection attack. Summary : Whether you are creating dynamic sql in a client application (like a web application) or in a stored procedure always use parameters instead of concatnating strings. Using parameters to create dynamic sql statements prevents sql injection.
Views: 29355 kudvenkat
DYNAMIC SQL WITH EXECUTE IMMEDIATE IN ORACLE PL/SQL WITH EXAMPLE
 
21:53
The audio and video now synced. Ever tried creating a table inside a PL SQL block, or a function or a procedure? If yes, then you would know that it would raise an error, as DDL statements are not allowed inside a PL/SQL Block. So the solution to such a case, where you want to generate tables, or sequences or want to execute any DDL statement on the fly, then use synamic sql. Dynamic SQL statment will allow you to create state statements on the fly and then you can execute them using the execute immediate statement. This video tutorial demonstrates on this topic of using synamic sql with execute immediate in a PL/SQL block.
Views: 4661 Kishan Mashru
Calling a Stored Procedure from another Stored Procedure
 
11:55
Calling a Stored Procedure from another Stored Procedure - DB2 UDB, Oracle, SQL Server, MySQL
Views: 5095 Professor Saad
PL-SQL Procedure, How to Create Procedure, Calling Procedure in Oracle 11g Database
 
10:56
PL-SQL Procedure, How to Create Procedure, Calling Procedure in Oracle 11g Database PL-SQL tutorial for Beginners in Hindi and English
CASE STATEMENT(IF THEN ELSE) IN ORACLE SQL WITH EXAMPLE
 
06:28
The case statement gives the if-then-else kind of conditional ability to the otherwise static sql select statement, This video demonstrates how to write an case statement in oracle sql, and explains different aspects of the case statement. The video explains the execution flow of the case statement and advises on the best way to write one.
Views: 1802 Kishan Mashru
DIFFERENCE BETWEEN PROCEDURE AND FUNCTION IN ORACLE PL/SQL WITH EXAMPLE
 
06:33
The audio and video now synced. This video is a free tutorial on the difference between procedure and a function. The tutorial demonstrates the difference between oracle PL/SQL stored procedure and a function, also it shows the different type of return statement in both of the database objects and various ways to execute a procedure and a function. By learning the difference the users can make an effective judgment on when to use procedure and when to use a function. If you want more such videos of exciting and amazing 'difference between' concepts, check out the links below: union and union all: https://youtu.be/n9FqQOd8liY char and varchar2: https://youtu.be/039qzwjWf4k replace and translate: https://youtu.be/HKYF77BGzOE in and exists: https://youtu.be/REX4IjRYlFw rank and dense_rank: https://youtu.be/WGSX998hZ9M delete and truncate: https://youtu.be/u76wMm2byXo %type and %rowtype: https://youtu.be/MlLUFeZ_3eM
Views: 4306 Kishan Mashru
Oracle Row Level Triggers when condition clause Session 7
 
04:17
Oracle SQL PLSQL and Unix Shell Scripting
Views: 419 Sridhar Raghavan
Stored Procedures in PL/SQL | Oracle PL/SQL Tutorial Videos | Mr.Vijay Kumar
 
18:54
Stored Procedures:- A Stored Procedure is also a Named PL/SQL block the accepts some input in the form of parameters and performs some task and many or many not returns a value Procedures are created to perform one or more dml operations over database.
Views: 43906 Naresh i Technologies
Cursor in a Stored Procedure Part 1
 
15:01
More information at: http://prof-oracle.blogspot.com/2018/01/cursor-in-stored-procedure.html
Views: 99 Gove Allen
Stored procedure output parameters or return values   Part 20
 
16:45
In this video we will 1. Understand what are stored procedure return values 2. Difference between stored procedure return values and output parameters 3. When to use output parameters over return values Text version of the video http://csharp-video-tutorials.blogspot.com/2012/08/stored-procedure-output-parameters-or.html Slides http://csharp-video-tutorials.blogspot.com/2013/08/part-20-stored-procedure-output.html All SQL Server Text Articles http://csharp-video-tutorials.blogspot.com/p/free-sql-server-video-tutorials-for.html All SQL Server Slides http://csharp-video-tutorials.blogspot.com/p/sql-server.html All Dot Net and SQL Server Tutorials in English https://www.youtube.com/user/kudvenkat/playlists?view=1&sort=dd All Dot Net and SQL Server Tutorials in Arabic https://www.youtube.com/c/KudvenkatArabic/playlists
Views: 270247 kudvenkat
Merge Statement in Oracle SQL with Example (UPDATE/DELETE or INSERT)
 
15:04
This video demonstrates how to write a Merge Statement in oracle sql, how it is useful in doing a conditional update or delete or both of them when the condition between the target table and source table is evaluated to true, and how we can insert the record into the target table when condition is evaluated to false. The video also shows the use of UPDATE, DELETE and INSERT with Merge, and also the various possible ways to use a Merge statement!!!
Views: 7977 Kishan Mashru
Stored procedures in sql server   Part 18
 
20:11
In this video we will learn 1. What is a stored procedure 2. Stored Procedure example 3. Creating a stored procedure with parameters 4. Altering SP 5. Viewing the text of the SP 6. Dropping the SP 7. Encrypting stored procedure Text version of the video http://csharp-video-tutorials.blogspot.com/2012/08/stored-procedures-part-18.html Slides http://csharp-video-tutorials.blogspot.com/2013/08/part-18-stored-procedures.html All SQL Server Text Articles http://csharp-video-tutorials.blogspot.com/p/free-sql-server-video-tutorials-for.html All SQL Server Slides http://csharp-video-tutorials.blogspot.com/p/sql-server.html All Dot Net and SQL Server Tutorials in English https://www.youtube.com/user/kudvenkat/playlists?view=1&sort=dd All Dot Net and SQL Server Tutorials in Arabic https://www.youtube.com/c/KudvenkatArabic/playlists
Views: 709665 kudvenkat
SQL Stored Procedures - What They Are, Best Practices, Security, and More...
 
44:34
Newsletter signup (with exclusive discounts): https://iamtimcorey.com/general-sign-up (your email will be kept safe and you will not be spammed). Facebook Page: https://www.facebook.com/IAmTimCorey/ Want to see a full C# application built from scratch? Check out this course: https://iamtimcorey.com/courses/csharp-from-start-to-finish/ Microsoft SQL can be confusing. There are a TON of features, options, and settings to consider when attempting to use it. One of my favorite features is stored procedures. These pre-compiled queries allow you to safely and securely access and modify data. In this video, you will learn the basics of how to build a stored procedure, as well as what the benefits and drawbacks of stored procedures are. You will also learn some best practices, including how to secure your entire database in just a few simple commands.
Views: 35922 IAmTimCorey
Stored Procedure - in out parameters
 
04:57
Stored Procedure - in out parameters. Plus performing calculations in a called procedure and sending it back to caller procedure. DB2 UDB, Oracle, SQL Server, MySQL
Views: 2951 Professor Saad
HOW TO RETURN MULTIPLE VALUES FROM A PROCEDURE IN ORACLE PL/SQL? (USING OUT PARAMETERS)
 
04:46
This video tutorial explains how an oracle procedure can return multiple values with a proper example. The video tutorial shows how this problem can be tacked using simple and easy to understand out parameters!!!
Views: 11942 Kishan Mashru
PL/SQL tutorial 40 : Introduction to PL/SQL Stored Procedure in Oracle Database By Manish Sharma
 
04:59
Learn what are "stored procedures" in Oracle Database By Manish Sharma from RebellionRider.com ------------------------------------------------------------------------ ►►►LINKS◄◄◄ Blog : http://bit.ly/stored-procedure Previous Tutorial ► How To Create PL/SQL function: https://youtu.be/93uqcFVtfWA ------------------------------------------------------------------------- ►►►Let's Get Free Uber Cab◄◄◄ Use Referral Code UberRebellionRider and get $20 free for your first ride. ------------------------------------------------------------------------- ►Make sure you SUBSCRIBE and be the 1st one to see my videos! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ►►►Find me on Social Media◄◄◄ Follow What I am up to as it happens on https://twitter.com/rebellionrider https://www.facebook.com/imthebhardwaj http://instagram.com/rebellionrider https://plus.google.com/+Rebellionrider http://in.linkedin.com/in/mannbhardwaj/ http://rebellionrider.tumblr.com/ http://www.pinterest.com/rebellionrider/ ___Facebook Official Page___ https://www.facebook.com/RebellionRider.official/ You can also Email me at for E-mail address please check About section Please please LIKE and SHARE my videos it makes me happy. Thanks for liking, commenting, sharing and watching more of our videos This is Manish from RebellionRider.com ♥ I LOVE ALL MY VIEWERS AND SUBSCRIBERS
Views: 51009 Manish Sharma
PL/SQL: Stored Procedures Part-1
 
06:19
In this tutorial, you'll learn what are stored procedures PL/SQL (Procedural Language/Structured Query Language) is Oracle Corporation's procedural extension for SQL and the Oracle relational database. PL/SQL is available in Oracle Database (since version 7), TimesTen in-memory database (since version 11.2.1), and IBM DB2 (since version 9.7).[1] Oracle Corporation usually extends PL/SQL functionality with each successive release of the Oracle Database. PL/SQL includes procedural language elements such as conditions and loops. It allows declaration of constants and variables, procedures and functions, types and variables of those types, and triggers. It can handle exceptions (runtime errors). Arrays are supported involving the use of PL/SQL collections. Implementations from version 8 of Oracle Database onwards have included features associated with object-orientation. One can create PL/SQL units such as procedures, functions, packages, types, and triggers, which are stored in the database for reuse by applications that use any of the Oracle Database programmatic interfaces. PL/SQL works analogously to the embedded procedural languages associated with other relational databases. For example, Sybase ASE and Microsoft SQL Server have Transact-SQL, PostgreSQL has PL/pgSQL (which emulates PL/SQL to an extent), and IBM DB2 includes SQL Procedural Language,[2] which conforms to the ISO SQL’s SQL/PSM standard. The designers of PL/SQL modeled its syntax on that of Ada. Both Ada and PL/SQL have Pascal as a common ancestor, and so PL/SQL also resembles Pascal in several aspects. However, the structure of a PL/SQL package does not resemble the basic Object Pascal program structure as implemented by a Borland Delphi or Free Pascal unit. Programmers can define public and private global data-types, constants and static variables in a PL/SQL package.[3] PL/SQL also allows for the definition of classes and instantiating these as objects in PL/SQL code. This resembles usage in object-oriented programming languages like Object Pascal, C++ and Java. PL/SQL refers to a class as an "Abstract Data Type" (ADT) or "User Defined Type" (UDT), and defines it as an Oracle SQL data-type as opposed to a PL/SQL user-defined type, allowing its use in both the Oracle SQL Engine and the Oracle PL/SQL engine. The constructor and methods of an Abstract Data Type are written in PL/SQL. The resulting Abstract Data Type can operate as an object class in PL/SQL. Such objects can also persist as column values in Oracle database tables. PL/SQL is fundamentally distinct from Transact-SQL, despite superficial similarities. Porting code from one to the other usually involves non-trivial work, not only due to the differences in the feature sets of the two languages,[4] but also due to the very significant differences in the way Oracle and SQL Server deal with concurrency and locking. There are software tools available that claim to facilitate porting including Oracle Translation Scratch Editor,[5] CEITON MSSQL/Oracle Compiler [6] and SwisSQL.[7] The StepSqlite product is a PL/SQL compiler for the popular small database SQLite. PL/SQL Program Unit A PL/SQL program unit is one of the following: PL/SQL anonymous block, procedure, function, package specification, package body, trigger, type specification, type body, library. Program units are the PL/SQL source code that is compiled, developed and ultimately executed on the database. The basic unit of a PL/SQL source program is the block, which groups together related declarations and statements. A PL/SQL block is defined by the keywords DECLARE, BEGIN, EXCEPTION, and END. These keywords divide the block into a declarative part, an executable part, and an exception-handling part. The declaration section is optional and may be used to define and initialize constants and variables. If a variable is not initialized then it defaults to NULL value. The optional exception-handling part is used to handle run time errors. Only the executable part is required. A block can have a label. Package Packages are groups of conceptually linked functions, procedures, variables, PL/SQL table and record TYPE statements, constants, cursors etc. The use of packages promotes re-use of code. Packages are composed of the package specification and an optional package body. The specification is the interface to the application; it declares the types, variables, constants, exceptions, cursors, and subprograms available. The body fully defines cursors and subprograms, and so implements the specification. Two advantages of packages are: Modular approach, encapsulation/hiding of business logic, security, performance improvement, re-usability. They support object-oriented programming features like function overloading and encapsulation. Using package variables one can declare session level (scoped) variables, since variables declared in the package specification have a session scope.
Views: 15793 radhikaravikumar
PL/SQL tutorial 10: PL/SQL IF THEN ELSIF Statement in Oracle Database by Manish Sharma
 
04:55
Watch and learn IF THEN ELSIF (ELSIF ladder)statement in PL/SQL by Manish Sharma RebellionRider.com ------------------------------------------------------------------------ ►►►LINKS◄◄◄ Blog : http://bit.ly/if-then-elsif Previous Tutorial ► IF-ELSE https://youtu.be/IWsY_HzufKw ►Simple Case: https://youtu.be/DMlDwOmqAzo ►Searched Case: https://youtu.be/jk7k4TDs3F0 ►DECODE: https://youtu.be/lKXqXINCNLo ------------------------------------------------------------------------- ►►►Let's Get Free Uber Cab◄◄◄ Use Referral Code UberRebellionRider and get $20 free for your first ride. ------------------------------------------------------------------------- ►Make sure you SUBSCRIBE and be the 1st one to see my videos! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ►►►Find me on Social Media◄◄◄ Follow What I am up to as it happens on https://twitter.com/rebellionrider https://www.facebook.com/imthebhardwaj http://instagram.com/rebellionrider https://plus.google.com/+Rebellionrider http://in.linkedin.com/in/mannbhardwaj/ http://rebellionrider.tumblr.com/ http://www.pinterest.com/rebellionrider/ You can also Email me at for E-mail address please check About section Please please LIKE and SHARE my videos it makes me happy. Thanks for liking, commenting, sharing and watching more of our videos This is Manish from RebellionRider.com ♥ I LOVE ALL MY VIEWERS AND SUBSCRIBERS
Views: 48590 Manish Sharma
Introduction to Oracle: PL-SQL - IF ... ELSIF ... ELSE Statement
 
04:28
Introduction to Oracle: PL-SQL - IF ... ELSIF ... ELSE Statement
Views: 353 David Hays
Oracle PL/SQL - Multiple ELSIF Clauses
 
06:57
http://plsqlzerotopro.com This tutorial explains multiple ELSIF clauses in an IF statement.
Views: 5341 HandsonERP
PL-SQL tutorial 25 - How to use Multiple IF-ELSIF-ELSE
 
05:46
Hi guys today i am going to explain about Selection Control Structure IF-ELSIF-ELSE in PL/SQL how to write a code in condition. Oracle database Unbeatable,Unbreakable Platform..
Views: 266 Oracle World
Tutorial 44 - IN , OUT & INOUT parameters
 
09:01
Learn about IN , OUT & INOUT parameters in PostgreSQL.
Views: 8157 Programming Guru
PL/SQL tutorial 3: SELECT INTO statement in PL/SQL by Manish Sharma RebellionRider
 
05:22
How to initialize the variable by fetching values from the table of the database or by using SELECT INTO statement in PL/SQL by Manish Sharma RebellionRider ------------------------------------------------------------------------ ►►►LINKS◄◄◄ Blog : http://bit.ly/select-into-statement-pl-sql Previous Tutorial ► Variables: https://youtu.be/2MNmodawvnE ------------------------------------------------------------------------- ►►►Let's Get Free Uber Cab◄◄◄ Use Referral Code UberRebellionRider and get $20 free for your first ride. -------------------------------------------------------------------------- ►Make sure you SUBSCRIBE and be the 1st one to see my videos! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ►►►Find me on Social Media◄◄◄ Follow What I am up to as it happens on https://twitter.com/rebellionrider https://www.facebook.com/imthebhardwaj http://instagram.com/rebellionrider https://plus.google.com/+Rebellionrider http://in.linkedin.com/in/mannbhardwaj/ http://rebellionrider.tumblr.com/ http://www.pinterest.com/rebellionrider/ You can also Email me at for E-mail address please check About section Please please LIKE and SHARE my videos it makes me happy. Thanks for liking, commenting, sharing and watching more of our videos This is Manish from RebellionRider.com ♥ I LOVE ALL MY VIEWERS AND SUBSCRIBERS
Views: 116319 Manish Sharma
Oracle Part 14 Stored Procedure Create and Execute
 
29:43
Create, replace, drop stored procedures, comment, variables, assignment, for loop, serveroutput, in parameter, execute SP
Views: 33640 Free OpenMentor
Oracle NVL Function Explained with Examples
 
09:25
https://www.databasestar.com/oracle-nvl-nvl2-logical-functions/ The Oracle NVL function allows you to check a value and return a different value if that value is NULL. It’s great for using another value if the first one is NULL or an optional value, for example people’s phone numbers. It’s also good alongside aggregate functions and grouping so you can see what the difference is between a subtotal row and an actual NULL value. The syntax of the Oracle NVL function is: NVL( check_value, replace_value ) The parameters are: - check_value (mandatory): This is the value that is displayed to the user. It is also the value that is checked for NULL. - replace_value (mandatory): This is the value that appears if the check_value is NULL. The function can use many different data types as parameters: string, date, or numeric. However, both parameters need to be the same type. For more information about the Oracle NVL function, including all of the SQL shown in this video and the examples, read the related article here: https://www.databasestar.com/oracle-nvl-nvl2-logical-functions/
Views: 197 Database Star
SQL Server Programming Part 1 - Stored Procedure Basics
 
10:31
If you'd like to help fund Wise Owl's conversion of tea and biscuits into quality training videos you can click this link https://www.wiseowl.co.uk/donate?t=1 to make a donation. Thanks for watching! By Andrew Gould https://www.wiseowl.co.uk - If you ever find yourself writing the same SQL query over and over again, a Stored Procedure could be just the time-saving tool you're looking for. This video introduces you to the concept of stored procedures and will show you how to create, execute and modify these useful elements of SQL Server. You can see a written version of this tutorial at: https://www.wiseowl.co.uk/blog/s263/stored-procedures.htm You can download the script to create the Movies database used in this video at the following link: https://www.wiseowl.co.uk/files/execise-question-files/qf-898.zip You can see the range of resources and courses we offer in SQL Server here: https://www.wiseowl.co.uk/sql/ Visit www.wiseowl.co.uk for more online training resources in Microsoft Excel, Microsoft Access, Microsoft PowerPoint, Microsoft Word, Microsoft Project, Microsoft Publisher, Microsoft Visio, SQL Server, Reporting Services, Analysis Services, Visual Studio, ASP.NET, VB.NET, C# and more!
Views: 288187 WiseOwlTutorials
Learn Store Procedure in SQL in Hindi tutorial for beginners
 
08:45
Stored Procedure: Stored Procedure in SQL Server can be defined as the set of logical group of SQL statements which are grouped to perform a specific task. There are many benefits of using a stored procedure. The main benefit of using a stored procedure is that it increases the performance of the database.The other benefits of using the Stored Procedure are given below. Benefits of Using the Stored Procedure One of the main benefits of using the Stored procedure is that it reduces the amount of information sent to the database server. It can become a more important benefit when the bandwidth of the network is less. Since if we send the SQL query (statement) which is executing in a loop to the server through network and the network gets disconnected, then the execution of the SQL statement doesn't return the expected results, if the SQL query is not used between Transaction statement and rollback statement is not used. Compilation step is required only once when the stored procedure is created. Then after it does not require recompilation before executing unless it is modified and reutilizes the same execution plan whereas the SQL statements need to be compiled every time whenever it is sent for execution even if we send the same SQL statement every time. It helps in re usability of the SQL code because it can be used by multiple users and by multiple clients since we need to just call the stored procedure instead of writing the same SQL statement every time. It helps in reducing the development time. Stored procedure is helpful in enhancing the security since we can grant permission to the user for executing the Stored procedure instead of giving permission on the tables used in the Stored procedure. Sometimes, it is useful to use the database for storing the business logic in the form of stored procedure since it makes it secure and if any change is needed in the business logic, then we may only need to make changes in the stored procedure and not in the files contained on the web server.
Views: 27697 Learn Everything
PL/SQL tutorial 6: Bind Variable in PL/SQL By Manish Sharma RebellionRider.com
 
07:56
Watch and learn what are bind variables in PL/SQL how to declare or create them using Variable command, Initialize them using Execute (exec)command and different ways of displaying current values of a bind variable for example using AutoPrint parameter. ------------------------------------------------------------------------ ►►►LINKS◄◄◄ Blog : http://bit.ly/bind-variable Previous Tutorial ► Constants in PL/SQL https://youtu.be/r1ypg7WH4GY ►User Variables :https://youtu.be/2MNmodawvnE ------------------------------------------------------------------------- ►►►Let's Get Free Uber Cab◄◄◄ Use Referral Code UberRebellionRider and get $20 free for your first ride. ------------------------------------------------------------------------- ►►►Help Me In Getting A Job◄◄◄ ►Help Me In Getting A Good Job By Connecting With Me on My LinkedIn and Endorsing My Skills. All My Contact Info is Down Below. You Can Also Refer Me To Your Company Thanks ------------------------------------------------------------------------- ►Make sure you SUBSCRIBE and be the 1st one to see my videos! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ►►►Find me on Social Media◄◄◄ Follow What I am up to as it happens on https://twitter.com/rebellionrider https://www.facebook.com/imthebhardwaj http://instagram.com/rebellionrider https://plus.google.com/+Rebellionrider http://in.linkedin.com/in/mannbhardwaj/ http://rebellionrider.tumblr.com/ http://www.pinterest.com/rebellionrider/ You can also Email me at for E-mail address please check About section Please please LIKE and SHARE my videos it makes me happy. Thanks for liking, commenting, sharing and watching more of our videos This is Manish from RebellionRider.com ♥ I LOVE ALL MY VIEWERS AND SUBSCRIBERS
Views: 87462 Manish Sharma
PL/SQL tutorial 12: PL/SQL WHILE Loop in Oracle Database
 
06:33
Iterative statements/loop series learn the concepts of While Loop in PL/SQL or In Oracle Database with Examples. also learn how to handle boolean expression in while loop ------------------------------------------------------------------------ ►►►LINKS◄◄◄ Blog : http://bit.ly/while-loop-in-pl-sql Previous Tutorial ► Simple Loop: https://youtu.be/AFx6QYcY1CU ------------------------------------------------------------------------- ►►►Let's Get Free Uber Cab◄◄◄ Use Referral Code UberRebellionRider and get $20 free for your first ride. ------------------------------------------------------------------------- ►Make sure you SUBSCRIBE and be the 1st one to see my videos! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ►►►Find me on Social Media◄◄◄ Follow What I am up to as it happens on https://twitter.com/rebellionrider https://www.facebook.com/imthebhardwaj http://instagram.com/rebellionrider https://plus.google.com/+Rebellionrider http://in.linkedin.com/in/mannbhardwaj/ http://rebellionrider.tumblr.com/ http://www.pinterest.com/rebellionrider/ You can also Email me at for E-mail address please check About section Please please LIKE and SHARE my videos it makes me happy. Thanks for liking, commenting, sharing and watching more of our videos This is Manish from RebellionRider.com ♥ I LOVE ALL MY VIEWERS AND SUBSCRIBERS
Views: 54508 Manish Sharma
PL/SQL tutorial | Cursor in Oracle Database 11g Complete guide
 
13:50
Learn in depth about cursor in oracle database 11g, and why to use cursor.Writing Implicit cursor and explicit cursor following using 'for loop' inside cursor to fetch multiple records from oracle database. Cursor in Oracle Cursor in PL/SQL Oracle Cursor PL/SQL Cursor What is cursor in PL/SQL How to use cursor in PL/SQL Implicit cursor in PL/SQL Explicit cursor in PL/SQL A cursor is a pointer to this context area. PL/SQL controls the context area through a cursor. A cursor holds the rows (one or more) returned by a SQL statement. The set of rows the cursor holds is referred to as the active set. Implicit Cursors Implicit cursors are automatically created by Oracle whenever an SQL statement is executed, when there is no explicit cursor for the statement. Programmers cannot control the implicit cursors and the information in it. %FOUND Returns TRUE if an INSERT, UPDATE, or DELETE statement affected one or more rows or a SELECT INTO statement returned one or more rows. Otherwise, it returns FALSE. %NOTFOUND The logical opposite of %FOUND. It returns TRUE if an INSERT, UPDATE, or DELETE statement affected no rows, or a SELECT INTO statement returned no rows. Otherwise, it returns FALSE. %ISOPEN Always returns FALSE for implicit cursors, because Oracle closes the SQL cursor automatically after executing its associated SQL statement. %ROWCOUNT Returns the number of rows affected by an INSERT, UPDATE, or DELETE statement, or returned by a SELECT INTO statement. Explicit Cursors Explicit cursors are programmer-defined cursors for gaining more control over the context area. An explicit cursor should be defined in the declaration section of the PL/SQL Block. It is created on a SELECT Statement which returns more than one row Linkedin: https://www.linkedin.com/in/aditya-kumar-roy-b3673368/ Facebook: https://www.facebook.com/SpecializeAutomation/
Views: 2090 Specialize Automation
SQL Server Programming Part 6 - WHILE Loops
 
14:48
If you'd like to help fund Wise Owl's conversion of tea and biscuits into quality training videos you can click this link https://www.wiseowl.co.uk/donate?t=1 to make a donation. Thanks for watching! By Andrew Gould https://www.wiseowl.co.uk - In SQL Server there is only one type of loop: a WHILE loop. This video teaches you how to use them, from the basic syntax of the WHILE statement, through how to use a SELECT statement within a loop. We'll also cover how to use the BREAK command to exit from a loop, what to do when you inevitably find yourself in an endless loop and, finally, a quick introduction to using loops with cursors. You can download the script to create the Movies database used in this video at the following link: https://www.wiseowl.co.uk/files/execise-question-files/qf-898.zip You can see the range of resources and courses we offer in SQL Server here: https://www.wiseowl.co.uk/sql/ Visit www.wiseowl.co.uk for more online training resources in Microsoft Excel, Microsoft Access, Microsoft PowerPoint, Microsoft Word, Microsoft Project, Microsoft Publisher, Microsoft Visio, SQL Server, Reporting Services, Analysis Services, Visual Studio, ASP.NET, VB.NET, C# and more!
Views: 70458 WiseOwlTutorials
PL/SQL Tutorial 5: What is PL/SQL Stored Procedure? give me an example?
 
03:20
Learn about PL/SQL Blocks by watching videos What is Stored Procedure in PL/SQL: A procedure is a group of PL/SQL statements that you can call by name. In my next video i will be explaining further concepts of PL/SQL. Make sure you SUBSCRIBE and be the 1st one to see my videos! For HCL interview question : https://youtu.be/Pf0lRerwF5U For Global Analytics interview questions : https://youtu.be/joRTF8ZhVwg For CTS interview questions: https://www.youtube.com/watch?v=ISpHa... For accenture interview questions: https://www.youtube.com/watch?v=lojdZA7pT4o For 3i infotech interview questions: https://www.youtube.com/watch?v=aI7_45hSb5o For Infosys interview questions: https://www.youtube.com/watch?v=l4hfRvcnyxk For top 30 PLSQL interview questions: https://www.youtube.com/watch?v=pNiVsMHTk68 Please subscribe to my channel here for more videos on recent interview questions of MNC companies. https://www.youtube.com/channel/UCofh... Please please LIKE and SHARE my videos it makes me happy. Thanks for liking, commenting, sharing and watching more of our videos This is Oracle PLSQL group from http://techroundinterviewque.blogspot.in/ ------------------------------------------------------------------------ Blog : http://techroundinterviewque.blogspot.in/ FB: https://www.facebook.com/jobupdates.necg/ Google+: https://plus.google.com/u/0/105097188725173992509 twitter: https://twitter.com/Oracle_pl_sql -------------------------------------------------------------------------- Thanks to my subscribers !!
Views: 1629 Oracle PL/SQL
PLS-2: My First PL/SQL Program
 
11:34
For Full Course Experience Please Go To http://mentorsnet.org/course_preview?course_id=5 Full Course Experience Includes 1. Access to course videos and exercises 2. View & manage your progress/pace 3. In-class projects and code reviews 4. Personal guidance from your Mentors Goal is to write your first PL/SQL program. The basic program unit in PL/SQL is the block. A PL/SQL block is defined by the keywords DECLARE, BEGIN, EXCEPTION, and END. These keywords partition the block into a declarative part, an executable part, and an exception-handling part. Example of a Block DECLARE bonus NUMBER(8,2); emp_id NUMBER(6) := 100; BEGIN SELECT salary * 0.10 INTO bonus FROM employees WHERE employee_id = emp_id; Exception When NO_DATA_FOUND THEN null ; END; This is a typical PL/SQL block where 10% of salary is selected and stored on a temp variables bonus. If for some reason there is no employee with empid = 100 then the control will come to exception area and the code in the exception area will be executed. These blocks can be entirely separate or nested one within another. The basic units (procedures and functions, also known as subprograms, and anonymous blocks) that make up a PL/SQL program are logical blocks, which can contain any number of nested sub blocks. Therefore, one block can represent a small part of another block, which in turn can be part of the whole unit of code. Anonymous Blocks Anonymous blocks are unnamed blocks. They are declared at the point in an application where they are to be executed and are passed to the PL/SQL engine for execution at run time. You can embed an anonymous block within a pre-compiler program and within iSQL*Plus or Server Manager. Triggers in Oracle Developer components consist of such blocks. Subprograms Subprograms are named PL/SQL blocks that can accept parameters and can be invoked. You can declare them either as procedures or as functions. Generally use a procedure to perform an action and a function to compute a value. You can store subprograms at the server or application level. Using Oracle Developer components (Forms, Reports, and Graphics), you can declare procedures and functions as part of the application (a form or report) and call them from other procedures, functions, and triggers (see next page) within the same application whenever necessary. Note: A function is similar to a procedure, except that a function must return a value.
Views: 64453 Oresoft LWC
jQuery datatables stored procedure for paging sorting and searching
 
14:36
Link for all dot net and sql server video tutorial playlists https://www.youtube.com/user/kudvenkat/playlists?sort=dd&view=1 Link for slides, code samples and text version of the video http://csharp-video-tutorials.blogspot.com/2015/08/jquery-datatables-stored-procedure-for.html In this video we will discuss implementing a stored procedure that can perform paging sorting and searching. In our upcoming videos we will discuss writing a generic handler that calls this stored procedure. The generic handler will convert the data to JSON format. The JSON formatted data can then be consumed by the jQuery datatables plugin. All the processing, that is, paging, sorting and searching is done on the server side. If the dataset is small you can retrieve all the data at once and all the processing (i.e paging, searching, sorting) can be done on the client-side. We discussed this in Part 106 for jQuery tutorial. However, if the dataset is large (i.e if you have millions of records), loading all data at once is not the best thing to do from a performance standpoint. With large dataset, we only want to load the correct set of rows (sorted, paged and filtered data ) that want to display on the page. So all the processing ((i.e paging, searching and sorting) should be done by the server. So in this and our upcoming videos we will discuss performing server side processing. SQL Script to create the table and populate it with test data Create table tblEmployees ( ID int primary key identity, FirstName nvarchar(50), LastName nvarchar(50), Gender nvarchar(20), JobTitle nvarchar(20) ) Go Insert into tblEmployees values('Mark', 'Hastings','Male','Developer') Insert into tblEmployees values('Maria', 'Nicholas','Female','Developer') Insert into tblEmployees values('Robert', 'Stephenson','Male','Sr. Developer') Insert into tblEmployees values('Mary', 'Quant','Female','Sr. Developer') Insert into tblEmployees values('John', 'Stenson','Male','Sr. Developer') Insert into tblEmployees values('Gilbert', 'Sullivan','Male','Developer') Insert into tblEmployees values('Rob', 'Gerald','Male','Sr. Developer') Insert into tblEmployees values('Ron', 'Simpson','Male','Developer') Insert into tblEmployees values('Sara', 'Solomon','Female','Sr. Developer') Insert into tblEmployees values('Rad', 'Wicht','Male','Sr. Developer') Insert into tblEmployees values('Julian', 'John','Male','Developer') Insert into tblEmployees values('James', 'Bynes','Male','Sr. Developer') Insert into tblEmployees values('Mary', 'Ward','Female','Developer') Insert into tblEmployees values('Michael', 'Niron','Male','Sr. Developer') SQL Server stored procedure paging sorting and searching create proc spGetEmployees @DisplayLength int, @DisplayStart int, @SortCol int, @SortDir nvarchar(10), @Search nvarchar(255) = NULL as begin Declare @FirstRec int, @LastRec int Set @FirstRec = @DisplayStart; Set @LastRec = @DisplayStart + @DisplayLength; With CTE_Employees as ( Select ROW_NUMBER() over (order by case when (@SortCol = 0 and @SortDir='asc') then Id end asc, case when (@SortCol = 0 and @SortDir='desc') then Id end desc, case when (@SortCol = 1 and @SortDir='asc') then FirstName end asc, case when (@SortCol = 1 and @SortDir='desc') then FirstName end desc, case when (@SortCol = 2 and @SortDir='asc') then LastName end asc, case when (@SortCol = 2 and @SortDir='desc') then LastName end desc, case when (@SortCol = 3 and @SortDir='asc') then Gender end asc, case when (@SortCol = 3 and @SortDir='desc') then Gender end desc, case when (@SortCol = 4 and @SortDir='asc') then JobTitle end asc, case when (@SortCol = 4 and @SortDir='desc') then JobTitle end desc ) as RowNum, COUNT(*) over() as TotalCount, Id, FirstName, LastName, Gender, JobTitle from tblEmployees where (@Search IS NULL Or Id like '%' + @Search + '%' Or FirstName like '%' + @Search + '%' Or LastName like '%' + @Search + '%' Or Gender like '%' + @Search + '%' Or JobTitle like '%' + @Search + '%') ) Select * from CTE_Employees where RowNum ] @FirstRec and RowNum [= @LastRec end Finally test the stored procedure
Views: 38517 kudvenkat
PL/SQL: Stored Procedure Part-2
 
04:38
In this tutorial, you'll learn what is stored procedure. PL/SQL (Procedural Language/Structured Query Language) is Oracle Corporation's procedural extension for SQL and the Oracle relational database. PL/SQL is available in Oracle Database (since version 7), TimesTen in-memory database (since version 11.2.1), and IBM DB2 (since version 9.7).[1] Oracle Corporation usually extends PL/SQL functionality with each successive release of the Oracle Database. PL/SQL includes procedural language elements such as conditions and loops. It allows declaration of constants and variables, procedures and functions, types and variables of those types, and triggers. It can handle exceptions (runtime errors). Arrays are supported involving the use of PL/SQL collections. Implementations from version 8 of Oracle Database onwards have included features associated with object-orientation. One can create PL/SQL units such as procedures, functions, packages, types, and triggers, which are stored in the database for reuse by applications that use any of the Oracle Database programmatic interfaces. PL/SQL works analogously to the embedded procedural languages associated with other relational databases. For example, Sybase ASE and Microsoft SQL Server have Transact-SQL, PostgreSQL has PL/pgSQL (which emulates PL/SQL to an extent), and IBM DB2 includes SQL Procedural Language,[2] which conforms to the ISO SQL’s SQL/PSM standard. The designers of PL/SQL modeled its syntax on that of Ada. Both Ada and PL/SQL have Pascal as a common ancestor, and so PL/SQL also resembles Pascal in several aspects. However, the structure of a PL/SQL package does not resemble the basic Object Pascal program structure as implemented by a Borland Delphi or Free Pascal unit. Programmers can define public and private global data-types, constants and static variables in a PL/SQL package.[3] PL/SQL also allows for the definition of classes and instantiating these as objects in PL/SQL code. This resembles usage in object-oriented programming languages like Object Pascal, C++ and Java. PL/SQL refers to a class as an "Abstract Data Type" (ADT) or "User Defined Type" (UDT), and defines it as an Oracle SQL data-type as opposed to a PL/SQL user-defined type, allowing its use in both the Oracle SQL Engine and the Oracle PL/SQL engine. The constructor and methods of an Abstract Data Type are written in PL/SQL. The resulting Abstract Data Type can operate as an object class in PL/SQL. Such objects can also persist as column values in Oracle database tables. PL/SQL is fundamentally distinct from Transact-SQL, despite superficial similarities. Porting code from one to the other usually involves non-trivial work, not only due to the differences in the feature sets of the two languages,[4] but also due to the very significant differences in the way Oracle and SQL Server deal with concurrency and locking. There are software tools available that claim to facilitate porting including Oracle Translation Scratch Editor,[5] CEITON MSSQL/Oracle Compiler [6] and SwisSQL.[7] The StepSqlite product is a PL/SQL compiler for the popular small database SQLite. PL/SQL Program Unit A PL/SQL program unit is one of the following: PL/SQL anonymous block, procedure, function, package specification, package body, trigger, type specification, type body, library. Program units are the PL/SQL source code that is compiled, developed and ultimately executed on the database. The basic unit of a PL/SQL source program is the block, which groups together related declarations and statements. A PL/SQL block is defined by the keywords DECLARE, BEGIN, EXCEPTION, and END. These keywords divide the block into a declarative part, an executable part, and an exception-handling part. The declaration section is optional and may be used to define and initialize constants and variables. If a variable is not initialized then it defaults to NULL value. The optional exception-handling part is used to handle run time errors. Only the executable part is required. A block can have a label. Package Packages are groups of conceptually linked functions, procedures, variables, PL/SQL table and record TYPE statements, constants, cursors etc. The use of packages promotes re-use of code. Packages are composed of the package specification and an optional package body. The specification is the interface to the application; it declares the types, variables, constants, exceptions, cursors, and subprograms available. The body fully defines cursors and subprograms, and so implements the specification. Two advantages of packages are: Modular approach, encapsulation/hiding of business logic, security, performance improvement, re-usability. They support object-oriented programming features like function overloading and encapsulation. Using package variables one can declare session level (scoped) variables, since variables declared in the package specification have a session scope.
Views: 5699 radhikaravikumar
SQL: WITH Clause
 
06:11
In this tutorial, you'll learn will learn how to use with clause PL/SQL (Procedural Language/Structured Query Language) is Oracle Corporation's procedural extension for SQL and the Oracle relational database. PL/SQL is available in Oracle Database (since version 7), TimesTen in-memory database (since version 11.2.1), and IBM DB2 (since version 9.7).[1] Oracle Corporation usually extends PL/SQL functionality with each successive release of the Oracle Database. PL/SQL includes procedural language elements such as conditions and loops. It allows declaration of constants and variables, procedures and functions, types and variables of those types, and triggers. It can handle exceptions (runtime errors). Arrays are supported involving the use of PL/SQL collections. Implementations from version 8 of Oracle Database onwards have included features associated with object-orientation. One can create PL/SQL units such as procedures, functions, packages, types, and triggers, which are stored in the database for reuse by applications that use any of the Oracle Database programmatic interfaces. PL/SQL works analogously to the embedded procedural languages associated with other relational databases. For example, Sybase ASE and Microsoft SQL Server have Transact-SQL, PostgreSQL has PL/pgSQL (which emulates PL/SQL to an extent), and IBM DB2 includes SQL Procedural Language,[2] which conforms to the ISO SQL’s SQL/PSM standard. The designers of PL/SQL modeled its syntax on that of Ada. Both Ada and PL/SQL have Pascal as a common ancestor, and so PL/SQL also resembles Pascal in several aspects. However, the structure of a PL/SQL package does not resemble the basic Object Pascal program structure as implemented by a Borland Delphi or Free Pascal unit. Programmers can define public and private global data-types, constants and static variables in a PL/SQL package.[3] PL/SQL also allows for the definition of classes and instantiating these as objects in PL/SQL code. This resembles usage in object-oriented programming languages like Object Pascal, C++ and Java. PL/SQL refers to a class as an "Abstract Data Type" (ADT) or "User Defined Type" (UDT), and defines it as an Oracle SQL data-type as opposed to a PL/SQL user-defined type, allowing its use in both the Oracle SQL Engine and the Oracle PL/SQL engine. The constructor and methods of an Abstract Data Type are written in PL/SQL. The resulting Abstract Data Type can operate as an object class in PL/SQL. Such objects can also persist as column values in Oracle database tables. PL/SQL is fundamentally distinct from Transact-SQL, despite superficial similarities. Porting code from one to the other usually involves non-trivial work, not only due to the differences in the feature sets of the two languages,[4] but also due to the very significant differences in the way Oracle and SQL Server deal with concurrency and locking. There are software tools available that claim to facilitate porting including Oracle Translation Scratch Editor,[5] CEITON MSSQL/Oracle Compiler [6] and SwisSQL.[7] The StepSqlite product is a PL/SQL compiler for the popular small database SQLite. PL/SQL Program Unit A PL/SQL program unit is one of the following: PL/SQL anonymous block, procedure, function, package specification, package body, trigger, type specification, type body, library. Program units are the PL/SQL source code that is compiled, developed and ultimately executed on the database. The basic unit of a PL/SQL source program is the block, which groups together related declarations and statements. A PL/SQL block is defined by the keywords DECLARE, BEGIN, EXCEPTION, and END. These keywords divide the block into a declarative part, an executable part, and an exception-handling part. The declaration section is optional and may be used to define and initialize constants and variables. If a variable is not initialized then it defaults to NULL value. The optional exception-handling part is used to handle run time errors. Only the executable part is required. A block can have a label. Package Packages are groups of conceptually linked functions, procedures, variables, PL/SQL table and record TYPE statements, constants, cursors etc. The use of packages promotes re-use of code. Packages are composed of the package specification and an optional package body. The specification is the interface to the application; it declares the types, variables, constants, exceptions, cursors, and subprograms available. The body fully defines cursors and subprograms, and so implements the specification. Two advantages of packages are: Modular approach, encapsulation/hiding of business logic, security, performance improvement, re-usability. They support object-oriented programming features like function overloading and encapsulation. Using package variables one can declare session level (scoped) variables, since variables declared in the package specification have a session scope.
Views: 12214 radhikaravikumar
SQL Server join :- Inner join,Left join,Right join and full outer join
 
08:11
For more such videos visit http://www.questpond.com See our other Step by Step video series below :- Learn Angular tutorial for beginners https://tinyurl.com/ycd9j895 Learn MVC Core step by step :- http://tinyurl.com/y9jt3wkv Learn MSBI Step by Step in 32 hours:- https://goo.gl/TTpFZN Learn Xamarin Mobile Programming Step by Step :- https://goo.gl/WDVFuy Learn Design Pattern Step by Step in 8 hours:- https://goo.gl/eJdn0m Learn C# Step by Step in 100 hours :- https://goo.gl/FNlqn3 Learn Data structures & algorithm in 8 hours :-https://tinyurl.com/ybx29c5s Learn SQL Server Step by Step in 16 hours:- http://tinyurl.com/ja4zmwu Learn Javascript in 2 hours :- http://tinyurl.com/zkljbdl Learn SharePoint Step by Step in 8 hours:- https://goo.gl/XQKHeP Learn TypeScript in 45 Minutes :- https://goo.gl/oRkawI Learn webpack in 50 minutes:- https://goo.gl/ab7VJi Learn Visual Studio code in 10 steps for beginners:- https://tinyurl.com/lwgv8r8 Learn Tableau step by step :- https://tinyurl.com/kh6ojyo Preparing for C# / .NET interviews start here http://www.youtube.com/watch?v=gaDn-sVLj8Q In this video we will try to understand four important concepts Inner joins,Left join,Right join and full outer joins. We are also distributing a 100 page Ebook ".Sql Server Interview Question and Answers". If you want this ebook please share this video in your facebook/twitter/linkedin account and email us on [email protected] with the shared link and we will email you the PDF.
Views: 828912 Questpond
Debugging sql server stored procedures
 
15:11
debugging in ssms debugging t-sql code t sql debug stored procedure sql server management studio debug stored procedure how to debug t sql debug in sql server management studio In this video we will discuss how to debug stored procedures in SQL Server. Setting up the Debugger in SSMS : If you have connected to SQL Server using (local) or . (period), and when you start the debugger you will get the following error Unable to start T-SQL Debugging. Could not connect to computer. To fix this error, use the computer name to connect to the SQL Server instead of using (local) or . For the examples in this video we will be using the following stored procedure. Create procedure spPrintEvenNumbers @Target int as Begin Declare @StartNumber int Set @StartNumber = 1 while(@StartNumber [ @Target) Begin If(@StartNumber%2 = 0) Begin Print @StartNumber End Set @StartNumber = @StartNumber + 1 End Print 'Finished printing even numbers till ' + RTRIM(@Target) End Connect to SQL Server using your computer name, and then execute the above code to create the stored procedure. At this point, open a New Query window. Copy and paste the following T-SQL code to execute the stored procedure. DECLARE @TargetNumber INT SET @TargetNumber = 10 EXECUTE spPrintEvenNumbers @TargetNumber Print 'Done' Starting the Debugger in SSMS : There are 2 ways to start the debugger 1. In SSMS, click on the Debug Menu and select Start Debugging 2. Use the keyboard shortcut ALT + F5 At this point you should have the debugger running. The line that is about to be executed is marked with an yellow arrow Step Over, Step into and Step Out in SSMS : You can find the keyboard shortcuts in the Debug menu in SSMS. Let us understand what Step Over, Step into and Step Out does when debugging the following piece of code 1. There is no difference when you STEP INTO (F11) or STEP OVER (F10) the code on LINE 2 2. On LINE 3, we are calling a Stored Procedure. On this statement if we press F10 (STEP OVER), it won't give us the opportunity to debug the stored procedure code. To be able to debug the stored procedure code you will have to STEP INTO it by pressing F11. 3. If the debugger is in the stored procedure, and you don't want to debug line by line with in that stored procedure, you can STEP OUT of it by pressing SHIFT + F11. When you do this, the debugger completes the execution of the stored procedure and waits on the next line in the main query, i.e on LINE 4 in this example. To stop debugging : There are 2 ways to stop debugging 1. In SSMS, click on the Debug Menu and select Stop Debugging 2. Use the keyboard shortcut SHIFT + F5 Show Next Statement shows the next statement that the debugger is about to execute. Run to Cursor command executes all the statements in a batch up to the current cursor position Locals Window in SSMS : Displays the current values of variables and parameters If you cannot see the locals window or if you have closed it and if you want to open it, you can do so using the following menu option. Locals window is only available if you are in DEBUG mode. Watch Window in SSMS : Just like Locals window, Watch window is used to watch the values of variables. You can add and remove variables from the watch window. To add a variable to the Watch Window, right click on the variable and select "Add Watch" option from the context menu. Call Stack Window in SSMS : Allows you to navigate up and down the call stack to see what values your application is storing at different levels. It's an invaluable tool for determining why your code is doing what it's doing. Immediate Window in SSMS : Very helpful during debugging to evaluate expressions, and print variable values. To clear immediate window type ]cls and press enter. Breakpoints in SSMS : There are 2 ways to set a breakpoint in SSMS. 1. By clicking on the grey margin on the left hand side in SSMS (to remove click again) 2. By pressing F9 (to remove press F9 again) Enable, Disable or Delete all breakpoints : There are 2 ways to Enable, Disable or Delete all breakpoints 1. From the Debug menu 2. From the Breakpoints window. To view Breakpoints window select Debug =] Windows =] Breakpoints or use the keyboard shortcut ALT + CTRL + B Conditional Breakpoint : Conditional Breakpoints are hit only when the specified condition is met. These are extremely useful when you have some kind of a loop and you want to break, only when the loop variable has a specific value (For example loop varible = 100). How to set a conditional break point in SSMS : 1. Right click on the Breakpoint and select Condition from the context menu 2. In the Breakpoint window specify the condition Text version of the video http://csharp-video-tutorials.blogspot.com/2015/09/debugging-sql-server-stored-procedures.html Slides http://csharp-video-tutorials.blogspot.com/2015/09/debugging-sql-server-stored-procedures_28.html
Views: 101849 kudvenkat
SQL: Check Constraint
 
05:11
In this tutorial, you'll learn how to make use of check constraint. PL/SQL (Procedural Language/Structured Query Language) is Oracle Corporation's procedural extension for SQL and the Oracle relational database. PL/SQL is available in Oracle Database (since version 7), TimesTen in-memory database (since version 11.2.1), and IBM DB2 (since version 9.7).[1] Oracle Corporation usually extends PL/SQL functionality with each successive release of the Oracle Database. PL/SQL includes procedural language elements such as conditions and loops. It allows declaration of constants and variables, procedures and functions, types and variables of those types, and triggers. It can handle exceptions (runtime errors). Arrays are supported involving the use of PL/SQL collections. Implementations from version 8 of Oracle Database onwards have included features associated with object-orientation. One can create PL/SQL units such as procedures, functions, packages, types, and triggers, which are stored in the database for reuse by applications that use any of the Oracle Database programmatic interfaces. PL/SQL works analogously to the embedded procedural languages associated with other relational databases. For example, Sybase ASE and Microsoft SQL Server have Transact-SQL, PostgreSQL has PL/pgSQL (which emulates PL/SQL to an extent), and IBM DB2 includes SQL Procedural Language,[2] which conforms to the ISO SQL’s SQL/PSM standard. The designers of PL/SQL modeled its syntax on that of Ada. Both Ada and PL/SQL have Pascal as a common ancestor, and so PL/SQL also resembles Pascal in several aspects. However, the structure of a PL/SQL package does not resemble the basic Object Pascal program structure as implemented by a Borland Delphi or Free Pascal unit. Programmers can define public and private global data-types, constants and static variables in a PL/SQL package.[3] PL/SQL also allows for the definition of classes and instantiating these as objects in PL/SQL code. This resembles usage in object-oriented programming languages like Object Pascal, C++ and Java. PL/SQL refers to a class as an "Abstract Data Type" (ADT) or "User Defined Type" (UDT), and defines it as an Oracle SQL data-type as opposed to a PL/SQL user-defined type, allowing its use in both the Oracle SQL Engine and the Oracle PL/SQL engine. The constructor and methods of an Abstract Data Type are written in PL/SQL. The resulting Abstract Data Type can operate as an object class in PL/SQL. Such objects can also persist as column values in Oracle database tables. PL/SQL is fundamentally distinct from Transact-SQL, despite superficial similarities. Porting code from one to the other usually involves non-trivial work, not only due to the differences in the feature sets of the two languages,[4] but also due to the very significant differences in the way Oracle and SQL Server deal with concurrency and locking. There are software tools available that claim to facilitate porting including Oracle Translation Scratch Editor,[5] CEITON MSSQL/Oracle Compiler [6] and SwisSQL.[7] The StepSqlite product is a PL/SQL compiler for the popular small database SQLite. PL/SQL Program Unit A PL/SQL program unit is one of the following: PL/SQL anonymous block, procedure, function, package specification, package body, trigger, type specification, type body, library. Program units are the PL/SQL source code that is compiled, developed and ultimately executed on the database. The basic unit of a PL/SQL source program is the block, which groups together related declarations and statements. A PL/SQL block is defined by the keywords DECLARE, BEGIN, EXCEPTION, and END. These keywords divide the block into a declarative part, an executable part, and an exception-handling part. The declaration section is optional and may be used to define and initialize constants and variables. If a variable is not initialized then it defaults to NULL value. The optional exception-handling part is used to handle run time errors. Only the executable part is required. A block can have a label. Package Packages are groups of conceptually linked functions, procedures, variables, PL/SQL table and record TYPE statements, constants, cursors etc. The use of packages promotes re-use of code. Packages are composed of the package specification and an optional package body. The specification is the interface to the application; it declares the types, variables, constants, exceptions, cursors, and subprograms available. The body fully defines cursors and subprograms, and so implements the specification. Two advantages of packages are: Modular approach, encapsulation/hiding of business logic, security, performance improvement, re-usability. They support object-oriented programming features like function overloading and encapsulation. Using package variables one can declare session level (scoped) variables, since variables declared in the package specification have a session scope.
Views: 11833 radhikaravikumar
PL SQL Tutorials for Beginners | IF THEN ELSE Conditions
 
08:44
PL/SQL includes procedural language elements such as conditions and loops. It allows declaration of constants and variables, procedures and functions, types and variables of those types, and triggers. It can handle exceptions (runtime errors). Arrays are supported involving the use of PL/SQL collections. Implementations from version 8 of Oracle Database onwards have included features associated with object-orientation. One can create PL/SQL units such as procedures, functions, packages, types, and triggers, which are stored in the database for reuse by applications that use any of the Oracle Database programmatic interfaces. The IF-THEN-ELSIF statement allows you to choose between several alternatives. An IF-THEN statement can be followed by an optional ELSIF...ELSE statement. The ELSIF clause lets you add additional conditions. When using IF-THEN-ELSIF statements there are few points to keep in mind. It's ELSIF, not ELSEIF An IF-THEN statement can have zero or one ELSE's and it must come after any ELSIF's. An IF-THEN statement can have zero to many ELSIF's and they must come before the ELSE. Once an ELSIF succeeds, none of the remaining ELSIF's or ELSE's will be tested. Subscribe to our Channel for more videos https://www.youtube.com/channel/UC7sbHUgN8FnJEZkEjvKTwJg
Views: 125 Puzzle Guru

World war one essay
Essay directed writing speech language
Water shortage problem solution essay example
Conclusion for global warming essay
Villanova student reviews college prowler no essay