ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
tip   SiteMap shows list of All Categories in this site.
Google
 
Categories >> Software >> Microsoft-Related
 
  Visual-Basic (584)  C-Sharp (457)  ASP.NET (949)  VB.NET (89)  COM+ (37)
  ADO.NET (151)  IIS (61)  MTS (2)  Crystal-Reports (41)  BizTalk (14)
  Exchange-Server (61)  Microsoft-Related-AllOther (26)
 


 

Back to Questions Page
 
Question
what is Option Implicit
Rank Answer Posted By  
 Question Submitted By :: Avinash
This Interview Question Asked @   Primus-Global , Cognizent
I also faced this Question!!   © ALL Interview .com
Answer
not sure
when we declare variable in procedure or function
 
0
Govind
 
 
Answer
Never heared of Option Implicit.
Though Setting Option Explicit "ON" requires declaration of 
variable before that variable can be used.
 
0
Guest
 
 
Answer
Instance of specific copy of a class with its own settings 
for the properties defined in that class. Note: The 
implicity defined variable is never equal to nothing. 
 
1
Senthilg
 
 
 
Answer
Option Explicit has 2 values ON and OFF
deafult value is ON
-Option Explicit means - All the variables should be 
declared before its use.
Else it shows error..it is a good practice to use this..
 
3
Anna
 
 
Answer
Option Explicit is set to On, to declare the variable 
compulsarily.
if u set it to off, the user who is going to read your 
coding won't find it easy to know what type of variable it 
stores. i.e int, float, string, var, etc.,
 
0
Dhanasekar
 
 
Answer
can i able to change my vb6 form style
 
0
Dinesh
 
 
Answer
Option Explicit means - All the variables should be 
declared before its use.
Else it shows error
 
0
Rupa
 
 
Question
What is @@rowcount and with small code snippet explain the 
usage?
Rank Answer Posted By  
 Question Submitted By :: Guest
This Interview Question Asked @   BirlaSoft
I also faced this Question!!   © ALL Interview .com
Answer
@@rowcount gives the number of rows given as an result of 
previous query ran.

Create  procedure get_emp_count ( @emp_id int)
As
Select * from emp where emp_id =@emp_id

If @@rowcount = 0
Begin 
Select 'no rows with emp_id= '
Select @emp_id
End
 
0
Guest
 
 
Answer
@@ROWCOUNT:

Returns the number of rows affected by the last statement.


ex:

UPDATE authors SET au_lname = 'Jones'
WHERE au_id = '999-888-7777'
IF @@ROWCOUNT = 0
print 'Warning: No rows were updated'
 
0
Jagan
 
 
Answer
@@ROWCOUNT:

Returns the number of rows affected by the last statement.


ex:

UPDATE authors SET au_lname = 'Jones'
WHERE au_id = '999-888-7777'
IF @@ROWCOUNT = 0
print 'Warning: No rows were updated'
 
2
Jagan
 
 
Answer
What are the properties of the Relational tables?
Relational tables have six properties:

Values are atomic. 
Column values are of the same kind. 
Each row is unique. 
The sequence of columns is insignificant. 
The sequence of rows is insignificant. 
Each column must have a unique name. 
What is De-normalization?
De-normalization is the process of attempting to optimize 
the performance of a database by adding redundant data. It 
is sometimes necessary because current DBMSs implement the 
relational model poorly. A true relational DBMS would allow 
for a fully normalized database at the logical level, while 
providing physical storage of data that is tuned for high 
performance. De-normalization is a technique to move from 
higher to lower normal forms of database modeling in order 
to speed up database access.

How to get @@error and @@rowcount at the same time?
If @@Rowcount is checked after Error checking statement 
then it will have 0 as the value of @@Recordcount as it 
would have been reset.
And if @@Recordcount is checked before the error-checking 
statement then @@Error would get reset. To get @@error and 
@@rowcount at the same time do both in same statement and 
store them in local variable. SELECT @RC = @@ROWCOUNT, @ER 
= @@ERROR

What is Identity?
Identity (or AutoNumber) is a column that automatically 
generates numeric values. A start and increment value can 
be set, but most DBA leave these at 1. A GUID column also 
generates numbers, the value of this cannot be controled. 
Identity/GUID columns do not need to be indexed.

What is a Scheduled Jobs or What is a Scheduled Tasks? 
Scheduled tasks let user automate processes that run on 
regular or predictable cycles. User can schedule 
administrative tasks, such as cube processing, to run 
during times of slow business activity. User can also 
determine the order in which tasks run by creating job 
steps within a SQL Server Agent job. E.g. Back up database, 
Update Stats of Tables. Job steps give user control over 
flow of execution. If one job fails, user can configure SQL 
Server Agent to continue to run the remaining tasks or to 
stop execution.

