Home
Search results “Oracle not exists select”
EXIST Function in SQL
 
08:04
Join Discussion: http://www.techtud.com/video-lecture/exist-function-sql IMPORTANT LINKS: 1) Official Website: http://www.techtud.com/ 2) Virtual GATE: http://virtualgate.in/login/index.php Both of the above mentioned platforms are COMPLETELY FREE, so feel free to Explore, Learn, Practice & Share! Our Social Media Links: Facebook Page: https://www.facebook.com/techtuduniversity Facebook Group: https://www.facebook.com/groups/virtualgate Google+ Page: https://plus.google.com/+techtud/posts Last but not the least, SUBSCRIBE our YouTube channel to stay updated about the regularly uploaded new videos.
Views: 32554 Techtud
Let's Learn SQL! Lesson 82 : EXIST and NOT EXIST Subqueries
 
03:37
Explore SQL with Tom Coffing of Coffing Data Warehousing! In this lesson, learn about EXIST and NOT EXIST Subqueries!
IN VS EXISTS VS JOIN, performance
 
05:04
This video demonstrates the performance effects of using an exists clause instead of an IN clause, also it shows how we can update a simple sub query having an IN clause with an EXISTS or JOIN statement. It also shows that joining would consider the null data, where as an IN clause would neglect null values. 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 procedure and function : https://youtu.be/q3LmOenL120 rank and dense_rank : https://youtu.be/WGSX998hZ9M delete and truncate : https://youtu.be/u76wMm2byXo %type and %rowtype : https://youtu.be/MlLUFeZ_3eM
Views: 10619 Kishan Mashru
How to use EXISTS / NOT EXISTS Logical Operator in SQL Server -  SQL Server / TSQL Tutorial Part 125
 
09:41
What is Exists / Not Exists Logical Operator in SQL Server Exists returns TRUE if a subquery contains any rows. EXISTS is used when we want to test for the existence of rows specified by a subquery. 1) EXISTS will return TRUE if subquery contains any rows. That is right, if our subquery will return any rows and we have used EXISTS, the outer query is going to return all rows. 2) Use EXISTS and Join with SubQuery Link to scripts used in SQL Server / TSQL Tutorial Video http://www.techbrothersit.com/2016/06/how-to-use-exists-logical-operator-in.html Check out our website for Different SQL Server, MSBI tutorials and interview questions such as SQL Server Reporting Services(SSRS) Tutorial SQL Server Integration Services(SSIS) Tutorial SQL Server DBA Tutorial SQL Server 2016 DBA Tutorial SQL Server / TSQL Tutorial ( Beginner to Advance) http://www.techbrothersit.com/
Views: 6089 TechBrothersIT
ORACLE SQL AND PL/SQL INTERVIEW QUESTION : SUBQUERY WITH NULL / NOT IN / NOT EXISTS OR OUTER JOIN
 
08:36
This video demonstrates the oracle sql interview question where one need to use either not in, not exists or an outer join to get the desired result. For example if one is asked to fetch records from department table where department_id is not present in employee table
Views: 1728 Kishan Mashru
PL/SQL tutorial 60: Collection Method EXISTS in Oracle Database by Manish Sharma
 
05:21
RebellionRider presents you the latest PL/SQL Tutorial 60 on Collection method EXISTS by Manish Sharma ------------------------------------------------------------------------ ►►►LINKS◄◄◄ Blog : http://bit.ly/exists-function Previous Tutorial ► ------------------------------------------------------------------------- ►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 http://instagram.com/rebellionrider https://plus.google.com/+Rebellionrider http://in.linkedin.com/in/mannbhardwaj/ ___Facebook Official Page of Manish Sharma___ https://www.facebook.com/TheRebellionRider/ ___Facebook Official Page of RebellionRider.com___ https://www.facebook.com/RebellionRider.official/ You can also Email me at for E-mail address please check the 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: 6093 Manish Sharma
SQL Error ORA-00942 Table or View Does Not Exist in Oracle Database
 
05:03
How to use Tab View (Data Dictionary) of Oracle Database to solve the SQL Error ORA-00942 Table or View Does Not Exist error in Oracle Database ------------------------------------------------------------------------ ►►►LINKS◄◄◄ Blog: http://bit.ly/ora-00942 Previous Tutorial ► ------------------------------------------------------------------------- ►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 http://instagram.com/rebellionrider https://plus.google.com/+Rebellionrider http://in.linkedin.com/in/mannbhardwaj/ ___Facebook Official Page of Manish Sharma___ https://www.facebook.com/TheRebellionRider/ ___Facebook Official Page of RebellionRider.com___ https://www.facebook.com/RebellionRider.official/ You can also Email me at for E-mail address please check the 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: 4835 Manish Sharma
The SQL EXISTS clause
 
08:52
How to use the EXISTS clause in SQL. For beginners.
Views: 20654 Database by Doug
ORACLE SQL INTERVIEW QUESTION : HOW TO SELECT ODD OR EVEN ROWS FROM A TABLE IN ORACLE
 
