Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How to count the no of records of a table without using
COUNT function?

Answer Posted / ramaprasad

select rownum from emp;
select max(rownum) from emp;

declare
cursor c1(dpno emp.deptno%type)is select * from emp where
deptno=dpno;
i c1%rowtype;
begin
open c1(dpno);
loop
fetch c1 into i ;
exit when c1%notfound;
dbms_output.put_line(c1%rowcount);
end loop;
close c1;
end;

Is This Answer Correct ?    1 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what are the different type of normalization? : Sql dba

1022


Which join is default?

944


What are database links used for?

1035


What is the difference between cluster and non-cluster index?

1099


What is function and procedure?

1023


explain about mysql and its features. : Sql dba

1008


What is multiple columns?

1054


What is an alias command?

1052


Are there any features that are decommissioned in 11g that are not present in 11g?

2136


How to use sql*plus built-in timers?

1178


Define union, minus, union all, intersect ?

996


Can we declare a column having number data type and its scale is larger than pricesionex: column_name number(10,100),column_name numbaer(10,-84)

944


What are some emotional triggers?

972


discuss about myisam index statistics collection. : Sql dba

939


What is sql lookup?

910