From the course: Oracle Database 12c: Basic SQL
Unlock the full course today
Join today to access over 24,400 courses taught by industry experts.
Using CONCAT - Oracle Database Tutorial
From the course: Oracle Database 12c: Basic SQL
Using CONCAT
- [Instructor] String concatenation allows us to chain multiple strings together, that is, combine the values of multiple varchar data types or string retrieved by a SQL query into one longer string value. Let's see an example. We'll start by selecting the first name and last name values from our employees table. We can concatenate or combine the values of first name and last name so that instead of the SQL query returning name in two distinctly different columns, which is how the data is stored in the table, the SQL query can return them as one concatenated string. We simply do that by adding concat, which is the name of the function, and then inside brackets, specify the two column values we want to combine together or concatenate together. Running this query, we see that we got a combined output of both columns. We can also use concat and combine a literal string with the value retrieved from a database column. So for…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
Introduction to functions1m 39s
-
(Locked)
Using SUBSTRING, LENGTH, and CONCAT2m 50s
-
(Locked)
Using LENGTH1m 4s
-
(Locked)
Using CONCAT4m 48s
-
(Locked)
Using LOWER and UPPER2m 44s
-
(Locked)
Using INSTR4m 32s
-
(Locked)
Using RPAD and LPAD3m 31s
-
(Locked)
Using TO_CHAR to convert numbers1m 34s
-
(Locked)
Using TO_CHAR to format DATE values2m 59s
-
(Locked)
Using TO_CHAR to filter DATE values1m 57s
-
(Locked)
The special Oracle DUAL table1m 18s
-
(Locked)
Using ROUND1m 15s
-
(Locked)
Using TRUNC1m 36s
-
(Locked)
Using SYSDATE1m 59s
-
(Locked)
Using SYSTIMESTAMP1m 37s
-
(Locked)
Using MONTHS_BETWEEN3m 2s
-
(Locked)
Using ADD_MONTHS1m 17s
-
-
-
-
-
-