Search:

Type: Posts; User: chaitueeturi; Keyword(s):

Search: Search took 0.02 seconds.

  1. Thread: sql query

    by chaitueeturi
    Answers
    3
    Views
    2,488

    SQL Re: sql query

    You have to use oracle9i

    Try this,Sure it will work

    Select * from tablename
    group by rollup(id);
  2. Answers
    20
    Views
    26,878

    SQL Re: Insert new column in the middle of a table

    That is not possible in oracle.But u can try the following

    Just u create a view on that particular table and keep the order of the columns in your view as you required.And use that view when ever...
  3. SQL Re: How to update more than one row with a different value

    try below one
    considering emp s reference table,if deptno of type varchar

    update emp
    set deptno=decode(deptno,10,20,20,30,30);
  4. Answers
    5
    Views
    5,626

    SQL Re: Updating a View

    generally a view will be stored as a statament in database.
    If u want retrieve data using this view,then it replaces the view with a select statement and it will be executed on the tables on which u...
  5. Answers
    8
    Views
    4,038

    SQL Re: How to alter a type in SQL

    if we wnt to change a column defintion first store all the data in that column to some where and set all the values to be modified in that column to null and then follo below mentioned

    sql> Alter...
  6. SQL Re: Details of emp having the 788th highest salary

    try this

    select * from emp
    where (select count(distinct sal) from emp s
    where s.sal>=m.sal)+1=788;
  7. SQL Re: How to update more than one row with a different value

    not sure but try below one
    considering emp s reference table,if deptno of type varchar

    update emp
    set deptno=decode(deptno,10,'ten',20,'twenty','thirty');
  8. Answers
    6
    Views
    6,592

    SQL Re: Finding Error in PL/SQL Code

    use the below one after executing pl/sql block

    sql> show errors

    it displays errors along with line numbers
  9. Answers
    5
    Views
    3,654

    SQL Re: Which trigger will fires first?

    the recently created trigger will be fired first

    suppose u created trigger t1 and then t2 for the same instant
    here t2 will be fired first and then t1
  10. Thread: Grant

    by chaitueeturi
    Answers
    5
    Views
    2,745

    SQL Re: Grant

    There are 3 types of roles to grant privileges depending upon requirement
    1.Resource
    2.Connect
    3.DBA

    Among these DBA cotains all the privileges,try the following one


    sql> Grant DBA to...
  11. Answers
    5
    Views
    19,224

    SQL Re: GROUP_BY and HAVING clause in SQL

    Having clause can occur without groupby clause.But the entire records in the table are considerd as single group and we can get the corresponding o/p

    observe this eg:

    select sum(sal) from emp...
  12. Answers
    8
    Views
    4,396

    SQL Re: what is trigger

    it is in object in database which is automatically executed at the specified event.
    3 types triggers are there
    DML triggers
    DDL triggers
    Database triggers
  13. SQL Re: Extract the table name by using its column name

    just give a name to constraint and try this it will work



    select table_name from user_constraints
    where constraint_name='<constraintname>';
  14. SQL Re: Difference between VIEWS and SELECT statements

    we know views are stored as select statement in database
    these are mainly useful to provide security to the data and to control the n/w traffic.
    in realtime views play the major role
  15. Answers
    10
    Views
    4,605

    SQL Re: Give me the queries for.....

    1.select * from emp m
    where (select count(distinct sal) rank from emp s
    where s.sal>m.sal)+1=22;


    2.delete from emp
    where empno=(select empno from (select rownum rn,emp.* from emp)...
  16. Answers
    4
    Views
    2,340

    SQL Re: Retrieve after roll back

    if we have performed a DML operation either we have to use commit or we have to perform DDL operation else the changes can not be made in database.It appears to u that is there but others clients can...
  17. Answers
    2
    Views
    2,187

    SQL Re: Is DML statements are cursors?

    There are some cursor attributes.If we state any DML statement inide a pl/sql block,implicitely a cursor sql%rowcount will be created which consists of the records satifying the DML statement,and DML...
  18. Answers
    5
    Views
    3,368

    SQL Re: fetch rows fastly

    if we define a unique or primary key on a column in a table automatically a unique index will be created.No need to define manually.
  19. Answers
    3
    Views
    2,293

    SQL Re: Column for Primary Key

    emp_id and acc_id should be unique and should not be null.so the requirement of primary key arises.if this table does not need any child records
    we can define primary key on either of the columns.if...
  20. Answers
    2
    Views
    2,085

    SQL Re: Inserting column in the middle

    actually no need to rearrange these columns
    if at all u want to do this to my known knowledge this can be done in two steps

    step1:- alter table <oldtablename> add
    ...
  21. Answers
    4
    Views
    2,225

    SQL Re: Concept of inserting NULL

    count syntax is count(<exp>/*)
    if we use count(<exp>) it returns the number of not null values in a group of values
    if we use count(*) it returns the count of values in a group of values

    just...
  22. Answers
    7
    Views
    38,275

    SQL Re: Difference between view and index

    a view is stored as a select statement in database.it provides security for both data and table.That means if we drop view no damage occurs to table.And the n/w traffic can be controlled,because a...
Results 1 to 22 of 24
About us
Applying for a job can be a stressful and frustrating experience, especially for someone who has never done it before. Considering that you are competing for the position with a at least a dozen other applicants, it is imperative that you thoroughly prepare for the job interview, in order to stand a good chance of getting hired. That's where GeekInterview can help.
Interact