-
Fetching records from attributes
How will you fetch records having underscore ( _ ) in the middle of of strings, from columns having attributes as "amit_6", "t_mit06", "am_06", "m_t", "j_x_t" ?
-
Table Name Alias
Why do we use alias for the table name? What is its importance?
-
What will be the output of the following query?
SELECT REPLACE(TRANSLATE(LTRIM(RTRIM('!! ATHEN !!','!'), '!'), 'AN', '**'),'*','TROUBLE') FROM DUAL;TROUBLETHETROUBLE
-
What command is used to create a table by copying the structure of another table?
Answer :CREATE TABLE .. AS SELECT commandExplanation : To copy only the structure, the WHERE clause of the SELECT command should contain a FALSE statement as in the following.CREATE TABLE NEWTABLE AS SELECT * FROM EXISTINGTABLE WHERE 1=2;If the WHERE condition is true, then all the rows or rows satisfying the condition will be copied to the new table.
-
What are the wildcards used for pattern matching?
_ for single character substitution and % for multi-character substitution