03:52
This video tutorial answers the frequently asked interview question, how to select only odd or even records in oracle sql, after watching this video you will understand more on the topic and will be able to answer this interview question with a lot of confidence.
Views: 3445 Kishan Mashru
Single Row Subqueries (Introduction to Oracle SQL)
 
03:01
Explains what a single row subquery is and how it's used. This is a subquery that returns one row. The full Introduction to Oracle SQL course is available here: https://www.databasestar.com/introduction-to-oracle-sql-course/
Views: 287 Database Star
NULL Value in Oracle Database | Oracle Tutorials for Beginners
 
03:18
NULL Value in Oracle Database | Oracle Tutorials for Beginners NULL Value in Oracle Database NULL Value in Oracle SQL NULL Value in SQL NULL Value in Oracle Database Oracle Tutorials for Beginners Oracle Tutorials for Beginners Oracle PL/SQL Tutorials for Beginners Oracle PL/SQL Tutorials for Beginners Oracle PL/SQL Tutorials for Beginners how to select null values in oracle oracle compare null values in where clause null=null in oracle how to handle null in case statement in oracle how to check null value in oracle stored procedure oracle nvl null value in oracle query how to check empty column value in oracle how to select null values in oracle oracle is null vs = null oracle nvl oracle is not null oracle decode oracle isnull oracle case when null select null from table in oracle oracle compare null values in where clause oracle select null how to check empty column value in oracle oracle sql not null or empty oracle is not null how to handle null in case statement in oracle oracle isnull oracle nvl
Views: 322 Oracle PL/SQL World
Oracle Operators in Oracle Database | Oracle Tutorial for Beginners
 
16:42
Oracle Operators in Oracle Database | Oracle Tutorial for Beginners Oracle Operators BETWEEN AND . NOT BETWEEN AND IS NULL and IS NOT NULL LIKE Operator in Oracle NOT LIKE Operators in Oracle IN and NOT IN Oracle SQL Oracle tutorials for Beginners oracle query between two timestamps oracle between inclusive oracle sql between two dates with time oracle between exclusive sql between dates sql between datetime sql between inclusive or exclusive between clause in oracle for date oracle not in vs not exists oracle not exists in condition in oracle oracle sql not in subquery oracle not in null if not exists in oracle not equal to in oracle not like in oracle how to select null values in oracle oracle case is null oracle compare null values in where clause oracle sql not null or empty oracle is not null oracle case when not null then how to handle null in case statement in oracle is null in oracle not like in oracle with multiple values oracle not like wildcard oracle sql like multiple values if not in oracle pl sql sql query not like multiple values how to pass parameter in like operator in oracle regexp_like in oracle oracle not equal
Views: 306 Oracle PL/SQL World
SQL SELECT - 13 - SUBCONSULTAS: EXISTS
 
03:57
Todo lo que necesitas en: http://tutorialesnet.com Redes Sociales: http://tutorialesnet.com/twitter http://tutorialesnet.com/facebook
Views: 6257 TutorialesNET
Difference between Case and Decode
 
10:14
This video tutorial explains on how case statement and decode function are different from each other. Though both of them are used in giving the if-then-else conditional functionality to sql statement, they differ much from each other, this video will walk through each of the difference with appropriate examples. If you want more such videos of exciting and amazing 'difference between' concepts, check out the links below : char and varchar2 : https://youtu.be/039qzwjWf4k replace and translate : https://youtu.be/HKYF77BGzOE procedure and function : https://youtu.be/q3LmOenL120 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: 10494 Kishan Mashru
LNNVL FUNCTION IN ORACLE SQL
 
09:11
This video is the 5th video in the series of 'working with null', this video explains the working of the lnnvl function in oracle sql with simple and easy to understand example. LNNVL provides a concise way to evaluate a condition when one or both operands of the condition may be null. The function can be used only in the WHERE clause of a query. It takes as an argument a condition and returns TRUE if the condition is FALSE or UNKNOWN and FALSE if the condition is TRUE. LNNVL can be used anywhere a scalar expression can appear, even in contexts where the IS [NOT] NULL, AND, or OR conditions are not valid but would otherwise be required to account for potential nulls. Oracle Database sometimes uses the LNNVL function internally in this way to rewrite NOT IN conditions as NOT EXISTS conditions. In such cases, output from EXPLAIN PLAN shows this operation in the plan table output. The condition can evaluate any scalar values but cannot be a compound condition containing AND, OR, or BETWEEN.
Views: 554 Kishan Mashru
What to choose for performance   SubQuery or Joins   Part 62
 
