Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Query to search for a particular value in any column of any table inside a Oracle database

User_SXX8IJun 15 2020 — edited Jun 18 2020

Hi Team,

I need to search a value say "NIK" in all tables of a database.

Let suppose we have two tables:

TAB1

  

SL NoNameEmp No
1ABC123
2XYZ111
3NIK245

TAB2

SL NoUsernameUser ID
1DEF231
2NIK235
3LMN124

So I need a query where if a search a string say "NIK", then it should display output as

  

Table NameColumn NameValue
TAB1NameNIK
TAB2UsernameNIK

Please help in getting the SQL query.

My database version is Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit .

Comments
Post Details
Added on Jun 15 2020
4 comments
6,310 views