What is a table called, if it does not have neither Cluster 
nor Non-cluster Index? What is it used for?
Unindexed table or Heap. Microsoft Press Books and Book On 
Line (BOL) refers it as Heap.
A heap is a table that does not have a clustered index and, 
therefore, the pages are not linked by pointers. The IAM 
pages are the only structures that link the pages in a 
table together.
Unindexed tables are good for fast storing of data. Many 
times it is better to drop all indexes from table and than 
do bulk of inserts and to restore those indexes after that.

What is BCP? When does it used? 
BulkCopy is a tool used to copy huge amount of data from 
tables and views. BCP does not copy the structures same as 
source to destination.

How do you load large data to the SQL server database?
BulkCopy is a tool used to copy huge amount of data from 
tables. BULK INSERT command helps to Imports a data file 
into a database table or view in a user-specified format.

Can we rewrite subqueries into simple select statements or 
with joins? 
Subqueries can often be re-written to use a standard outer 
join, resulting in faster performance. As we may know, an 
outer join uses the plus sign (+) operator to tell the 
database to return all non-matching rows with NULL values. 
Hence we combine the outer join with a NULL test in the 
WHERE clause to reproduce the result set without using a 
sub-query.

Can SQL Servers linked to other servers like Oracle?
SQL Server can be lined to any server provided it has OLE-
DB provider from Microsoft to allow a link. E.g. Oracle has 
a OLE-DB provider for oracle that Microsoft provides to add 
it as linked server to SQL Server group.

How to know which index a table is using? 
SELECT table_name,index_name FROM user_constraints

How to copy the tables, schema and views from one SQL 
server to another?
Microsoft SQL Server 2000 Data Transformation Services 
(DTS) is a set of graphical tools and programmable objects 
that lets user extract, transform, and consolidate data 
from disparate sources into single or multiple destinations.

What is Self Join?
This is a particular case when one table joins to itself, 
with one or two aliases to avoid confusion. A self join can 
be of any type, as long as the joined tables are the same. 
A self join is rather unique in that it involves a 
relationship with only one table. The common example is 
when company have a hierarchal reporting structure whereby 
one member of staff reports to another.

What is Cross Join?
A cross join that does not have a WHERE clause produces the 
Cartesian product of the tables involved in the join. The 
size of a Cartesian product result set is the number of 
rows in the first table multiplied by the number of rows in 
the second table. The common example is when company wants 
to combine each product with a pricing table to analyze 
each product at each price.

Which virtual table does a trigger use?
Inserted and Deleted.

List few advantages of Stored Procedure.

Stored procedure can reduced network traffic and latency, 
boosting application performance. 
Stored procedure execution plans can be reused, staying 
cached in SQL Server’s memory, reducing server overhead. 
Stored procedures help promote code reuse. 
Stored procedures can encapsulate logic. You can change 
stored procedure code without affecting clients. 
Stored procedures provide better security to your data. 
What is DataWarehousing?

Subject-oriented, meaning that the data in the database is 
organized so that all the data elements relating to the 
same real-world event or object are linked together; 
Time-variant, meaning that the changes to the data in the 
database are tracked and recorded so that reports can be 
produced showing changes over time; 
Non-volatile, meaning that data in the database is never 
over-written or deleted, once committed, the data is 
static, read-only, but retained for future reporting; 
Integrated, meaning that the database contains data from 
most or all of an organization’s operational applications, 
and that this data is made consistent. 
What is OLTP(OnLine Transaction Processing)?
In OLTP - online transaction processing systems relational 
database design use the discipline of data modeling and 
generally follow the Codd rules of data normalization in 
order to ensure absolute data integrity. Using these rules 
complex information is broken down into its most simple 
structures (a table) where all of the individual atomic 
level elements relate to each other and satisfy the 
normalization rules.

How do SQL server 2000 and XML linked? Can XML be used to 
access data?
FOR XML (ROW, AUTO, EXPLICIT)
You can execute SQL queries against existing relational 
databases to return results as XML rather than standard 
rowsets. These queries can be executed directly or from 
within stored procedures. To retrieve XML results, use the 
FOR XML clause of the SELECT statement and specify an XML 
mode of RAW, AUTO, or EXPLICIT.

OPENXML
OPENXML is a Transact-SQL keyword that provides a 
relational/rowset view over an in-memory XML document. 
OPENXML is a rowset provider similar to a table or a view. 
OPENXML provides a way to access XML data within the 
Transact-SQL context by transferring data from an XML 
document into the relational tables. Thus, OPENXML allows 
you to manage an XML document and its interaction with the 
relational environment.

What is an execution plan? When would you use it? How would 
you view the execution plan?
An execution plan is basically a road map that graphically 
or textually shows the data retrieval methods chosen by the 
SQL Server query optimizer for a stored procedure or ad-hoc 
query and is a very useful tool for a developer to 
understand the performance characteristics of a query or 
stored procedure since the plan is the one that SQL Server 
will place in its cache and use to execute the stored 
procedure or query. From within Query Analyzer is an option 
called “Show Execution Plan” (located on the Query drop-
down menu). If this option is turned on it will display 
query execution plan in separate window when query is ran 
again.
 