12:26
Text version of the video http://csharp-video-tutorials.blogspot.com/2013/01/what-to-choose-for-performance.html Slides http://csharp-video-tutorials.blogspot.com/2013/09/part-62-what-to-choose-for-performance.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 What to choose for performance - SubQuery or Joins According to MSDN, in sql server, in most cases, there is usually no performance difference between queries that uses sub-queries and equivalent queries using joins. For example, on my machine I have 400,000 records in tblProducts table 600,000 records in tblProductSales tables The following query, returns, the list of products that we have sold atleast once. This query is formed using sub-queries. When I execute this query I get 306,199 rows in 6 seconds Select Id, Name, Description from tblProducts where ID IN ( Select ProductId from tblProductSales ) At this stage please clean the query and execution plan cache using the following T-SQL command. CHECKPOINT; GO DBCC DROPCLEANBUFFERS; Go DBCC FREEPROCCACHE; GO Now, run the query that is formed using joins. Notice that I get the exact same 306,199 rows in 6 seconds. Select distinct tblProducts.Id, Name, Description from tblProducts inner join tblProductSales on tblProducts.Id = tblProductSales.ProductId Please Note: I have used automated sql script to insert huge amounts of this random data. Please watch Part 61 of SQL Server tutorial, in which we have discussed about this automated script. According to MSDN, in some cases where existence must be checked, a join produces better performance. Otherwise, the nested query must be processed for each result of the outer query. In such cases, a join approach would yield better results. The following query returns the products that we have not sold atleast once. This query is formed using sub-queries. When I execute this query I get 93,801 rows in 3 seconds Select Id, Name, [Description] from tblProducts where Not Exists(Select * from tblProductSales where ProductId = tblProducts.Id) When I execute the below equivalent query, that uses joins, I get the exact same 93,801 rows in 3 seconds. Select tblProducts.Id, Name, [Description] from tblProducts left join tblProductSales on tblProducts.Id = tblProductSales.ProductId where tblProductSales.ProductId IS NULL In general joins work faster than sub-queries, but in reality it all depends on the execution plan that is generated by SQL Server. It does not matter how we have written the query, SQL Server will always transform it on an execution plan. If sql server generates the same plan from both queries, we will get the same result. I would say, rather than going by theory, turn on client statistics and execution plan to see the performance of each option, and then make a decision. In a later video session we will discuss about client statistics and execution plans in detail.
Views: 81991 kudvenkat
How to use exists statement
 
03:30
Hello Friends In this video i'm going to show you how to use exist in subquery step by step.
Views: 5093 OCP Technology
ORACLE SQL AND PL/SQL INTERVIEW QUESTION : SUBQUERY WITH IN / EXISTS OR SELF JOIN
 
09:31
This video demonstrates the solution of the oracle sql interview question like, find the employees where there manager's salary is more than 15000. This is a classic example of using a subquery or a self join to get the result.
Views: 2205 Kishan Mashru
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: 12932 Sourn Sarim
SQL EXISTS() Existential Subqueries
 
04:34
Desmonstrates SQL existential subqueries.
Views: 20203 Jamie King
59. Subquery in PL/SQL Oracle
 
19:12
In this video you will learn about Subquery in Oracle. For Support =========== Email: [email protected] Contact Form: http://www.learninhindi.com/home/contact Our Social Media ================ Facebook: https://www.facebook.com/LearnInHindi Twitter: https://twitter.com/LearnInHindi For Training & Videos ===================== For more videos and articles visit: http://www.learninhindi.com Free Java Programming In Hindi Course ===================================== https://www.youtube.com/playlist?list=PLOZ3jentlCDAwwhMyoLISrxkXTADGp7PH Free Oracle PL/SQL Programming In Hindi Course ============================================== https://www.youtube.com/playlist?list=PLB5DA82419C2D99B6 Free C Programming In Hindi Course ================================== https://www.youtube.com/playlist?list=PLOZ3jentlCDAxKpBLMWogxSdy6BZcsAJq Trips & Tricks Channel ====================== https://www.youtube.com/channel/UCGmLfkuCo-3lHHJXRJ9HUMw Programming in Hindi Channel ============================ https://www.youtube.com/channel/UCudElIDgwNrybeAvXIy1HZQ
Views: 5419 ITORIAN
Subqueries: Databases for Developers #11
 
07:45
In SQL you can base queries on the results of other queries. This video explains the various types of subquery and their uses, covering: - Inline views - IN & EXISTS - Common table expressions/subquery factoring/with clause - Scalar subqueries Take the course; Databases for Developers: Next Level https://blogs.oracle.com/academy/take-your-sql-skills-to-the-next-level-with-this-free-online-10-part-tutorial Further reading: About Queries and Subqueries: https://docs.oracle.com/en/database/oracle/oracle-database/18/sqlrf/About-Queries-and-Subqueries.html Using Subqueries: https://docs.oracle.com/en/database/oracle/oracle-database/18/sqlrf/Using-Subqueries.html Need help with SQL? Ask us over on AskTOM: https://asktom.oracle.com Twitter: https://twitter.com/ChrisRSaxon Daily SQL Twitter tips: https://twitter.com/SQLDaily All Things SQL blog: https://blogs.oracle.com/sql/ ============================ The Magic of SQL with Chris Saxon Copyright © 2015 Oracle and/or its affiliates. Oracle is a registered trademark of Oracle and/or its affiliates. All rights reserved. Other names may be registered trademarks of their respective owners. Oracle disclaims any warranties or representations as to the accuracy or completeness of this recording, demonstration, and/or written materials (the “Materials”). The Materials are provided “as is” without any warranty of any kind, either express or implied, including without limitation warranties or merchantability, fitness for a particular purpose, and non-infringement.
Views: 1201 The Magic of SQL
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: 4374 Kishan Mashru
Difference between IN and EXISTS clause in database
 
