Suppose I have to create a view on a table, that is not yet been
created by DBA. I khow the table structure. Is it possible to
create the view before DBA creates this table? If yes then how?
Is it possible to create synonym in this way?
Answers were Sorted based on User's Feedback
Answer / monika
Yes, we can create a view on a table that really doesn't
exist yet.We can do this by putting a word (Force) in
create view command-
create force view v1 as
select * from emp;
here view gets created but its staus is invalid,its become
valid when we create table emp(table on which view is
defined).
| Is This Answer Correct ? | 44 Yes | 2 No |
Answer / anitha
It is true that the force option can be used to create the
view. But, this view will remain invalid even after the
creation the the Table. It needs to be recompiled again.
| Is This Answer Correct ? | 6 Yes | 1 No |
Answer / ram
i cannot create a view unless the DBA gives me create view system privilege and to create a view in any schema, rather than just your own we need the create view privilege and be granted the select,insert,update and delete objects on table underlying the view.
synonym is the alias to database object and to hide details of source of the database object. a public synonym is created by the DBA and is available for use by any database user. a private synonym is defined in the schema by the user and is available to the user.
| Is This Answer Correct ? | 3 Yes | 3 No |
Answer / neo
Synonym can be created on non-existing table without using
Force keyword. It automatically become valid once table is
created.
| Is This Answer Correct ? | 1 Yes | 1 No |
What are the types of operators available in sql?
What are Anti joins
What is foreign key and example?
What are the different operators available in sql?
What are local and global Indexes and where they are useful.
What is the usage of when clause in trigger?
I have a procedure in a procedure. The inner procedure contains out parameter. How I can call the inner procedure in the out procedure and send the inner procedure parameter value(out parameter value) into out procedure?
Explain scalar functions in sql?
What is scalar data type in pl sql?
what is difference between procedure and function, procedure and trigger?
Is left join same as inner join?
How to rename a table?
Oracle (3259)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)