|
|
Archives of the TeradataForum
Message Posted: Fri, 30 Sep 2011 @ 11:30:17 GMT
Subj: | | Re: How to Fetch tables from Database with different suffixes |
|
From: | | Mankala, Mahesh |
Sravan...
Please try this below one.
select substring((trim(tablename)) from character(trim(tablename))-3 for 4)
,tablename
,databasename
from dbc.tables
where upper ((substring((trim(tablename)) from character(trim(tablename))-3 for 4)))
= lower((substring((trim(tablename)) from character(trim(tablename))-3 for 4))) (casespecific)
and databasename='XXXX'
Thanks,
Mahesh Mankala
| |