04:18
Difference between IN and EXISTS clause in database
Views: 399 Techie Savy
SQL Server except operator
 
05:14
sql except example sql except operator example sql server except example sql server except order by sql server except clause SQL Server except operator In this video we will discuss SQL Server except operator with examples. EXCEPT operator returns unique rows from the left query that aren’t in the right query’s results. Introduced in SQL Server 2005 The number and the order of the columns must be the same in all queries The data types must be same or compatible This is similar to minus operator in oracle Let us understand this with an example. SQL Script to create the tables Create Table TableA ( Id int primary key, Name nvarchar(50), Gender nvarchar(10) ) Go Insert into TableA values (1, 'Mark', 'Male') Insert into TableA values (2, 'Mary', 'Female') Insert into TableA values (3, 'Steve', 'Male') Insert into TableA values (4, 'John', 'Male') Insert into TableA values (5, 'Sara', 'Female') Go Create Table TableB ( Id int primary key, Name nvarchar(50), Gender nvarchar(10) ) Go Insert into TableB values (4, 'John', 'Male') Insert into TableB values (5, 'Sara', 'Female') Insert into TableB values (6, 'Pam', 'Female') Insert into TableB values (7, 'Rebeka', 'Female') Insert into TableB values (8, 'Jordan', 'Male') Go Notice that the following query returns the unique rows from the left query that aren’t in the right query’s results. Select Id, Name, Gender From TableA Except Select Id, Name, Gender From TableB To retrieve all of the rows from Table B that does not exist in Table A, reverse the two queries as shown below. Select Id, Name, Gender From TableB Except Select Id, Name, Gender From TableA You can also use Except operator on a single table. SQL script to create tblEmployees table Create table tblEmployees ( Id int identity primary key, Name nvarchar(100), Gender nvarchar(10), Salary int ) Go Insert into tblEmployees values ('Mark', 'Male', 52000) Insert into tblEmployees values ('Mary', 'Female', 55000) Insert into tblEmployees values ('Steve', 'Male', 45000) Insert into tblEmployees values ('John', 'Male', 40000) Insert into tblEmployees values ('Sara', 'Female', 48000) Insert into tblEmployees values ('Pam', 'Female', 60000) Insert into tblEmployees values ('Tom', 'Male', 58000) Insert into tblEmployees values ('George', 'Male', 65000) Insert into tblEmployees values ('Tina', 'Female', 67000) Insert into tblEmployees values ('Ben', 'Male', 80000) Go Except operator on a single table Select Id, Name, Gender, Salary From tblEmployees Where Salary ]= 50000 Except Select Id, Name, Gender, Salary From tblEmployees Where Salary ]= 60000 Order By clause should be used only once after the right query Select Id, Name, Gender, Salary From tblEmployees Where Salary ]= 50000 Except Select Id, Name, Gender, Salary From tblEmployees Where Salary ]= 60000 order By Name Text version of the video http://csharp-video-tutorials.blogspot.com/2015/09/sql-server-except-operator.html Slides http://csharp-video-tutorials.blogspot.com/2015/09/adsbygoogle-window.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: 37021 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: 7140 Kishan Mashru
Understanding Correlated Queries in SQL
 
08:13
Join Discussion: http://www.techtud.com/video-lecture/understanding-correlated-queries-sql IMPORTANT LINKS: 1) Official Website: http://www.techtud.com/ 2) Virtual GATE: http://virtualgate.in/login/index.php Both of the above mentioned platforms are COMPLETELY FREE, so feel free to Explore, Learn, Practice & Share! Our Social Media Links: Facebook Page: https://www.facebook.com/techtuduniversity Facebook Group: https://www.facebook.com/groups/virtualgate Google+ Page: https://plus.google.com/+techtud/posts Last but not the least, SUBSCRIBE our YouTube channel to stay updated about the regularly uploaded new videos.
Views: 41711 Techtud
Oracle - SQL - Subqueries
 
13:27
Oracle - SQL - Subqueries Watch more Videos at https://www.tutorialspoint.com/videotutorials/index.htm Lecture By: Mr. Anadi Sharma, Tutorials Point India Private Limited.
Oracle SQL Tutorial 16 - Parent Child Relationships
 
