Java Hyd Team
746 subscribers
986 photos
39 videos
670 files
690 links
https://teamhydteam.my.canva.site/

Can visit us on our website ๐Ÿ˜Š
Still working on it ๐Ÿ˜Š
Download Telegram
For a quick brief you can refer these notes for tomorrow ๐Ÿ˜Š
1
2 3
4 5 6
7 8 9 10
11 12 13 14 15
16 17 18 19 20 21
22 23 24 25 26 27 28
29 30 31 32 33 34 35 36
37 38 39 40 41 42 43 44 45
46 47 48 49 50 51 52 53 54 55
Print this triangle ๐Ÿ“
Download from here
Java Hyd Team
SQL INTERVIEW QUESTIONS.pdf
Possibly this can help you with sql
Java Hyd Team
MYHTML.pptx
Can check this for basics of html
Java Hyd Team
JAVA BASICโ—พNOTES.pdf
Check this for hand written notes of html
The different join types in Oracle SQL are:
โ— Inner join: Returns records that exist in both tables.
โ— Left join/left outer join: Returns records that exist in the first table and shows NULL for those
values that donโ€™t exist in the second table.
โ— Right join/right outer join: Returns records that exist in the second table and shows NULL for
those values that donโ€™t exist in the first table.
โ— Full join/full outer join: Returns records that exist in both the first and second table, and shows
NULL for those values that donโ€™t exist in the corresponding table.
โ— Cross join: Returns all combinations of all records in both tables.
โ— Natural join: an inner join with two tables on columns that have the same names
โ— Self join: A join from one table to another record in the same table.
๐Ÿ‘1
The WHERE clause is run to remove data before grouping. The HAVING clause is run on data after it
has been grouped.
This also means the WHERE clause cannot operate on aggregate functions calculated as part of the
group.
COUNT(column) will return the number of non-NULL values in that column. COUNT(DISTINCT
column) will return the number of unique non-NULL values in that column.
. Whatโ€™s wrong with this query?
SELECT department_id, count(*)FROM department;
Answer:
There is no GROUP BY clause and it will display an error. Because we have used the COUNT function,
which is an aggregate function, along with a database field, we need to add a GROUP BY clause. It
should GROUP BY the department_id column.
Whatโ€™s wrong with this query?
SELECT department_id, count(*)
FROM department
WHERE count(*) > 5
GROUP BY department_id;
Answer:
The WHERE clause cannot include any checks on the aggregate column โ€“ even if a GROUP BY has
been performed.
This is because the WHERE happens before the grouping, so there is no way for the WHERE clause to
know what the value of the COUNT function is.
To resolve this, use the HAVING clause to check for COUNT(*) > 5.
What is the default sort order using ORDER BY? How can it be changed?
The default sort order is ascending. This can be changed by specifying the word DESC after any
column name in the ORDER BY clause. The word ASC can be used instead to specify ascending order.
Can you sort a column using a column alias?
Yes, you can sort by column aliases in an ORDER BY clause.
What is the difference between RANK and DENSE_RANK?
The difference between RANK and DENSE_RANK is where there is a tie or two records with the same
value.
RANK will assign non-consecutive values, which means there will be gaps in numbers.
DENSE_RANK will assign consecutive values, which means there will be no gaps.
Whatโ€™s the difference between UNION and JOIN?
A join allows us to lookup data from one table in another table based on common fields (for example
employees and departments). It requires us to have a field that is common in both tables.
A union allows us to combine the results of two queries into a single result. No join between the results
is needed. Only the number and type of columns need to be the same.
Whatโ€™s the difference between UNION, MINUS, and INTERSECT?
They are all set operators.
But, UNION will combine the results from query1 with query2 and remove duplicate records.
MINUS will display the results of query1 and remove those that match any records from query2.