Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write an anonymous PL/SQL block that takes the contents of a text variable (e.g. VARCHAR2) and performs the following modifications to it: 1) Remove all

Write an anonymous PL/SQL block that takes the contents of a text variable

(e.g. VARCHAR2) and performs the following modifications to it:

1) Remove all characters that are not a letter

(e.g. A-Z or a-z) abcd123efg-^%. would be converted to abcdefg

2) Reverse the order of the remaining characters abcdefg would be converted to gfedcba

3) Capitalize every other letter starting with the 1st one gfedcba would be converted to GfEdCbA

Display the original and converted contents in the variable as shown below. Original -> abc123efg-^%.

Converted -> GfDcBa Also, be sure to look at the built-in Oracle functions to see if something exists (e.g. SUBSTR(), LENGTH(), etc) before coding your solution.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

PostgreSQL Up And Running A Practical Guide To The Advanced Open Source Database

Authors: Regina Obe, Leo Hsu

3rd Edition

1491963417, 978-1491963418

More Books

Students also viewed these Databases questions