06:09
So far in this series we have discussed database design, creating tables, and constraints. We've brought up the concept of foreign keys, but we have not explained how to create them. That is the goal of this video and the upcoming videos. We want to study those foreign keys! Let's make them not so foreign. Let's learn the proper way to define a foreign key. As a reminder, a foreign key is a column that references a column of another table. The column it references must either be a primary key, or have the UNIQUE constraint. This means that every value inside of the column that is labeled as a foreign key, there must be that value in some row of the referenced column. As an example, imagine that we have the users table, and we have a table service_requests. We could have a column in the service_request that references a column in the users table. Usually this would be the primary key that is referenced, but there is nothing stopping you from referencing a unique column. Just for fun, let's go through an example using the username column. If we have a service_requests table, every single row within the table is going to be what some would consider an instance of a service_request. This means that the table columns are like the blueprint for what a service request looks like and then each row is an individual service request. If we have one of the columns labeled as a foreign key to the username of the users table, what does that mean practically? It means that for a single row, the value for that column must be a value that exists in the users table. We could have a service_request submitted by a user with the username of Yoloswagman. This means that there must be a row inside of the users table that has the value Yoloswagman for the username column. This brings up the concept of parent and child relationships. Yoloswagman in this situation is the parent, and his service request is the child. When we draw it out, it makes sense why a primary key must be UNIQUE. If we had two Yoloswagmans, the child would not know which column is the parent. The same applies if we were using IDs and we had So remember, always reference a primary key or a column with the UNIQUE constraint. Now, I have a question for you. Do foreign keys automatically have the UNIQUE constraint, just like primary keys? The answer is no. A parent row can have many child rows. It makes sense because the user could submit multiple service requests. Can we force the column to be unique? Absolutely. If that was the case, the user could only make one service request. Another question. Do foreign keys automatically have the NOT NULL constraint, just like primary keys? The answer is no. Essentially what this means is that a child could be created with no parent. Can we force the column to be NOT NULL? Absolutely. It is ok in some situations to allow the row to be null, but in this situation it makes no sense. It would be wise for us to add that constraint ourselves. So now that you understand some more differences between primary and foreign keys and parent child relationships, take all of these questions into consideration when you are creating foreign keys. In the next video, we are going to start a small project that is going to require multiple tables. We'll take a video to design our structure and then we'll get to creating those foreign keys in Oracle SQL Developer. Stick around and if you like these videos please be a serious supporter and subscribe to my channel. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HELP ME! http://www.patreon.com/calebcurry Subscribe to my newsletter: http://bit.ly/JoinCCNewsletter Donate!: http://bit.ly/DonateCTVM2. ~~~~~~~~~~~~~~~Additional Links~~~~~~~~~~~~~~~ More content: http://CalebCurry.com Facebook: http://www.facebook.com/CalebTheVideoMaker Google+: https://plus.google.com/+CalebTheVideoMaker2 Twitter: http://twitter.com/calebCurry Amazing Web Hosting - http://bit.ly/ccbluehost (The best web hosting for a cheap price!)
Views: 10183 Caleb Curry
IN v/s EXISTS v/s JOIN, which one will give better performance under what condition?
 
04:56
This video demonstrates the performance effects of using an exists clause instead of an IN clause, also it shows how we can update a simple sub query having an IN clause with an EXISTS or JOIN statement. It also shows that joining would consider the null data, where as an IN clause would neglect null values.
Views: 954 Kishan Mashru
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: 56182 Manish Sharma
Oracle Using In , Between and Not تعليم أوراكل
 
10:27
by Mohamed El Desouki - محمد الدسوقى [email protected] Tel :00966 553450836 جامعة سلمان بن عبد العزيز - السعودية - الخرج How to use In , Between and Not. Text Book: Fundamentals of Database Systems, 5th Edition, by Elmasri/Navathe, published by Addison-W oracle create table statement oracle drop table statement oracle constraints database constraints primary key constraint foreign key constraint check constraint null not null constraint unique constraint insert into statement update statement delete statement select statement basic query where clause select where Like '%' Like '_' select where Like select where Between Between , Not Between select where In , Not In
Alias Names  In Oracle | Oracle Tutorials for Beginners
 
07:30
Alias Names In Oracle | Oracle Tutorials for Beginners Column Level Alias Names in Oracle Table Level Alias names in Oracle Oracle Tutorials for Beginners Oracle pl/sql Tutorials for Beginners Oracle Tutorials for Beginners Oracle Tutorials for Beginners Oracle Tutorials for Beginners Oracle Tutorials for Beginners PlayList Oracle Tutorials for Beginners Playlist Oracle Tutorials for Beginners oracle alias column name with space oracle sql column alias in where clause oracle sql alias subquery oracle join alias oracle database alias alias sql sql alias join oracle as keyword sql query column name with space how to find space in a column in oracle select column name with space in teradata sql column name with space in where clause oracle sql alias subquery teradata column alias with space oracle column names with special characters oracle sql column alias with spaces sql alias join sql alias without as sql alias in where clause changing column names in sql query results how to join two tables with alias sql server alias aliases are very handy when table names are long sql as
Views: 354 Oracle PL/SQL World
SQL script to insert into many to many table
 