0
Guest
 
 
Question
We have 2 sites in which one site allows the user with out 
asking credentials and second one ask for credentials 
through a log page. What might be the configurations 
settings for both sites? We can use IIS and web.config 
files together.
Rank Answer Posted By  
 Question Submitted By :: Guest
This Interview Question Asked @   ADITI
I also faced this Question!!   © ALL Interview .com
Answer
First one using windows authentication as follows.

Set Windows authentication in IIS.
And in web.config 
<authorization>
	<deny users=”?”/>
</authorization>

For the second one.
We set IIS authentication as none. And in web.config file 
we mention as follow.

<authentication mode=”forms”>
<forms login=”login.aspx”/>
</authentication>
<authorization>
<deny user=”?”/>
<authorization>
 
0
Guest
 
 
Question
Can we have a non static member function in a base class to 
be override in derived with static modifier?
Rank Answer Posted By  
 Question Submitted By :: Guest
This Interview Question Asked @   Wipro
I also faced this Question!!   © ALL Interview .com
Answer
No.
A Static member can not be declared override, virtual, 
abstract.
 
0
Guest
 
 
Answer
No, we cannot derive static class from a user defined 
class. They can only be derived from object class.
 
0
Parmjit
 
 
Answer
yes we can have a nonstatic membe function in the base , 
which can be override in derived class with static modiier.

for ex:
class sample
{
        public:
        static void get(){cout<<"this is base class 
function:"<<endl;}
        static void put(){cout<<"this is a put function of 
base class :"<<endl;}
};
class sample1:public sample
{
        public:
        void put(){cout<<"this is a derived class 
function:"<<endl;}
};
sample class is havinfg a non static member function put 
which is overidden in dervied which static key word.

Which runs fine.
 
0
Srinivas
 
 
Answer
sorry i have given the reverse once . Even the reverse 
works fine..

class sample
{
        public:
        static void get(){cout<<"this is base class 
function:"<<endl;}
        void put(){cout<<"this is a put function of base 
class :"<<endl;}
};
class sample1:public sample
{
        public:
        static void put(){cout<<"this is a derived class 
function:"<<endl;}
};
 
0
Srinivas
 
 
Answer
No We cant ovver ride static member function in a base 
class.
 
0
Sanjay
 
 
Question
What is the Difference between read only and constant 
variables?
Rank Answer Posted By  
 Question Submitted By :: Guest
This Interview Question Asked @   SilverKey
I also faced this Question!!   © ALL Interview .com
Answer
Read only variable can be assigned a value at the runtime. 
Where as const have to be assigned at the compile time only.
 
0
Guest
 
 
Answer
We can assign a value to a readonly variable at runtime 
till it is a unassined identifier, but once value is 
assigned, it cannot be changed.

In case of const we cannot assign a value at run time i.e. 
the value assigned to it at declaration time cannot be 
change
 
0
Parmjit
 
 
Answer
Readonly variable can be assigned in run time but constant
variables cnt assign at run time.constant variables is
assigned at compile time only
 
0
Pankaj
 
 
Answer
The difference between the readonly and const data members 
is that const requires you to initialize with the 
declaration, that is directly
 
0
Zia Khan
 
 
Answer
all above answers are correct.But there is another point.

readonly variable can be assigned at declaration or at run 
time which is must be in constructor. Readonly value can't 
be modified.

Constant variable must be assigned at the time of 
declaration only ,which is can't be modified.
 
0
Kishore Maddineni
 
 
Question
how barcode create in the report
Rank Answer Posted By  
 Question Submitted By :: Amarkavi
This Interview Question Asked @   Wipro
I also faced this Question!!   © ALL Interview .com
Answer
Its very easy. 
1-Take a barcode font like we used Arial, Time new Roman
2-Install this font at window fonts directory
3-Use Steric (*) at both ends of a field of Report with the 
help of double/single commas 
4.Change this field Font Like from Time new roman to 
Barcode font
e.g Bar is field that contain digit from 1 to 8 as shown 
below
  *12345678*
After changing font these digit were converted into Black 
Lines mean barcode
|||||||||||||||

5-Take print of barcode and enjoy.

If you feel any problem then email me at 
salmansahb@hotmail.com and i will furhter send you font or 
report.
 
0
Muhammad Sulman Saeed
 
 
Question
How insert recored in the database
Rank Answer Posted By  
 Question Submitted By :: Amarkavi
This Interview Question Asked @   Wipro
I also faced this Question!!   © ALL Interview .com
Answer
insert into <tablename> values (Parm1,parm2....)
 
0
Sesu
 
 
 
Back to Questions Page
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us interview questions urls   External Links 
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com