14:52
Text Article http://csharp-video-tutorials.blogspot.com/2017/02/sql-script-to-insert-into-many-to-many.html Slides http://csharp-video-tutorials.blogspot.com/2017/02/sql-script-to-insert-into-many-to-many_6.html SQL Server Interview Questions and Answers text articles & slides http://csharp-video-tutorials.blogspot.com/2014/05/sql-server-interview-questions-and.html SQL Server Interview Questions and Answers playlist https://www.youtube.com/playlist?list=PL6n9fhu94yhXcztdLO7i6mdyaegC8CJwR 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 discuss how to insert data into a table that has many-to-many relationship Create table Students ( Id int primary key identity, StudentName nvarchar(50) ) Go Create table Courses ( Id int primary key identity, CourseName nvarchar(50) ) Go Create table StudentCourses ( StudentId int not null foreign key references Students(Id), CourseId int not null foreign key references Courses(Id) ) Go Students - Id column is identity column Courses - Id column is identity column StudentCourses - StudentId and CourseId columns are foreign keys referencing Id column in Students and Courses tables As you can see, StudentCourses is a bridge table that has many to many relationship with Students and Courses tables. This means a given student can be enrolled into many courses and a given course can have many students enrolled. Below is the question asked in an interview for SQL Server Developer role. Write a SQL script to insert data into StudentCourses table. Here are the rules that your script should follow. 1. There will be 2 inputs for the script Student Name - The name of the student who wants to enroll into a course Course Name - The name of the course the student wants to enroll into 2. If the student is already in the Students table, then use that existing Student Id. If the student is not already in the Students table, then a row for that student must be inserted into the Students table, and use that new student id. 3. Along the same lines, if the course is already in the Courses table, then use that existing Course Id. If the course is not already in the Courses table, then a row for that course must be inserted into the Courses table, and use that new course id. 4. There should be no duplicate student course enrollments, i.e a given student must not be enrolled in the same course twice. For example, Tom must not be enrolled in C# course twice. Answer : To avoid duplicate student course enrollments create a composite primary key on StudentId and CourseId columns in StudentCourses table. With this composite primary key in place, if someone tries to enroll the same student in the same course again we get violation of primary key constraint error. Alter table StudentCourses Add Constraint PK_StudentCourses Primary Key Clustered (CourseId, StudentId) Here is the SQL script that inserts data into the 3 tables as expected Declare @StudentName nvarchar(50) = 'Sam' Declare @CourseName nvarchar(50) = 'SQL Server' Declare @StudentId int Declare @CourseId int -- If the student already exists, use the existing student ID Select @StudentId = Id from Students where StudentName = @StudentName -- If the course already exists, use the existing course ID Select @CourseId = Id from Courses where CourseName = @CourseName -- If the student does not exist in the Students table If (@StudentId is null) Begin -- Insert the student Insert into Students values(@StudentName) -- Get the Id of the student Select @StudentId = SCOPE_IDENTITY() End -- If the course does not exist in the Courses table If (@CourseId is null) Begin -- Insert the course Insert into Courses values(@CourseName) -- Get the Id of the course Select @CourseId = SCOPE_IDENTITY() End -- Insert StudentId & CourseId in StudentCourses table Insert into StudentCourses values(@StudentId, @CourseId) If required, we can very easily convert this into a stored procedure as shown below. Create procedure spInsertIntoStudentCourses @StudentName nvarchar(50), @CourseName nvarchar(50) as Begin Declare @StudentId int Declare @CourseId int Select @StudentId = Id from Students where StudentName = @StudentName Select @CourseId = Id from Courses where CourseName = @CourseName If (@StudentId is null) Begin Insert into Students values(@StudentName) Select @StudentId = SCOPE_IDENTITY() End If (@CourseId is null) Begin Insert into Courses values(@CourseName) Select @CourseId = SCOPE_IDENTITY() End Insert into StudentCourses values(@StudentId, @CourseId) End Use the following statement to execute the stored procedure Execute spInsertIntoStudentCourses 'Tom','C#'
Views: 70416 kudvenkat
SQL 136 Subselect, EXISTS with Subselects
 
03:37
Explains how EXISTS with subselects work. From http://ComputerBasedTrainingInc.com SQL Course. Learn by doing SQL commands for ANSI Standard SQL, Access, DB2, MySQL, Oracle, PostgreSQL, and SQL Server.
Views: 4836 cbtinc
The GROUP BY clause of the SQL SELECT statement (for ORACLE, MySQL, SQL Server, etc.)
 
07:49
The Structured Query Language (SQL) is the most powerful database language in use today. SELECT is the most powerful statement within SQL, and the GROUP BY clause is part of the reason. Learn the inner workings of GROUP BY and make yourself a more powerful database professional! From Steve O'Hearn of databasetraining.com and Corbinian, author of Oracle Press books, including the first "expert" level certification exam guide from Oracle Corporation, the "OCA Oracle Database SQL Expert Exam Guide: Exam 1Z0-047". (http://www.amazon.com/Oracle-Database-Expert-Exam-Guide/dp/0071614214/ref=sr_1_1?ie=UTF8&qid=1371769056&sr=8-1&keywords=oracle+sql+expert) This information is good for use with Oracle, MySQL, Microsoft SQL Server, and any ANSI-standard SQL database. Full transcript available here: http://databasetraining.com/node/3
Views: 15628 DatabaseTraining
EXISTS Operator in SQL Server
 
06:17
Click here to Subscribe to IT PORT Channel : https://www.youtube.com/channel/UCMjmoppveJ3mwspLKXYbVlg Specifies a subquery to test for the existence of rows. In this video you can check Exists and Not Exists with Simple Example
Views: 738 IT Port
IS NULL Operator in SQL Query with Example
 
02:24
SQL IS NULL Operator: A column value is NULL if it does not exist. The IS NULL operator is used to display all the rows for columns that do not have a value. For Example: If you want to find the emp names who do not get any commision, the query would be as given below: select * from emp where COMM IS NULL; In the opposite way, NOT NULL also works here: select * from emp where COMM IS NOT NULL; Thanks for watching..:)
Views: 3361 WingsOfTechnology
Intersect operator in sql server
 
05:29
sql intersect vs join sql server intersect example sql server intersect vs inner join sql server inner join remove duplicates In this video we will discuss 1. Intersect operator in sql server 2. Difference between intersect and inner join Intersect operator retrieves the common records from both the left and the right query of the Intersect operator. Introduced in SQL Server 2005 The number and the order of the columns must be same in both the queries The data types must be same or at least compatible Let us understand INTERSECT operator with an example. The following query retrieves the common records from both the left and the right query of the Intersect operator. Select Id, Name, Gender from TableA Intersect Select Id, Name, Gender from TableB We can also achieve the same thinkg using INNER join. The following INNER join query would produce the exact same result. Select TableA.Id, TableA.Name, TableA.Gender From TableA Inner Join TableB On TableA.Id = TableB.Id What is the difference between INTERSECT and INNER JOIN 1. INTERSECT filters duplicates and returns only DISTINCT rows that are common between the LEFT and Right Query, where as INNER JOIN does not filter the duplicates. To understand this difference, insert the following row into TableA Insert into TableA values (2, 'Mary', 'Female') Now execute the following INTERSECT query. Notice that we get only the DISTINCT rows Select Id, Name, Gender from TableA Intersect Select Id, Name, Gender from TableB Now execute the following INNER JOIN query. Notice that the duplicate rows are not filtered. Select TableA.Id, TableA.Name, TableA.Gender From TableA Inner Join TableB On TableA.Id = TableB.Id You can make the INNER JOIN behave like INTERSECT operator by using the DISTINCT operator Select DISTINCT TableA.Id, TableA.Name, TableA.Gender From TableA Inner Join TableB On TableA.Id = TableB.Id 2. INNER JOIN treats two NULLS as two different values. So if you are joining two tables based on a nullable column and if both tables have NULLs in that joining column then, INNER JOIN will not include those rows in the result-set, where as INTERSECT treats two NULLs as a same value and it returns all matching rows. To understand this difference, execute the following 2 insert statements Insert into TableA values(NULL, 'Pam', 'Female') Insert into TableB values(NULL, 'Pam', 'Female') INTERSECT query Select Id, Name, Gender from TableA Intersect Select Id, Name, Gender from TableB INNER JOIN query Select TableA.Id, TableA.Name, TableA.Gender From TableA Inner Join TableB On TableA.Id = TableB.Id Text version of the video http://csharp-video-tutorials.blogspot.com/2015/09/intersect-operator-in-sql-server.html Slides http://csharp-video-tutorials.blogspot.com/2015/09/intersect-operator-in-sql-server_6.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: 34685 kudvenkat
Oracle SQL Lecture 26: ALL and ANY
 
03:34
Oracle Sql: ALL and ANY https://www.youtube.com/channel/UCnBpiBIOtRgMsk4G7Ri1jbQ
Views: 2382 Oracle SQL
Java- MySQL Connection (Create Table, Insert, Select)
 
09:55
This is a fast tutorial, intended for people who understand java, and the basics of SQL/MySQL who just want to see how to use my-sql-connector. How to create a MySQL Connection in java, then create a table, insert, and select, video 1 of 4. CODE: import java.sql.Connection; import java.sql.DriverManager; public static Connection getConnection() throws Exception{ try{ String driver = "com.mysql.jdbc.Driver"; String url = "jdbc:mysql://24.196.52.166:3306/testdb"; String username = "username"; String password = "password"; Class.forName(driver); Connection conn = DriverManager.getConnection(url,username,password); System.out.println("Connected"); return conn; } catch(Exception e){System.out.println(e);} return null; } Download JDBC https://dev.mysql.com/downloads/connector/j/ --06/07/2107
Views: 249620 Steven Byrne
50. Subquery or Inner Query or Nested Query in PL/SQL Oracle
 
03:40
In this video you will learn about Subquery or Inner Query or Nested Query in PL/SQL Oracle. For Support =========== Email: [email protected] Contact Form: http://www.learninhindi.com/home/contact Our Social Media ================ Facebook: https://www.facebook.com/LearnInHindi Twitter: https://twitter.com/LearnInHindi For Training & Videos ===================== For more videos and articles visit: http://www.learninhindi.com Free Java Programming In Hindi Course ===================================== https://www.youtube.com/playlist?list=PLOZ3jentlCDAwwhMyoLISrxkXTADGp7PH Free Oracle PL/SQL Programming In Hindi Course ============================================== https://www.youtube.com/playlist?list=PLB5DA82419C2D99B6 Free C Programming In Hindi Course ================================== https://www.youtube.com/playlist?list=PLOZ3jentlCDAxKpBLMWogxSdy6BZcsAJq Trips & Tricks Channel ====================== https://www.youtube.com/channel/UCGmLfkuCo-3lHHJXRJ9HUMw Programming in Hindi Channel ============================ https://www.youtube.com/channel/UCudElIDgwNrybeAvXIy1HZQ
Views: 6183 ITORIAN
Oracle SQL Tutorial 22 - Why Primary Keys Shouldn't Change
 
07:14
In the last video I mentioned that with our database design it is important to make sure that nobody tries to update a user's username. What happens if they do? Nothing horrible, Oracle will just throw an error. That's not such a big deal, but if you are hoping to make some kind of application that allows someone to change their username, this is not the best set up. Why? If you look at the projects table, we have a foreign key that references the username. Let's assume for a moment that Oracle allows you to do anything with your data. That means that if a user updates their username, there will be projects created by users that don't exist. Or a user could change their name to the previous owner. To fix this problem, we would need something such as an ON UPDATE CASCADE command for our foreign key. That would mean that if the user updated their username, the columns that reference that username would also update to the new value. This exists in some database management systems, but this does not exist in Oracle at the time of this video. How do we get around this problem? I'm sure we could conjure up something to allow us to update the username, but the easiest solution is to reference the user_id instead of the username. That way, when the username is updated, nothing changes inside of the foreign key. As a general rule, primary keys should never change. Foreign keys CAN change, but they should not change because a primary key changed. So, if we did happen to use a username as a column, it would be frowned upon if the username had to change because the column it references changes. However, it would be acceptable to change the foreign key if we needed to point to a new entity in the users table. Even if a username is never intended to change, these complications bother a lot of people. You can mitigate these problems by only referencing surrogate keys in foreign keys. This has the downside though that when you retrieve the data, you are going to have to do more work to make the data readable. For example, we had a table that was called project_users. It is essentially a table that says what users are part of what projects. We could have the foreign keys reference the project's name and the user's username. Then when you could say SELECT * FROM project_users. The data would be completely readable without doing anything. If you switch to only referencing surrogate primary keys, you will have a bunch of random numbers that don't mean anything and will have to be joined with other tables…which is really super frustrating when later you have to join a thousand tables to read anything. Which side do you prefer? Pick a side. Choose wisely. I'll see you all in the next video ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HELP ME! http://www.patreon.com/calebcurry Subscribe to my newsletter: http://bit.ly/JoinCCNewsletter Donate!: http://bit.ly/DonateCTVM2. ~~~~~~~~~~~~~~~Additional Links~~~~~~~~~~~~~~~ More content: http://CalebCurry.com Facebook: http://www.facebook.com/CalebTheVideoMaker Google+: https://plus.google.com/+CalebTheVideoMaker2 Twitter: http://twitter.com/calebCurry Amazing Web Hosting - http://bit.ly/ccbluehost (The best web hosting for a cheap price!)
Views: 4887 Caleb Curry
How to delete duplicate records from a table in oracle
 
02:01
Let c how to remove duplicates from a table..I have one table here 'student' It has two duplicate records. 3 joe 4 robert These two records has duplicates. So I have to remove them. I can remove them using rowid functionality using one subquery. You can give different column names in GROUP BY clause. to identify the duplicate record. You can give just primary key values also. Duplicate rows are deleted now... Query used in video: delete from student where rowid not in (select min(rowid) from student group by sno,sname); Thanks for watching...:)
Views: 14339 WingsOfTechnology
ALL, ANY and SOME Comparison Conditions in SQL
 
02:00
This video demonstrates the use of the ALL, ANY and SOME comparison conditions in SQL. You don't see them used in Oracle very often, probably because there are functionally equivalent statements that are in more common use instead. For more information see: https://oracle-base.com/articles/misc/all-any-some-comparison-conditions-in-sql Website: https://oracle-base.com Blog: https://oracle-base.com/blog Twitter: https://twitter.com/oraclebase Cameo by Jorge Rimblas (actually, his children :) ) Blog: http://rimblas.com/blog/ Twitter: https://twitter.com/rimblas Cameo appearances are for fun, not an endorsement of the content of this video.
Views: 11323 ORACLE-BASE.com
Java & MySQL - Check if a value already exists
 
12:03
Easy tutorial on how to check if a value already exists in the database.
Views: 24694 Mozoran