<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>PDF Tutorials .com</title>
	<atom:link href="http://www.pdftutorials.com/feed" rel="self" type="application/rss+xml" />
	<link>http://www.pdftutorials.com</link>
	<description>PDF study Materials. Tutorial Downloads, References, Interview Questions and Answers</description>
	<lastBuildDate>Thu, 13 Oct 2011 14:29:50 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>C++ INTERVIEW QUESTIONS</title>
		<link>http://www.pdftutorials.com/questions/c-interview-questions.html</link>
		<comments>http://www.pdftutorials.com/questions/c-interview-questions.html#comments</comments>
		<pubDate>Thu, 13 Oct 2011 13:41:16 +0000</pubDate>
		<dc:creator>Tutorial Master</dc:creator>
				<category><![CDATA[questions]]></category>

		<guid isPermaLink="false">http://www.pdftutorials.com/test/?p=3867</guid>
		<description><![CDATA[What is encapsulation?? Containing and hiding information about an object, such as internal data structures and code. Encapsulation isolates the internal complexity of an object&#8217;s operation from the rest of the application. For example, a client component asking for net revenue from a business object need not know the data&#8217;s origin. What is inheritance? Inheritance <a href="http://www.pdftutorials.com/questions/c-interview-questions.html"> read more <span class="meta-nav">&#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p>What is encapsulation??<br />
Containing and hiding information about an object, such as internal data structures and<br />
code. Encapsulation isolates the internal complexity of an object&#8217;s operation from the rest<br />
of the application. For example, a client component asking for net revenue from a business<br />
object need not know the data&#8217;s origin.</p>
<p>What is inheritance?<br />
Inheritance allows one class to reuse the state and behavior of another class. The derived<br />
class inherits the properties and method implementations of the base class and extends it by<br />
overriding methods and adding additional properties and methods.<br />
What is Polymorphism??</p>
<p>Polymorphism allows a client to treat different objects in the same way even if they were<br />
created from different classes and exhibit different behaviors. You can use implementation<br />
inheritance to achieve polymorphism in languages such as C++ and Java. Base class object&#8217;s<br />
pointer can invoke methods in derived class objects. You can also achieve polymorphism in<br />
C++ by function overloading and operator overloading.</p>
<p>What is constructor or ctor?</p>
<p>Constructor creates an object and initializes it. It also creates vtable for virtual<br />
functions. It is different from other methods in a class.</p>
<p>What is destructor?<br />
Destructor usually deletes any extra resources allocated by the object.<br />
What is default constructor?<br />
Constructor with no arguments or all the arguments has default values.</p>
<p>What is copy constructor?<br />
Constructor which initializes the it&#8217;s object member variables ( by shallow copying) with<br />
another object of the same class. If you don&#8217;t implement one in your class then compiler<br />
implements one for you.<br />
for example:<br />
Boo Obj1(10); // calling Boo constructor<br />
Boo Obj2(Obj1); // calling boo copy constructor<br />
Boo Obj2 = Obj1;// calling boo copy constructor</p>
<p>When are copy constructors called?<br />
Copy constructors are called in following cases:<br />
a) when a function returns an object of that class by value<br />
b) when the object of that class is passed by value as an argument to a function<br />
c) when you construct an object based on another object of the same class<br />
d) When compiler generates a temporary object</p>
<p>What is assignment operator?<br />
Default assignment operator handles assigning one object to another of the same class.<br />
Member to member copy (shallow copy)</p>
<p>What are all the implicit member functions of the class? Or what are all the functions which<br />
compiler implements for us if we don&#8217;t define one.??<br />
default ctor<br />
copy ctor<br />
assignment operator<br />
default destructor<br />
address operator</p>
<p>What is conversion constructor?<br />
constructor with a single argument makes that constructor as conversion ctor and it can be<br />
used for type conversion.<br />
for example:<br />
class Boo<br />
{<br />
public:<br />
Boo( int i );<br />
};<br />
Boo BooObject = 10 ; // assigning int 10 Boo object</p>
<p>What is conversion operator??<br />
class can have a public method for specific data type conversions.<br />
for example:<br />
class Boo<br />
{<br />
double value;<br />
public:<br />
Boo(int i )<br />
operator double()<br />
{<br />
return value;<br />
}<br />
};<br />
Boo BooObject;<br />
double i = BooObject; // assigning object to variable i of type double. now conversion<br />
operator gets called to assign the value.</p>
<p>What is diff between malloc()/free() and new/delete?<br />
malloc allocates memory for object in heap but doesn&#8217;t invoke object&#8217;s constructor to<br />
initiallize the object.<br />
new allocates memory and also invokes constructor to initialize the object.<br />
malloc() and free() do not support object semantics<br />
Does not construct and destruct objects<br />
string * ptr = (string *)(malloc (sizeof(string)))<br />
Are not safe<br />
Does not calculate the size of the objects that it construct<br />
Returns a pointer to void<br />
int *p = (int *) (malloc(sizeof(int)));<br />
int *p = new int;<br />
Are not extensible<br />
new and delete can be overloaded in a class<br />
&#8220;delete&#8221; first calls the object&#8217;s termination routine (i.e. its destructor) and then<br />
releases the space the object occupied on the heap memory. If an array of objects was<br />
created using new, then delete must be told that it is dealing with an array by preceding<br />
the name with an empty []:-<br />
Int_t *my_ints = new Int_t[10];<br />
&#8230;<br />
delete []my_ints;<br />
What is the diff between &#8220;new&#8221; and &#8220;operator new&#8221; ?</p>
<p>&#8220;operator new&#8221; works like malloc.<br />
What is difference between template and macro??<br />
There is no way for the compiler to verify that the macro parameters are of compatible<br />
types. The macro is expanded without any special type checking.<br />
If macro parameter has a postincremented variable ( like c++ ), the increment is performed<br />
two times.<br />
Because macros are expanded by the preprocessor, compiler error messages will refer to the<br />
expanded macro, rather than the macro definition itself. Also, the macro will show up in<br />
expanded form during debugging.<br />
for example:<br />
Macro:<br />
#define min(i, j) (i &lt; j ? i : j)<br />
template:<br />
template&lt;class T&gt;<br />
T min (T i, T j)<br />
{<br />
return i &lt; j ? i : j;<br />
}<br />
What are C++ storage classes?<br />
auto<br />
register<br />
static<br />
extern<br />
auto: the default. Variables are automatically created and initialized when they are defined<br />
and are destroyed at the end of the block containing their definition. They are not visible<br />
outside that block<br />
register: a type of auto variable. a suggestion to the compiler to use a CPU register for<br />
performance<br />
static: a variable that is known only in the function that contains its definition but is<br />
never destroyed and retains its value between calls to that function. It exists from the<br />
time the program begins execution<br />
extern: a static variable whose definition and placement is determined when all object and<br />
library modules are combined (linked) to form the executable code file. It can be visible<br />
outside the file where it is defined.<br />
What are storage qualifiers in C++ ?<br />
They are..<br />
const<br />
volatile<br />
mutable<br />
Const keyword indicates that memory once initialized, should not be altered by a program.<br />
volatile keyword indicates that the value in the memory location can be altered even though<br />
nothing in the program<br />
code modifies the contents. for example if you have a pointer to hardware location that<br />
contains the time, where hardware changes the value of this pointer variable and not the<br />
program. The intent of this keyword to improve the optimization ability of the compiler.<br />
mutable keyword indicates that particular member of a structure or class can be altered even<br />
if a particular structure variable, class, or class member function is constant.<br />
struct data<br />
{<br />
char name[80];<br />
mutable double salary;<br />
}<br />
const data MyStruct = { &#8220;Satish Shetty&#8221;, 1000 }; //initlized by complier<br />
strcpy ( MyStruct.name, &#8220;Shilpa Shetty&#8221;); // compiler error<br />
MyStruct.salaray = 2000 ; // complier is happy allowed<br />
What is reference ??<br />
reference is a name that acts as an alias, or alternative name, for a previously defined<br />
variable or an object. prepending variable with &#8220;&amp;&#8221; symbol makes it as reference. for<br />
example:<br />
int a;<br />
int &amp;b = a;<br />
What is passing by reference?<br />
Method of passing arguments to a function which takes parameter of type reference. for<br />
example:<br />
void swap( int &amp; x, int &amp; y )<br />
{<br />
int temp = x;<br />
x = y;<br />
y = x;<br />
}<br />
int a=2, b=3;<br />
swap( a, b );<br />
Basically, inside the function there won&#8217;t be any copy of the arguments &#8220;x&#8221; and &#8220;y&#8221; instead<br />
they refer to original variables a and b. so no extra memory needed to pass arguments and it<br />
is more efficient.<br />
When do use &#8220;const&#8221; reference arguments in function?<br />
a) Using const protects you against programming errors that inadvertently alter data.<br />
b) Using const allows function to process both const and non-const actual arguments, while a<br />
function without const in the prototype can only accept non constant arguments.<br />
c) Using a const reference allows the function to generate and use a temporary variable<br />
appropriately.<br />
When are temporary variables created by C++ compiler?<br />
Provided that function parameter is a &#8220;const reference&#8221;, compiler generates temporary<br />
variable in following 2 ways.<br />
a) The actual argument is the correct type, but it isn&#8217;t Lvalue<br />
double Cuberoot ( const double &amp; num )<br />
{<br />
num = num * num * num;<br />
return num;<br />
}<br />
double temp = 2.0;<br />
double value = cuberoot ( 3.0 + temp ); // argument is a expression and not a Lvalue;<br />
b) The actual argument is of the wrong type, but of a type that can be converted to the<br />
correct type<br />
long temp = 3L;<br />
double value = cuberoot ( temp); // long to double conversion<br />
What is virtual function?<br />
When derived class overrides the base class method by redefining the same function, then if<br />
client wants to access redefined the method from derived class through a pointer from base<br />
class object, then you must define this function in base class as virtual function.<br />
class parent<br />
{<br />
void Show()<br />
{<br />
cout &lt;&lt; &#8220;i&#8217;m parent&#8221; &lt;&lt; endl;<br />
}<br />
};<br />
class child: public parent<br />
{<br />
void Show()<br />
{<br />
cout &lt;&lt; &#8220;i&#8217;m child&#8221; &lt;&lt; endl;<br />
}<br />
};<br />
parent * parent_object_ptr = new child;<br />
parent_object_ptr-&gt;show() // calls parent-&gt;show() i<br />
now we goto virtual world&#8230;<br />
class parent<br />
{<br />
virtual void Show()<br />
{<br />
cout &lt;&lt; &#8220;i&#8217;m parent&#8221; &lt;&lt; endl;<br />
}<br />
};<br />
class child: public parent<br />
{<br />
void Show()<br />
{<br />
cout &lt;&lt; &#8220;i&#8217;m child&#8221; &lt;&lt; endl;<br />
}<br />
};<br />
parent * parent_object_ptr = new child;<br />
parent_object_ptr-&gt;show() // calls child-&gt;show()<br />
What is pure virtual function? or what is abstract class?<br />
When you define only function prototype in a base class without and do the complete<br />
implementation in derived class. This base class is called abstract class and client won&#8217;t<br />
able to instantiate an object using this base class.<br />
You can make a pure virtual function or abstract class this way..<br />
class Boo<br />
{<br />
void foo() = 0;<br />
}<br />
Boo MyBoo; // compilation error<br />
What is Memory alignment??<br />
The term alignment primarily means the tendency of an address pointer value to be a multiple<br />
of some power of two. So a pointer with two byte alignment has a zero in the least<br />
significant bit. And a pointer with four byte alignment has a zero in both the two least<br />
significant bits. And so on. More alignment means a longer sequence of zero bits in the<br />
lowest bits of a pointer.<br />
What problem does the namespace feature solve?<br />
Multiple providers of libraries might use common global identifiers causing a name collision<br />
when an application tries to link with two or more such libraries. The namespace feature<br />
surrounds a library&#8217;s external declarations with a unique namespace that eliminates the<br />
potential for those collisions.<br />
namespace [identifier] { namespace-body }<br />
A namespace declaration identifies and assigns a name to a declarative region.<br />
The identifier in a namespace declaration must be unique in the declarative region in which<br />
it is used. The identifier is the name of the namespace and is used to reference its<br />
members.<br />
What is the use of &#8216;using&#8217; declaration?<br />
A using declaration makes it possible to use a name from a namespace without the scope<br />
operator.<br />
What is an Iterator class?<br />
A class that is used to traverse through the objects maintained by a container class. There<br />
are five categories of iterators: input iterators, output iterators, forward iterators,<br />
bidirectional iterators, random access. An iterator is an entity that gives access to the<br />
contents of a container object without violating encapsulation constraints. Access to the<br />
contents is granted on a one-at-a-time basis in order. The order can be storage order (as in<br />
lists and queues) or some arbitrary order (as in array indices) or according to some<br />
ordering relation (as in an ordered binary tree). The iterator is a construct, which<br />
provides an interface that, when called, yields either the next element in the container, or<br />
some value denoting the fact that there are no more elements to examine. Iterators hide the<br />
details of access to and update of the elements of a container class. Something like a<br />
pointer.<br />
What is a dangling pointer?<br />
A dangling pointer arises when you use the address of an object after its lifetime is over.<br />
This may occur in situations like returning addresses of the automatic variables from a<br />
function or using the address of the memory block after it is freed.<br />
What do you mean by Stack unwinding?<br />
It is a process during exception handling when the destructor is called for all local<br />
objects in the stack between the place where the exception was thrown and where it is<br />
caught.<br />
Name the operators that cannot be overloaded??<br />
sizeof, ., .*, .-&gt;, ::, ?:<br />
What is a container class? What are the types of container classes?<br />
A container class is a class that is used to hold objects in memory or external storage. A<br />
container class acts as a generic holder. A container class has a predefined behavior and a<br />
well-known interface. A container class is a supporting class whose purpose is to hide the<br />
topology used for maintaining the list of objects in memory. When a container class contains<br />
a group of mixed objects, the container is called a heterogeneous container; when the<br />
container is holding a group of objects that are all the same, the container is called a<br />
homogeneous container.<br />
What is inline function??<br />
The __inline keyword tells the compiler to substitute the code within the function<br />
definition for every instance of a function call. However, substitution occurs only at the<br />
compiler&#8217;s discretion. For example, the compiler does not inline a function if its address<br />
is taken or if it is too large to inline.<br />
What is overloading??<br />
With the C++ language, you can overload functions and operators. Overloading is the practice<br />
of supplying more than one definition for a given function name in the same scope.<br />
- Any two functions in a set of overloaded functions must have different argument lists.<br />
- Overloading functions with argument lists of the same types, based on return type alone,<br />
is an error.<br />
What is Overriding?<br />
To override a method, a subclass of the class that originally declared the method must<br />
declare a method with the same name, return type (or a subclass of that return type), and<br />
same parameter list.<br />
The definition of the method overriding is:<br />
• Must have same method name.<br />
• Must have same data type.<br />
• Must have same argument list.<br />
Overriding a method means that replacing a method functionality in child class. To imply<br />
overriding functionality we need parent and child classes. In the child class you define the<br />
same method signature as one defined in the parent class.<br />
What is &#8220;this&#8221; pointer?<br />
The this pointer is a pointer accessible only within the member functions of a class,<br />
struct, or union type. It points to the object for which the member function is called.<br />
Static member functions do not have a this pointer.<br />
When a nonstatic member function is called for an object, the address of the object is<br />
passed as a hidden argument to the function. For example, the following function call<br />
myDate.setMonth( 3 );<br />
can be interpreted this way:<br />
setMonth( &amp;myDate, 3 );<br />
The object&#8217;s address is available from within the member function as the this pointer. It is<br />
legal, though unnecessary, to use the this pointer when referring to members of the class.<br />
What happens when you make call &#8220;delete this;&#8221; ??<br />
The code has two built-in pitfalls. First, if it executes in a member function for an<br />
extern, static, or automatic object, the program will probably crash as soon as the delete<br />
statement executes. There is no portable way for an object to tell that it was instantiated<br />
on the heap, so the class cannot assert that its object is properly instantiated. Second,<br />
when an object commits suicide this way, the using program might not know about its demise.<br />
As far as the instantiating program is concerned, the object remains in scope and continues<br />
to exist even though the object did itself in. Subsequent dereferencing of the pointer can<br />
and usually does lead to disaster.<br />
You should never do this. Since compiler does not know whether the object was allocated on<br />
the stack or on the heap, &#8220;delete this&#8221; could cause a disaster.<br />
How virtual functions are implemented C++?<br />
Virtual functions are implemented using a table of function pointers, called the vtable.<br />
There is one entry in the table per virtual function in the class. This table is created by<br />
the constructor of the class. When a derived class is constructed, its base class is<br />
constructed first which creates the vtable. If the derived class overrides any of the base<br />
classes virtual functions, those entries in the vtable are overwritten by the derived class<br />
constructor. This is why you should never call virtual functions from a constructor: because<br />
the vtable entries for the object may not have been set up by the derived class constructor<br />
yet, so you might end up calling base class implementations of those virtual functions<br />
What is name mangling in C++??<br />
The process of encoding the parameter types with the function/method name into a unique name<br />
is called name mangling. The inverse process is called demangling.<br />
For example Foo::bar(int, long) const is mangled as `bar__C3Fooil&#8217;.<br />
For a constructor, the method name is left out. That is Foo::Foo(int, long) const is mangled<br />
as `__C3Fooil&#8217;.<br />
What is the difference between a pointer and a reference?<br />
A reference must always refer to some object and, therefore, must always be initialized;<br />
pointers do not have such restrictions. A pointer can be reassigned to point to different<br />
objects while a reference always refers to an object with which it was initialized.<br />
How are prefix and postfix versions of operator++() differentiated?<br />
The postfix version of operator++() has a dummy parameter of type int. The prefix version<br />
does not have dummy parameter.<br />
What is the difference between const char *myPointer and char *const myPointer?<br />
Const char *myPointer is a non constant pointer to constant data; while char *const<br />
myPointer is a constant pointer to non constant data.<br />
How can I handle a constructor that fails?<br />
throw an exception. Constructors don&#8217;t have a return type, so it&#8217;s not possible to use<br />
return codes. The best way to signal constructor failure is therefore to throw an exception.<br />
How can I handle a destructor that fails?<br />
Write a message to a log-file. But do not throw an exception.<br />
The C++ rule is that you must never throw an exception from a destructor that is being<br />
called during the &#8220;stack unwinding&#8221; process of another exception. For example, if someone<br />
says throw Foo(), the stack will be unwound so all the stack frames between the throw Foo()<br />
and the } catch (Foo e) { will get popped. This is called stack unwinding.<br />
During stack unwinding, all the local objects in all those stack frames are destructed. If<br />
one of those destructors throws an exception (say it throws a Bar object), the C++ runtime<br />
system is in a no-win situation: should it ignore the Bar and end up in the } catch (Foo e)<br />
{ where it was originally headed? Should it ignore the Foo and look for a } catch (Bar e) {<br />
handler? There is no good answer &#8212; either choice loses information.<br />
So the C++ language guarantees that it will call terminate() at this point, and terminate()<br />
kills the process. Bang you&#8217;re dead.<br />
What is Virtual Destructor?<br />
Using virtual destructors, you can destroy objects without knowing their type &#8211; the correct<br />
destructor for the object is invoked using the virtual function mechanism. Note that<br />
destructors can also be declared as pure virtual functions for abstract classes.<br />
if someone will derive from your class, and if someone will say &#8220;new Derived&#8221;, where<br />
&#8220;Derived&#8221; is derived from your class, and if someone will say delete p, where the actual<br />
object&#8217;s type is &#8220;Derived&#8221; but the pointer p&#8217;s type is your class.<br />
Can you think of a situation where your program would crash without reaching the breakpoint<br />
which you set at the beginning of main()?<br />
C++ allows for dynamic initialization of global variables before main() is invoked. It is<br />
possible that initialization of global will invoke some function. If this function crashes<br />
the crash will occur before main() is entered.<br />
Name two cases where you MUST use initialization list as opposed to assignment in<br />
constructors.<br />
Both non-static const data members and reference data members cannot be assigned values;<br />
instead, you should use initialization list to initialize them.<br />
Can you overload a function based only on whether a parameter is a value or a reference?<br />
No. Passing by value and by reference looks identical to the caller.<br />
What are the differences between a C++ struct and C++ class?<br />
The default member and base class access specifiers are different.<br />
The C++ struct has all the features of the class. The only differences are that a struct<br />
defaults to public member access and public base class inheritance, and a class defaults to<br />
the private access specifier and private base class inheritance.<br />
What does extern &#8220;C&#8221; int func(int *, Foo) accomplish?<br />
It will turn off &#8220;name mangling&#8221; for func so that one can link to code compiled by a C<br />
compiler.<br />
How do you access the static member of a class?<br />
&lt;ClassName&gt;::&lt;StaticMemberName&gt;<br />
What is multiple inheritance(virtual inheritance)? What are its advantages and<br />
disadvantages?<br />
Multiple Inheritance is the process whereby a child can be derived from more than one parent<br />
class. The advantage of multiple inheritance is that it allows a class to inherit the<br />
functionality of more than one base class thus allowing for modeling of complex<br />
relationships. The disadvantage of multiple inheritance is that it can lead to a lot of<br />
confusion(ambiguity) when two base classes implement a method with the same name.<br />
What are the access privileges in C++? What is the default access level?<br />
The access privileges in C++ are private, public and protected. The default access level<br />
assigned to members of a class is private. Private members of a class are accessible only<br />
within the class and by friends of the class. Protected members are accessible by the class<br />
itself and it&#8217;s sub-classes. Public members of a class can be accessed by anyone.<br />
What is a nested class? Why can it be useful?<br />
A nested class is a class enclosed within the scope of another class. For example:<br />
// Example 1: Nested class<br />
//<br />
class OuterClass<br />
{<br />
class NestedClass<br />
{<br />
// &#8230;<br />
};<br />
// &#8230;<br />
};<br />
Nested classes are useful for organizing code and controlling access and dependencies.<br />
Nested classes obey access rules just like other parts of a class do; so, in Example 1, if<br />
NestedClass is public then any code can name it as OuterClass::NestedClass. Often nested<br />
classes contain private implementation details, and are therefore made private; in Example<br />
1, if NestedClass is private, then only OuterClass&#8217;s members and friends can use<br />
NestedClass.<br />
When you instantiate as outer class, it won&#8217;t instantiate inside class.<br />
What is a local class? Why can it be useful?<br />
local class is a class defined within the scope of a function &#8212; any function, whether a<br />
member function or a free function. For example:<br />
// Example 2: Local class<br />
//<br />
int f()<br />
{<br />
class LocalClass<br />
{<br />
// &#8230;<br />
};<br />
// &#8230;<br />
};<br />
Like nested classes, local classes can be a useful tool for managing code dependencies.<br />
Can a copy constructor accept an object of the same class as parameter, instead of reference<br />
of the object?<br />
No. It is specified in the definition of the copy constructor itself. It should generate an<br />
error if a programmer specifies a copy constructor with a first argument that is an object<br />
and not a reference.<br />
(From Microsoft) Assume I have a linked list contains all of the alphabets from ‘A’ to ‘Z’.<br />
I want to find the letter ‘Q’ in the list, how does you perform the search to find the ‘Q’?<br />
How do you write a function that can reverse a linked-list? (Cisco System)<br />
void reverselist(void)<br />
{<br />
if(head==0)<br />
return;<br />
if(head-&gt;next==0)<br />
return;<br />
if(head-&gt;next==tail)<br />
{<br />
head-&gt;next = 0;<br />
tail-&gt;next = head;<br />
}<br />
else<br />
{<br />
node* pre = head;<br />
node* cur = head-&gt;next;<br />
node* curnext = cur-&gt;next;<br />
head-&gt;next = 0;<br />
cur-&gt;next = head;<br />
for(; curnext!=0; )<br />
{<br />
cur-&gt;next = pre;<br />
pre = cur;<br />
cur = curnext;<br />
curnext = curnext-&gt;next;<br />
}<br />
curnext-&gt;next = cur;<br />
}<br />
}<br />
How do you find out if a linked-list has an end? (i.e. the list is not a cycle)<br />
You can find out by using 2 pointers. One of them goes 2 nodes each time. The second one<br />
goes at 1 nodes each time. If there is a cycle, the one that goes 2 nodes each time will<br />
eventually meet the one that goes slower. If that is the case, then you will know the<br />
linked-list is a cycle.<br />
How can you tell what shell you are running on UNIX system?<br />
You can do the Echo $RANDOM. It will return a undefined variable if you are from the<br />
C-Shell, just a return prompt if you are from the Bourne shell, and a 5 digit random numbers<br />
if you are from the Korn shell. You could also do a ps -l and look for the shell with the<br />
highest PID.<br />
What is Boyce Codd Normal form?<br />
A relation schema R is in BCNF with respect to a set F of functional dependencies if for all<br />
functional dependencies in F+ of the form a-&gt;b, where a and b is a subset of R, at least one<br />
of the following holds:<br />
• a-&gt;b is a trivial functional dependency (b is a subset of a)<br />
• a is a superkey for schema R<br />
Could you tell something about the Unix System Kernel?<br />
The kernel is the heart of the UNIX openrating system, it’s reponsible for controlling the<br />
computer’s resouces and scheduling user jobs so that each one gets its fair share of<br />
resources.<br />
What is a Make file?<br />
Make file is a utility in Unix to help compile large programs. It helps by only compiling<br />
the portion of the program that has been changed<br />
How do you link a C++ program to C functions?<br />
By using the extern &#8220;C&#8221; linkage specification around the C function declarations.<br />
Explain the scope resolution operator.<br />
Design and implement a String class that satisfies the following:<br />
Supports embedded nulls<br />
Provide the following methods (at least)<br />
Constructor<br />
Destructor<br />
Copy constructor<br />
Assignment operator<br />
Addition operator (concatenation)<br />
Return character at location<br />
Return substring at location<br />
Find substring<br />
Provide versions of methods for String and for char* arguments<br />
Suppose that data is an array of 1000 integers. Write a single function call that will sort<br />
the 100 elements data [222] through data [321].<br />
Answer: quicksort ((data + 222), 100);<br />
What is a modifier?<br />
What is an accessor?</p>
<p>Differentiate between a template class and class template.</p>
<p>When does a name clash occur?</p>
<p>Define namespace.</p>
<p>What is the use of ‘using’ declaration.</p>
<p>What is an Iterator class?</p>
<p>List out some of the OODBMS available.</p>
<p>List out some of the object-oriented methodologies.</p>
<p>What is an incomplete type?</p>
<p>What is a dangling pointer?</p>
<p>Differentiate between the message and method.</p>
<p>What is an adaptor class or Wrapper class?</p>
<p>What is a Null object?</p>
<p>What is class invariant?<br />
What do you mean by Stack unwinding?<br />
Define precondition and post-condition to a member function.</p>
<p>What are the conditions that have to be met for a condition to be an invariant of the class?</p>
<p>What are proxy objects?</p>
<p>Name some pure object oriented languages.</p>
<p>Name the operators that cannot be overloaded.</p>
<p>What is a node class?</p>
<p>What is an orthogonal base class?</p>
<p>What is a container class? What are the types of container classes?</p>
<p>What is a protocol class?</p>
<p>What is a mixin class?</p>
<p>What is a concrete class?</p>
<p>What is the handle class?</p>
<p>What is an action class?</p>
<p>When can you tell that a memory leak will occur?<br />
What is a parameterized type?<br />
Differentiate between a deep copy and a shallow copy?<br />
What is an opaque pointer?<br />
What is a smart pointer?<br />
What is reflexive association?<br />
What is slicing?<br />
What is name mangling?<br />
What are proxy objects?<br />
What is cloning?<br />
Describe the main characteristics of static functions.<br />
Will the inline function be compiled as the inline function always? Justify.<br />
Define a way other than using the keyword inline to make a function inline.<br />
How can a &#8216;::&#8217; operator be used as unary operator?<br />
What is placement new?<br />
What do you mean by analysis and design?<br />
What are the steps involved in designing?</p>
<p>What are the main underlying concepts of object orientation?</p>
<p>What do u meant by &#8220;SBI&#8221; of an object?</p>
<p>Differentiate persistent &amp; non-persistent objects?</p>
<p>What do you meant by active and passive objects?</p>
<p>What is meant by software development method?</p>
<p>What do you meant by static and dynamic modeling?</p>
<p>How to represent the interaction between the modeling elements?</p>
<p>Why generalization is very strong?</p>
<p>Differentiate Aggregation and containment?<br />
Can link and Association applied interchangeably?</p>
<p>What is meant by &#8220;method-wars&#8221;?</p>
<p>Whether unified method and unified modeling language are same or different?</p>
<p>Who were the three famous amigos and what was their contribution to the object community?</p>
<p>Differentiate the class representation of Booch, Rumbaugh and UML?</p>
<p>What is an USECASE? Why it is needed?</p>
<p>Who is an Actor?</p>
<p>What is guard condition?</p>
<p>Differentiate the following notations?</p>
<p>USECASE is an implementation independent notation. How will the designer give the<br />
implementation details of a particular USECASE to the programmer?</p>
<p>Suppose a class acts an Actor in the problem domain, how to represent it in the static<br />
model?</p>
<p>Why does the function arguments are called as &#8220;signatures&#8221;?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pdftutorials.com/questions/c-interview-questions.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>VB INTERVIEW QUESTIONS</title>
		<link>http://www.pdftutorials.com/questions/vb-interview-questions.html</link>
		<comments>http://www.pdftutorials.com/questions/vb-interview-questions.html#comments</comments>
		<pubDate>Thu, 13 Oct 2011 13:38:07 +0000</pubDate>
		<dc:creator>Tutorial Master</dc:creator>
				<category><![CDATA[questions]]></category>

		<guid isPermaLink="false">http://www.pdftutorials.com/test/?p=3864</guid>
		<description><![CDATA[What are the three main differences between flexgrid control and dbgrid(Data bound Grid) control The Microsoft FlexGrid (MSFlexGrid) control displays and operates on tabular data. It allows complete flexibility to sort, merge, and format tables containing strings and pictures. When bound to a Data control, MSFlexGrid displays read-only data.Adaptation to existing Visual Basic code for <a href="http://www.pdftutorials.com/questions/vb-interview-questions.html"> read more <span class="meta-nav">&#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p>What are the three main differences between flexgrid control and dbgrid(Data bound Grid) control</p>
<p>The Microsoft FlexGrid (MSFlexGrid) control displays and operates on tabular data. It allows complete flexibility to sort, merge, and format tables containing strings and pictures. When bound to a Data control, MSFlexGrid displays read-only data.Adaptation to existing Visual Basic code for the data-bound grid (DBGrid).</p>
<p>dbgrid is A spreadsheet-like bound control that displays a series of rows and columns representing records and fields from a Recordset object.</p>
<p>The data grids are bound controls; that is, they require a data source that actually connects to a database and retrieves their data. And it seems that the root of the problem with DBGrid is that there’s no data source that can be readily included along with the DBGrid control.<br />
In Visual Basic, the solution is simply to include the Data Control on the same form as DBGrid. But the Data Control is an intrinsic control; it’s unavailable to anything outside of the Visual Basic environment itself. and VB 6.0 has a new set of data controls (DataGrid, DataList, DataCombo, MSHFlexGrid, MSFlexGrid) that once again are bound controls. Unlike DBGrid, though, they support OLE DB, and therefore rely on the an ADO Data Source (and in particular the ActiveX Data Objects Data Control, or ADO DC) for data access. Unlike the Data Control, the ADO<br />
DC is a custom control (that is, an .OCX) that can be added to any project. In short, if you add ADO DC to your project along with the<br />
DataGrid control.<br />
ActiveX and Types of ActiveX Components in VB ?</p>
<p>Standard EXE<br />
ActiveX EXE<br />
ActiveX DLL<br />
ActiveX document<br />
ActiveX Control</p>
<p>What is difference between inprocess and out of process ?</p>
<p>An in-process component is implemented as a DLL, and runs in the same process space as its client app, enabling the most efficient communication between client and component.Each client app that uses the component starts a new instance of it.</p>
<p>An out of process component is implemented as an EXE, and unlike a dll, runs in its own process space. As a result, exe’s are slower then dll’s<br />
because communications between client and component must be marshalled across process boundaries. A single instance of an out of process component can service many clients.<br />
Advantage of ActiveX Dll over Active Exe ?</p>
<p>ACTIVEX DLL:<br />
=============<br />
An in-process component, or ActiveX DLL, runs in another application’s process. In-process components are used by applications or other in-process components. this allows you to wrap up common functionality (like an ActiveX Exe).</p>
<p>ACTIVEX EXE:<br />
=============<br />
An out-of-process component, or ActiveX EXE, runs in its own address space. The client is usually an application running in another process.The code running in an ActiveX Exe is running in a separate process space. You would usually use this in N-Tier programming.</p>
<p>An ActiveX EXE runs out of process while an ActiveX DLL runs in the same process space as VB app. Also, and ActiveX EXE can be run independent of your application if desired.</p>
<p>Explain single thread and multithread thread apartments</p>
<p>All components created with Visual Basic use the apartment model, whether they’re single-threaded or multithreaded. A single-threaded component has only one apartment, which contains all the objects the component provides.</p>
<p>This means that a single-threaded DLL created with Visual Basic is safe to use with a multithreaded client. However, there’s a performance trade-off for this safety. Calls from all client threads except one are marshaled, just as if they were out-of-process calls.</p>
<p>What is a Component?</p>
<p>If you compile an ActiveX dll, it becomes a component.<br />
If you compile an ActiveX Control, it becomes both a component and a control. Component is a general term used to describe code that’s grouped by functionality. More specifically, a component in COM terms is a compiled collection of properties/methods and events.</p>
<p>Typically a component is loaded into your project via the References whereas an ActiveX Control is loaded into your project via “components”.<br />
What is meant by “Early Binding” and “Late Binding”? Which is better?</p>
<p>Early binding and late binding refer to the method used to bind an interface’s properties and methods to an object reference (variable). Early binding uses type library information at design time to reference procedures, while late binding handles this at run time. Late binding<br />
handles this by interrogating the reference before each call to insure that it supports a particular method. Since every call to a late bound<br />
object actually requires two calls</p>
<p>(“Do you do this?” followed by “Okay, do it then”), late binding is much less efficient than early binding. Except where early binding is not supported (ASP, scripting, etc.), late binding should only be used in very special cases.</p>
<p>It is a common misconception that any code using the CreateObject function instead of Set = New is using late binding. This is not the case. The type declaration of the object variable determines whether<br />
it is late or early bound, as in the following:</p>
<p>Dim A As Foo<br />
Dim B As Foo<br />
Dim C As Object<br />
Dim D As Object</p>
<p>Set A = New Foo ‘Early Bound<br />
Set B = CreateObject(“FooLib.Foo”) ‘Early Bound<br />
Set C = CreateObject(“FooLib.Foo”) ‘Late Bound<br />
Set D = New Foo ‘Late Bound<br />
What are the Advantages of disconnected recordsets?</p>
<p>A disconnected Recordset, as its name implies, is a Recordset that lacks a connection.</p>
<p>seen that a Recordset that does not have a database connection can be very useful as a tool in your programming. It can save you time and effort and make your code more scalable.</p>
<p>In order to create a disconnected Recordset two Recordset properties must be set appropriately.<br />
It is a requirement that the CursorLocation property is set to adUseClient and the LockType property is set to adLockBatchOptimistic. Note that the CursorType will default to adUseStatic if we don’t explicitly state that it should be set to adUseClient.) i.e</p>
<p>rst.LockType = adLockBatchOptimistic<br />
rst.CursorLocation = adUseClient</p>
<p>However, we’ve recently discovered that these steps aren’t necessary. VB automatically assigns batch optimistic locking to newly created,<br />
connectionless recordsets. And, of course, without a connection, a recordset can’t have any other cursor but a client-side one. To create one of these structures, then, the only thing you need do is create<br />
the object variable instance. After that, you can simply begin adding fields to the construct.</p>
<p>To add fields, you use the Fields collection’s Append method. This method requires two parameters , the field name and the field data type. So, to create a connectionless recordset with two fields,you’d use code similar to:</p>
<p>Dim rst As ADODB.Recordset<br />
Set rst = New ADODB.Recordset</p>
<p>rst.Fields.Append “CustID”, adVarChar<br />
rst.Fields.Append “CustName”, adVarChar</p>
<p>Additional, optional Append method parameters include DefinedSize and Attrib. The DefinedSize argument takes the size of the field. Fill the Attrib parameter with constants that define additional field characteristics, such as whether it will allow null values or is updatable.<br />
Since, in our technique, we want the fields to mirror the structure of the original recordset, we’ll simply use existing values for these parameters.</p>
<p>Disconnected Recordsets, first available with ADO 2.0, are the most commonly used mechanism to retrieve a Recordset and open a connection for only the necessary amount of time, thus increasing scalability. They are call disconnected because the connection to the database is closed.<br />
The collections, properties, and methods of a disconnected Recordset are still available even though the connection is closed. This frees up server resources, given that the number of open connections is limited and database locking is a non-issue.<br />
What are Benefits of wrapping database calls into MTS transactions?</p>
<p>If database calls are made within the context of a transaction, aborting the transaction will undo and changes that occur within that transaction.<br />
This removes the possibility of stranded, or partial data. Transaction that uses the Microsoft® Transaction Server (MTS) environment. MSMQ implicitly uses the current MTS transaction if one is available.</p>
<p>BENIFTIS OF USING MTS :<br />
Database Pooling, Transactional operations, Deployment, Security, Remote Execution This allows MTS to reuse database connections. Database connections are put to ?sleep? As opposed to being created and destroyed and are activated upon request.</p>
<p>How to register a component?</p>
<p>Compiling the component, running REGSVR32 MyDLL.dll<br />
Controls which do not have events ?</p>
<p>Shape and line controls are useful for drawing graphical elements on<br />
the surface of a form. These controls don’t support any events; they<br />
are strictly for decorative purposes.</p>
<p>EXTRA INFO::<br />
The image, shape and line controls are considered to be lightweight controls; that is, they support only a subset of the properties, methods, and events found in the picture box. Because of this, they typically require less system resources and load faster than the picture box control.</p>
<p>What are the Control Categories</p>
<p>a)Intrinsic controls:<br />
such as the command button and frame controls. These controls are contained inside the Visual Basic .exe file. Intrinsic controls are always included in the toolbox</p>
<p>b)ActiveX controls:<br />
which exist as separate files with a .ocx file name extension. These include controls that are available in all editions of Visual Basic (DataCombo, DataList controls, and so on) and those that are available only in the Professional and Enterprise editions (such as Listview, Toolbar, Animation, and Tabbed Dialog). Many third-party ActiveX controls are also available.</p>
<p>c)Insertable Objects:<br />
such as a Microsoft Excel Worksheet object containing a list of all your company’s employees, or a Microsoft Project Calendar object containing the scheduling information for a project. Since these can<br />
be added to the toolbox, they can be considered controls.Some of these objects also support Automation (formerly called OLE Automation),which allows you to program another application’s objects from within a Visual Basic application.<br />
DIFF between Image and Picture box controls?</p>
<p>The sizing behavior of the image control differs from that of the picture box. It has a Stretch property while the picture box has an AutoSize property. Setting the AutoSize property to True causes a picture box to resize to the dimensions of the picture; setting it to False causes the picture to be cropped (only a portion of the picture is visible). When set to False (the default) , the Stretch property of the image control causes it to resize to the dimensions of the picture.<br />
Setting the Stretch property to True causes the picture to resize to the size of the image control, which may cause the picture to appear<br />
distorted.</p>
<p>Default property of datacontrol ?…</p>
<p>connect property……</p>
<p>Define the scope of Public, Private, Friend procedures?</p>
<p>The set of public variables, methods, properties, and events described in a class module define the interface for an object. The interface consists of the object members that are available to a programmer who’s using the object from code.</p>
<p>You can create private variables, methods, properties, and events that are used by other procedures within the class module but are not part of the object’s public interface. Additionally, constants user-defined types, and Declare statements within a class module must always be private.</p>
<p>The Friend keyword makes a procedure private to the project: The procedure is available to any code running within the project, but it is not available to a referencing project.<br />
Describe Database Connection pooling relative to MTS ?</p>
<p>This allows MTS to reuse database connections. Database connections are put to ?sleep? as opposed to being created and destroyed and are activated upon request.</p>
<p>Object pooling is an important design concept required for high-performance applications. A performance optimization based on using collections of preallocated resources, such as objects or database connections. Pooling results in more efficient resource allocation.</p>
<p>Difference between a function and a subroutine ?</p>
<p>A function accepts any number of parameters (possibly zero), does something with them, and returns a value. A subroutine is performs an action, but doesn’t return a value.</p>
<p>There are two differences between a function and a subroutine: A)How they are invoked. B)How they are accessed.</p>
<p>A function call has the following syntax ::<br />
function(arg1, arg2, …)<br />
where: function Is the name of the function. arg1, arg2, … Are the arguments.</p>
<p>A subroutine call has the following syntax<br />
::subroutine (arg1, arg2, … {outputfield|’format’})<br />
where: subroutine –&gt;Is the name of the subroutine. arg1, arg2, … Are the arguments. {outputfield|’format’} Is the name of the output field or its format.</p>
<p>In addition, on some platforms, the functions are available immediately; whereas, the subroutines are available in a special subroutine library that you must access.<br />
Difference between Linked Object and Embedded Object?</p>
<p>Embedding objects -<br />
When you embed an object, a copy of the object is inserted into the destination document. There’s no link to the original file. When you change information in the source document, no changes will be reflected in the destination document. The actual data for the object is stored within the destination file. To make changes to the embedded object, double click it and it will launch the original application the source file was in.</p>
<p>Linking objects -<br />
Information is updated when you modify the original source file when you use a linked object. This dynamic updating is very handy for things such as the aforementioned monthly report. You can open up the Excel spreadsheet that is referenced within your Word document.Make changes to the spreadsheet, close Excel, and when you open your Word document… viola! The changes are already there. If that object is linked to ten other Word files, the changes are already in those ten files, too! actually linking or embedding an object is fast and easy.</p>
<p>Difference between listbox and combo box?</p>
<p>A LISTBOX CONTROL displays a list of items from which the user can select one or more. If the number of items exceeds the number that can be displayed, a scroll bar is automatically added to the ListBox control. A COMBOX CONTROL combines the features of a text box and a list box. This control allows the user to select an item either by typing text into the combo box, or by selecting it from the list.<br />
DIFF::Generally, a combo box is appropriate when there is a list of suggested choices, and a list box is appropriate when you want to limit input to what is on the list. A combo box contains an edit field, so choices not on the list can be typed in this field.</p>
<p>Difference between Dynaset and Snapshot?</p>
<p>All Recordset objects are constructed using records (rows) and fields (columns). There are five types of Recordset objects:</p>
<p>Table-type Recordset ::<br />
representation in code of a base table that you can use to add, change, or delete records from a single database table (Microsoft Jet workspaces only).</p>
<p>Dynaset-type Recordset ::<br />
the result of a query that can have updatable records. A dynaset-type Recordset object is a dynamic set of records that you can use to add, change, or delete records from an underlying database table or tables. A dynaset-type Recordset object can contain fields from one or more tables in a database. This type corresponds to an ODBC keyset cursor.</p>
<p>Snapshot-type Recordset ::<br />
a static copy of a set of records that you can use to find data or generate reports. A snapshot-type Recordset object can contain fields from one or more tables in a database but can’t be updated. This type corresponds to an ODBC static cursor.</p>
<p>Forward-only-type Recordset::<br />
identical to a snapshot except that no cursor is provided. You can only scroll forward through records. This improves performance in situations where you only need to make a single pass through a result set. This type corresponds to an ODBC forward-only cursor.</p>
<p>Dynamic-type Recordset ::<br />
a query result set from one or more base tables in which you can add, change, or delete records from a row-returning query. Further, records other users add, delete, or edit in the base tables also appear in your Recordset. This type corresponds to an ODBC dynamic cursor (ODBCDirect workspaces only).<br />
Difference Listindex and Tab index?</p>
<p>LIST INDEX::<br />
Returns or sets theindex of the currently selected item in the control. Not available at design time.Default LIST INDEX IS -1 for ComboBox, DirListBox, and DriveListBox controls<br />
TAB INDEX::<br />
Returns or sets thetab order of most objects within their parent form. Visual Basic automatically renumbers the TabIndex of other controls to reflect insertions and deletions. You can make changes atdesign time using theProperties window or atrun time in code.The TabIndex property isn’t affected by the ZOrder method.</p>
<p>Difference modal and moduless window?</p>
<p>MODAL forms are forms which require user input before any other actions can be taken place. In other words, a modal form has exclusive focus in that application until it is dismissed. When showing a modal form, the<br />
controls outside this modal form will not take user interaction until the form is closed. The internal MsgBox and InputBox forms are examples of modal forms. To show a form modally, use the syntax:<br />
MyForm.SHOW.vbModal ‘ a predeclared constant for 1<br />
MODELESS forms are those which are shown but do not require immediate user input. MDI child forms are always modeless. To show a form modeless, use the syntax:: MyForm.SHOW<br />
Difference Object and Class?</p>
<p>Classes and objects are separate but related concepts. Every object belongs to a class and every class contains one or more related objects.<br />
1)A Class is static. All of the attributes of a class are fixed before,during, and after the execution of a program. The attributes of a class don’t change.The class to which an object belongs is also (usually) static. If a particular object belongs to a certain class at the time that it is created then it almost certainly will still belong to that class right up until the time that it is destroyed.<br />
2)An Object on the other hand has a limited lifespan. Objects are created and eventually destroyed. Also during that lifetime, the attributes of the object may undergo significant change.So basically the difference between a class and an object is that a class is a general concept while objects are the specific and real instances that embody that concept. When creating an object oriented program we define the classes and the relationships between the classes . We then execute the program to create, update, and destroy the objects which are the specific realization of these classes.</p>
<p>Difference Query unload and unload in form?</p>
<p>Occurs before a form or application closes. When an MDIForm object closes, the QueryUnload event occurs first for the MDI form and then in all MDI child forms. If no form cancels the QueryUnload event, the Unload event occurs first in all other forms and then in an MDI form. When a child form or a Form object closes, the QueryUnload event in that form occurs before the form’s Unload event.</p>
<p>Difference Declaration and Instantiation an object?</p>
<p>Dim obj as OBJ.CLASS with either<br />
Set obj = New OBJ.CLASS or<br />
Set obj = CreateObject(?OBJ.CLASS?) or<br />
Set obj = GetObject( ,? OBJ.CLASS?)<br />
or<br />
Dim obj as New OBJ.CLASS</p>
<p>Set object = Nothing<br />
ensure the object is release from the memory.</p>
<p>If this object is a form, you can add set myform = nothing and Form_Unload() event.Maintain a habit of remove the object by using set object = nothing which will benefit at last.<br />
Visual Basic is supposed to automatically release objects when they go out of scope. To free up some memory usage, you can set the object to<br />
nothing.</p>
<p>Draw and explain Sequence Modal of DAO</p>
<p>Connection,Container,Database,DBEngine,Document,Error,Field,Group,Index<br />
Parameter Property,QueryDef,Recordset,Relation,TableDef,User,Workspace</p>
<p>Version |Year |Significant Changes and New Features of Visual Basic?</p>
<p>1 1991 initial release, with drag and drop GUI creation<br />
2 1992 ODBC, object variables<br />
3 1993 Access Engine, OLE 2.0, Crystal Reports, new tools and controls<br />
4 1995 classes, OCXs<br />
5 1997 compiler, ActiveX controls<br />
6 1998 web support, windowless controls, designers, data sources<br />
.NET 2001 XML, SOAP, inheritance, structured exception handling<br />
How can objects on different threads communicate with one another?</p>
<p>Processes communicate with one another through messages, using Microsoft’s Remote Procedure Call (RPC) technology to pass information to one another. There is no difference to the caller between a call coming from a process on a remote machine and a call coming from another process on the same machine.</p>
<p>Multithreaded applications must avoid two threading problems: deadlocks and races. A deadlock occurs when each thread is waiting for the other to do something</p>
<p>How can you force new objects to be created on new threads?</p>
<p>The CreateThread function creates a thread to execute within the virtual address space of the calling process.</p>
<p>To create a thread that runs in the virtual address space of another process Creating a new thread is as easy as declaring it and supplying it with a delegate to the method where the thread is to start. When you are ready to begin execution on the thread, call the Thread.Start Method. There are special considerations involved when working with multiple threads of execution.</p>
<p>To create a new thread of execution<br />
====================================<br />
Declare the thread.<br />
******************<br />
‘ Visual Basic<br />
Dim myThread as System.Threading.Thread</p>
<p>// C#<br />
System.Threading.Thread myThread;</p>
<p>Instantiate the thread with the appropriate delegate for the starting point of the thread. Use the AddressOf operator to create the delegate<br />
in Visual Basic, or create a new ThreadStart object in C#.<br />
*******************<br />
‘ Visual Basic<br />
myThread = New System.Threading.Thread(AddressOf<br />
myStartingMethod)</p>
<p>// C#<br />
myThread = new System.Threading.Thread(new<br />
System.Threading.ThreadStart(myStartingMethod));</p>
<p>call the Thread.Start method to start the thread.<br />
*******************<br />
‘ Visual Basic<br />
myThread.Start()</p>
<p>// C#<br />
myThread.Start();<br />
How does a DCOM component know where to instantiate itself?</p>
<p>To create a remote instance of a script component, call the CreateObject method, passing it the name of the remote computer as a parameter. If the remotable attribute of a script component’s &lt;registration&gt; element has been set to “true,” the script component can be instantiated remotely from another computer using Distributed COM (DCOM).<br />
Both computers must have basic DCOM installed. Note The ability to use CreateObject for instantiating remote script components requires Visual Basic 6.0 or later or VBScript 5.0 or later. The following Visual Basic example shows how to do this on a computer named “myserver”:</p>
<p>Set newS = CreateObject(“Component.MyComponent”, “myserver”)<br />
Note There can be a slight delay when you first instantiate a remote script component while DCOM establishes communication between the computers.</p>
<p>1. You can specify the machine on which you want to create the remote server object in DCOM config (‘dcomcnfg’).</p>
<p>2. You can specify the machine name when instantiating the remote server object.<br />
In C you can do this with a call to CoGetClassObject or CoCreateInstanceEx (instead of CoCreateInstance, which does not allow you to specify the name of the machine).<br />
In VB you can specify the name in one of the parameters in the call to CreateObject</p>
<p>What type of multi-threading does VB6 implement?</p>
<p>Apartment model threading</p>
<p>How to register a component?</p>
<p>Compiling the component, running REGSVR32 MyDLL.dll<br />
What is Database Connection pooling (relative to MTS)</p>
<p>This allows MTS to reuse database connections. Database connections are<br />
put to “sleep” As opposed to being created and destroyed and are activated upon request.</p>
<p>What is the tool used to configure the port range and protocols for DCOM communications?</p>
<p>DCOMCONFIG.EXE</p>
<p>What is a Type Library and what is it’s purpose ?</p>
<p>The type library may represent another Visual Basic project, or any other executable component that exposes a type library.<br />
Visual Basic creates type library information for the classes you create, provides type libraries for the objects it includes, and lets you access the type libraries provided by other applications.</p>
<p>What are binary and project compatibility?<br />
Visual Basic’s Version Compatibility feature is a way of enhancing your components while maintaining backward compatibility with programs that were compiled using earlier versions. The Version Compatibility box, located on the Component tab of the Project Properties dialog box, contains three options:<br />
No Compatibility:<br />
Each time you compile the component, new type library information is generated, including new class IDs and new interface IDs. There is no relation between versions of a component, and programs compiled to use one version cannot use subsequent versions.</p>
<p>Project Compatibility:<br />
Each time you compile the component the type library identifier is kept, so that your test projects can maintain their references to the component project. All class IDs from the previous version are maintained; interface IDs are changed only for classes that are no longer binary-compatible with their earlier counterparts. Note This is a change in Project Compatibility from Visual Basic 5.0, where all class IDs and interface IDs in the project changed if any one class was no longer binary-compatible.</p>
<p>Important For the purpose of releasing compatible versions of a component, Project Compatibility is the same as No Compatibility.</p>
<p>Binary Compatibility:<br />
When you compile the project, if any binary-incompatible changes are detected you will be presented with a warning dialog. If you choose to accept the warning, the component will retain the type library identifier and the class IDs. Interface IDs are changed only for classes that are no longer binary-compatible. This is the same behavior as Project Compatibility.<br />
If, however, you choose to ignore the warning, the component will also maintain the interface IDs. This option is only available when the compiler determines that the change was in the procedure ID or signature of a method.</p>
<p>Note:: When people talk about Version Compatibility, they’re usually referring to Binary Compatibility.<br />
How to set a shortcut key for label?</p>
<p>object.KeyLabel(keycode) [= string]<br />
You would probably create the menu item as follows:<br />
.Add “keyFile”, , , “E&amp;xit”, , vbAltMask + vbCtrlMask, vbKeyEnd<br />
The default key label for vbKeyEnd is “End”. Thus, the shortcut string will be created by default as “Ctrl+Alt+End”.</p>
<p>Name the four different cursor and locking types in ADO and describe them briefly ?</p>
<p>CURSORS::<br />
*********<br />
The cursor types are listed from least to most resource intensive.<br />
Forward Only – Fastest, can only move forward in recordset<br />
Static – Can move to any record in the recordset. Data is static and never changes.<br />
KeySet – Changes are detectable, records that are deleted by other users are unavailable, and records created by other users are not detected Dynamic – All changes are visible.</p>
<p>LOCKING TYPES::<br />
****************<br />
LockPessimistic – Locks the row once after any edits occur.<br />
LockOptimistic – Locks the row only when Update is called.<br />
LockBatchOptimistic – Allows Batch Updates.<br />
LockReadOnly – Read only. Cannot alter the data.</p>
<p>Name the different compatibility types when creating a COM component.</p>
<p>No Compatibility – New GUID (Globally Unique Identifier) created, references from other components will not work Project Compatibility – Default for a new component &lt;Not as critical to mention this one&gt;<br />
Binary Compatibility – GUID does not change references from other components will work<br />
Why is it important to use source control software for source code?<br />
Modification history. Code ownership: Multiple people cannot modify the same code at the same time.</p>
<p>List the ADO objects?<br />
Connection – Connects to a data source; contains the Errors collection<br />
Command – Executes commands to the data source. The only object that can accept parameters for a stored procedure Recordset – The set of data returned from the database.<br />
Under the ADO Command Object, The Parameters collection. collection is responsible for input to stored procedures?</p>
<p>What two methods are called from the ObjectContext object to inform MTS that the transaction was successful or unsuccessful?<br />
SetComplete and SetAbort.</p>
<p>What is the benefit of wrapping database calls into MTS transactions?<br />
Aborting the transaction will undo and changes that occur within that transaction. This removes the possibility of stranded, or partial data</p>
<p>Describe and In Process vs. Out of Process component. Which is faster?<br />
An in-process component is implemented as a DLL, and runs in the same process space as its client app, enabling the most efficient communication between client and component. Each client app that uses the component starts a new instance of it.<br />
An out of process component is implemented as an EXE, and unlike a dll, runs in its own process space. As a result, exe’s are slower then dll’s because communications between client and component must be marshaled across process boundaries. A single instance of an out of process component can service many clients.How would you declare and raise custom events in a class?<br />
a) Public Event OnVarChange();<br />
b) RaiseEvent OnVarChange[(arg1, arg2, ... , argn)]</p>
<p>What is the difference between a Property Let and Property Set procedure?<br />
Let – for simple variable<br />
Set – for object</p>
<p>What is the difference between ANSI and UNICODE strings when passed as arguments to a DLL?<br />
ANSI – one byte for a char UNICODE – two bytes per char – works only on NT</p>
<p>What is the difference in passing values ByRef or ByVal to a procedure?<br />
ByRef -pass the address (for string -address of address of first byte)<br />
BY REF IS VERY USEFULL When the contents itself are being modified, when there is large data. Multiple arguments are needed to be returned, instead they can be passed as reference.<br />
ByVal -pass the value (for string -it is the address of first byte)</p>
<p>What is the purpose of the DoEvents command?<br />
Fields execution so that the operating system can process other events. Returns number of open forms. Useful for things like ‘cancel search’ in Windows<br />
Name and define the logical tiers in a traditional 3-tiered architecture?<br />
Presentation logic – front end (HTML, Visual Basic forms)<br />
Business Logic – Applications and components that encapsulate business logic<br />
Data end – databases to store data</p>
<p>What is the difference between a PictureBox and Image control?<br />
Image Control – Use this to display a picture. Use it over the PictureBox because it takes less operating system resources<br />
PictureBox- While it can display pictures, it also acts as an area on which you can print text and graphics. Use it for home-grown graphics or print previews</p>
<p>Under which circumstance does a VB application ignore a Timer event?<br />
When the system is really busy doing something else and when DoEvents is being executed</p>
<p>What does the NewIndex property return?<br />
Used to retrieve the index of the item most recently added to a ListBox or ComboBox control</p>
<p>What is the purpose of the ClipControls property on a form or container?<br />
Returns or sets a value that determines whether graphics methods in Paint events repaint the entire object or only newly exposed areas. Also determines whether the Microsoft Windows operating environment creates a clipping region that excludes non-graphical controls contained by the object. Read-only at run time.<br />
What is the purpose of the AutoRedraw property on a form or container?<br />
Setting AutoRedraw to True automatically redraws the output from these methods in a Form object or PictureBox control when, for example, the object is resized or redisplayed after being hidden by another object</p>
<p>Have you ever used Collections? Collection Classes?<br />
A collection is a set of Repository objects that are all connected to a common source object via a relationship collection. A collection provides a way to connect a group of dependent objects with an object that ‘contains’ them. For example, an Invoice object might have a collection of LineItem objects.</p>
<p>What version control systems have you used?<br />
TLIB 16-Bit add-in</p>
<p>How about any other database engines?<br />
Apollo OLE DB ,Apollo Server ,Apollo SQL ,FUNCky ,R&amp;R Report Writer</p>
<p>What kind of components can you use as DCOM servers?<br />
actve-x components, Com<br />
Dim x, y as integer. What is x and y data type?<br />
X as variant and y as integer.</p>
<p>What is the size of the variant data type?<br />
The Variant data type has a numeric storage size of 16 bytes and can contain data up to the range of a Decimal, or a character storage size of 22 bytes (plus string length), and can store any character text.</p>
<p>What is the return type of Instr and Strcmp?<br />
Instr – integer (Numeric position)<br />
Strcmp – integer ( if both the string are equal they result = 0)<br />
Strcmp (Str1, Str2, Comparetype)<br />
Comparing mode = 0 – Binary Comparing<br />
1 – Textual Comparing</p>
<p>What is the max size allowed for Msgbox Prompt and Input Box?<br />
1024</p>
<p>Max label caption length. –<br />
2,048</p>
<p>Max Text box length –<br />
32,000</p>
<p>Max Control Names length –<br />
255.</p>
<p>Extension in Visual Basic<br />
Frm, bas, cls, res, vbx, ocx, frx, vbp, exe<br />
What is frx?<br />
When some controls like grid and third party control placed in our application then it will create frx in run time.</p>
<p>Name some date function<br />
Dateadd(), Datediff(), Datepart(), Cdate()</p>
<p>What will be the result for 15/4 and 15\4<br />
15/4 = 3.75 and 15\4 = 3</p>
<p>What is keyword used to compare to objects?<br />
ISOperator – Returns Boolean.</p>
<p>How many procedures are in VB?<br />
2. function and sub procedures. Function Will return value but a sub procedure wont return values…</p>
<p>Where will we give the option explicit keyword and for what?<br />
In the general declarations section. To trap undeclared variables.</p>
<p>What is Friend Variable?<br />
Scope sharable between projects.What is binding? What are types of binding?<br />
Assigning variable with defined memory space. Late Binding – Memory size is allotted in later stage.<br />
Ex:- Dim x as object<br />
Early Binding – Memory size is allotted while declaring itself. New Key word is important.<br />
Ex:- Dim x as New Object</p>
<p>What is the difference between Property Get, Set and Let.<br />
Set – Value is assigned to ActiveX Object from the form.<br />
Let – Value is retried to ActiveX Object from the form.<br />
Get- Assigns the value of an expression to a variable or property.</p>
<p>What is Mask Edit and why it is used?<br />
Control. Restricted data input as well as formatted data output.</p>
<p>Drag and Drop state numbers and functions.<br />
State 0 – Source control is being dragged with the range of a target.<br />
1 – Out of the range of a target.<br />
2 – One positon in the target to another.</p>
<p>What are the type of validation available in VB?<br />
Field, Form</p>
<p>With in the form we want to check all the text box control are typed or not? How?<br />
For each currentcontrol in controls if typeof currentcontrol is TextBox then end if next</p>
<p>What is control array and How many we can have it with in the form?<br />
Group of control share the same name. Max 32, 767.What is the default model of the form? And what is it number?<br />
VbModaless – 0 (Zero) – We can able to place another window above this form.</p>
<p>Suppose from form1 to form2 object property settings will arise to ?<br />
Invalid procedure call or argument (Run time error – 5)</p>
<p>What is the diff between the Std and Class Module?<br />
Std Global with in the project. Cls Global through out the all project only thing is we want to set the type lib. Class Modules can be Instantiated.</p>
<p>Different type of Instantiation?<br />
Private – Only for the Specific Module.<br />
Public not creatable – Private &amp; Public<br />
Multi Use – Variable we have to declare.<br />
Single Use – Not possible through dll.<br />
Global Multiuse – Have variable not Required to<br />
Declare. Global Single Use – Only for exe.<br />
How to declare Dll Procedure?<br />
Declare function “&lt;Function Name&gt;” lib “&lt;Lib Name&gt;” Alias “&lt;Alias Name&gt;” (Arg, …..) as Return type.</p>
<p>What is MDI form? MDI Styles?<br />
We can have only one MDI form for a project. Multiple Document Interface. This form type is VBModal. We have set the Child property of the forms to True to place forms inside this MDI.<br />
Style availables 1. VbCascade 2. VbTitle Horizontal</p>
<p>How many images can be placed in the image list ?<br />
64</p>
<p>Diff type of Datatypes?<br />
LOB (Large Object Data type).<br />
CLOB (Stores Character Objects).<br />
BLOB ( Store Binary Objects such as Graphic, Video Chips and Sound files).<br />
BFILE(Store file pointers to LOB It may Contain filename for photo’s store on CD_ROM).</p>
<p>What is Zorder Method?<br />
Object.Zorder = 1 or 0 Place a Specified mdiform form or control at the front or back of the z-order with n its Graphical Level.</p>
<p>What is diff between the Generic Variable and Specific Variable?<br />
Generic Variable:Create Object Ex:-Ole-Automation . No need refer the object library.<br />
Specific Variable: Binding Procedure Early and Late Binding ( Can be Remove from the Memory).<br />
What are properties available in Clip Board?<br />
No Properties Available. Only the methods they are SetText, GetText, Setdata(), Getformat(), Clear.</p>
<p>What is Dll?<br />
Libraries of procedure external to the application but can be called from the application.</p>
<p>What is Tabstrip control? What is the starting Index value? How to locate it?<br />
It is tab control to place our controls with in the form in multiple sheets.<br />
Index starts with 1. And to identify<br />
If Tabstrip1.SelectedItem.Index = 1 Then<br />
…..<br />
End if</p>
<p>Why we use Treeview Control?<br />
To list the hierarchial list of the node objects. Such of files and Directories.</p>
<p>Why we need OLE-Automation? Advantages?<br />
Enables an application to exposes objects and methods to other Applications.<br />
No need to reserve memory. No need to write functions.<br />
Object library that simplify programming tasks. i.e., No need to Object library. (OLB, TLB).</p>
<p>What is the diff between the Create Object and Get object?<br />
Create Object – To create an instance of an object.<br />
Get Object – To get the reference to an existing object.</p>
<p>Have you create Properties and Methods for your own Controls?<br />
Properties – Public variable of a Class<br />
Method – Public procedure of a classWhat is Collection Objects?<br />
Similarly to arrays but is preferred over an array because of the following reasons.<br />
1. A collection objects uses less Memory than an array.<br />
2. It provides methods to add and delete members.<br />
3. It does not required reason statement when objects are added or deleted.<br />
4. It does not have boundary limitations.</p>
<p>What is Static Variable?<br />
Its Scope will be available through out the life time.</p>
<p>Private Dim x as integer. Is it true?<br />
No. Private cannot be used in front of DIM.</p>
<p>What is Implicit?<br />
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.</p>
<p>What are the scope of the class?<br />
Public , private, Friend</p>
<p>Can we able to set Instancing properties like Singleuse, GlobalSingleuse to ActiveXDll?<br />
No.</p>
<p>In project properties if we set Unattended what is it mean?<br />
This cannot have user interface. This can be used for the COM creation.What are the Style Properties of Combo Box?<br />
Simple, Dropdown list – We can type and select.<br />
Dropdown Combo – Only Drop Down.</p>
<p>What are the Style properties of List Box?<br />
Simple –Single Select , Extended. – Multiple Select.</p>
<p>What are the different types of Dialog Box?<br />
Predefined, Custom, User Defined.</p>
<p>What is Parser Bug?<br />
It is difficult to use database objects declared in a module from within a form.</p>
<p>What is the Dll required for running the VB?<br />
Vbrun300.dllCan We create CGI scripts in VB?<br />
Yes.</p>
<p>How to change the Mouse Pointer?<br />
Screen.MousePointer = VBHourGlass/VBNormal.</p>
<p>How to check the condition in Msgbox?<br />
If(Msgbox(“Do you want to delete this Record”,VbYesNo)=VbYes)Then End if</p>
<p>What is difference between datagrid and flexgrid?<br />
Datagrid – Editable.<br />
Flexigrid – Non-Editable. (Generally used for Read only purpose.)</p>
<p>What is ADO? What are its objects ?<br />
ActiveX Data Object. ADO can access data from both flat files as well as the databases. I.e., It is encapsulation of DAO, RDO, and OLE that is why we call it as OLE-DB Technology. Objects are Connection, Record Set, Command, Parameter, field, Error, Property.</p>
<p>What is Dataware Control?<br />
Any control bound to Data Control.<br />
Ex:- Textbox, Check Box, Picture Box, Image Control, Label, List box, Combo Box, DB Combo, What are two validate with Data Control?<br />
Data_Validate, Data_Error.</p>
<p>Record set types and Number available in VB?<br />
3. 1- Dynaset, 0 – Table, 2 – Snap Shot.</p>
<p>Referential Integrity (Take care By jet database Engine).<br />
Cascade Delete, Cascade Update – is done setting property of Attributes.<br />
DbRelationDeleteCascade,<br />
DbRelationUpdateCascade.</p>
<p>What are the locks available in Visual Basic?<br />
Locking is the process by which a DBMS restricts access to a row in a multi-user environment<br />
4 types of locks. They are<br />
1.Batch Optimistic<br />
2.Optimistic<br />
3.Pessimistic<br />
4.ReadOnlyWhat is the diff between RDO and ADO?<br />
RDO is Hierarchy model where as ADO is Object model. ADO can access data from both flat files as well as the data bases. I.e., It is<br />
encapsulation of DAO, RDO , OLE that is why we call it as OLE-DB Technology.</p>
<p>How can we call Stored procedure of Back End in RDO and ADO ?<br />
In RDO – We can call using RDO Query Objects.<br />
In ADO – We can call using Command Objects.</p>
<p>What is the different between Microsoft ODBC Driver and Oracle OBDC Driver?<br />
Microsoft ODBC driver will support all the methods and properties of Visual Basic. Where as the Oracle not.</p>
<p>What are the Technologies for Accessing Database from Visual Basic?<br />
DAO, Data Control, RDO, ODBCDIRECT, ADO, ODBC API.</p>
<p>Calling Stored Procedures in VB?<br />
1. Calling Simply the Procedure with out Arguments “Call ProcedureName}”</p>
<p>If it is with Arguments Means then<br />
Declare the Query Def qy<br />
Set Qy as New Query def<br />
Qy.SQL = “{Call ProcedureName(?,?,?)}”<br />
qy(0)=val(Txt1.Text)<br />
qy(1)=val(Txt2.Text)<br />
qy(2)=val(Txt3.Text)<br />
Set Rs = Qy.OpenresultSet<br />
Txt(1)=Rs.RdoColumns(0)What is MAPI ?<br />
Messaging Application programing Interface.</p>
<p>Different type of Passing Value?<br />
By value, By ref, Optional, Param Array.<br />
Note:- Optional keyword cannot be used while declaring arguments for a function using param array.</p>
<p>What are the different types of error?<br />
Syntax Errors, Runtime , Logic.</p>
<p>What is Seek Method which type of record set is available this?<br />
Only in DbOpenTables.<br />
Syntax: rs.index = “empno”<br />
rs.seek “=” , 10<br />
If with our setting the rs.index then run time error will occur.What is Centralization Error Handling?<br />
Writing funciton and calling it when error occurs.</p>
<p>Handling Error in Calling chain.<br />
This will call the top most error where the error is handled.</p>
<p>To connect the Data Control with Back end What are all the properties to be set?<br />
Data source Name, Record Source Name</p>
<p>How to trap Data Base Error?<br />
Dim x as RDOError<br />
X(0).Des<br />
X(1).NumberWhat is view Port?<br />
The area under which the container provides the view of the ActiveX Document is known as a view port.</p>
<p>What methods are used for DBGrid in unbound mode?<br />
AddData, EditData, Readdata, WriteData.</p>
<p>How to increase the Date corresponding with month,date,year?<br />
DateSerial(year(Now),Month(Now)+1,1)<br />
Hour, min, sec, month, year, DateSerial, dateadd, datediff, weekday, datevalue, timeserial,timevalue.</p>
<p>Setting the Cursors.<br />
Default Cursor – 0<br />
ODBC Cursor (Client side) – 1<br />
ServerSide Cursors (More Network traffic) – 2Cursor management<br />
Client Batch – Batch up the Multiple SQL Statements in a single string and Send them to the Server at one time.</p>
<p>What are the record set types?<br />
RdOpenFowardOnly 0 (Default used only for the read only purpose)<br />
RdOpenStatic 1<br />
RdOpenDynamic 2<br />
RdOpenKeySet 3 (Normally used for the live project)</p>
<p>Diff types of Lock Types?<br />
RdConcurReadOnly 0 (Default)<br />
RdConcurLock 1 (Pessimistic Locking)<br />
RdConcurRowver 2 (Optimistic Lociking)<br />
RdConcurValues 3<br />
RdConcurBatch 4</p>
<p>What are the RDO Methods and Events?<br />
Methods Events<br />
Begin Trans Validate<br />
Commit Trans Reposition<br />
Rollback Trans Error<br />
Cancel Query Complied<br />
Refresh<br />
Update Controls<br />
Update rowWhat is Static Cursor?<br />
In ADO Snap Shot is called so.</p>
<p>What is Mixed Cursors?<br />
Static + Keyset</p>
<p>What is FireHouse Cursors?<br />
Forward Only Some time Updateable</p>
<p>What is DBSqlPassThrough?<br />
It will By Passing the Jet Query Processor.</p>
<p>What is DBFailError?<br />
Rolls Back updates if any errors Occurs.</p>
<p>DSN Less Connection?<br />
“Server=Oracle; Driver={Microsoft ODBC for Oracle};”</p>
<p>What is RdExecDirect?<br />
Bypasses the Creation of a stored procedure to execute the query. Does not apply to Oracle.</p>
<p>RdoParameter Object RdoParameterConstant<br />
Direction RdparamInput<br />
RdparamInputOutput<br />
RdParamOutput<br />
Name<br />
Type<br />
Value</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pdftutorials.com/questions/vb-interview-questions.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>UNIX interview Questions</title>
		<link>http://www.pdftutorials.com/questions/unix-interview-questions.html</link>
		<comments>http://www.pdftutorials.com/questions/unix-interview-questions.html#comments</comments>
		<pubDate>Thu, 13 Oct 2011 13:37:31 +0000</pubDate>
		<dc:creator>Tutorial Master</dc:creator>
				<category><![CDATA[questions]]></category>

		<guid isPermaLink="false">http://www.pdftutorials.com/test/?p=3862</guid>
		<description><![CDATA[Generally Asked Unix Interview Questions What exactly is UNIX? How are devices represented in UNIX? What is ‘inode’? Brief about the directory representation in UNIX How do you change File Access Permissions? What are the main differences between Apache 1.x and 2.x? Explain about DELETE and BREAK? What are the Unix system calls for I/O? <a href="http://www.pdftutorials.com/questions/unix-interview-questions.html"> read more <span class="meta-nav">&#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Generally Asked Unix Interview Questions</p>
<p>What exactly is UNIX?<br />
How are devices represented in UNIX?<br />
What is ‘inode’?<br />
Brief about the directory representation in UNIX<br />
How do you change File Access Permissions?<br />
What are the main differences between Apache 1.x and 2.x?<br />
Explain about DELETE and BREAK?<br />
What are the Unix system calls for I/O?<br />
What is a FIFO?<br />
What is a shell?<br />
What does the “route” command do?<br />
Explain about TYPE-ahead?<br />
What is a zombie?<br />
What are the read/write/execute bits on a directory mean?<br />
Explain about cat?<br />
What does iostat do?<br />
How to search files for lines that match a pattern?<br />
what does vmstat do?<br />
Describe about the root file system?<br />
What does netstat do?<br />
Explain about ZAP?<br />
Explain fork() system call.<br />
What is AWK?<br />
Explain abut low-level I/O?<br />
What is SED?<br />
Explain about read slow?<br />
What is the difference between binaries in /bin, and /usr/bin?<br />
What function does “errno” do?<br />
What is a dynamically linked file?<br />
Describe the process of “spname”?<br />
What is a statically linked file?<br />
Explain about fork?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pdftutorials.com/questions/unix-interview-questions.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>TESTING INTERVIEW QUESTIONS</title>
		<link>http://www.pdftutorials.com/questions/testing-interview-questions.html</link>
		<comments>http://www.pdftutorials.com/questions/testing-interview-questions.html#comments</comments>
		<pubDate>Thu, 13 Oct 2011 13:36:52 +0000</pubDate>
		<dc:creator>Tutorial Master</dc:creator>
				<category><![CDATA[questions]]></category>

		<guid isPermaLink="false">http://www.pdftutorials.com/test/?p=3860</guid>
		<description><![CDATA[TESTING INTERVIEW QUESTIONS What is Acceptance Testing? Testing conducted to enable a user/customer to determine whether to accept a software product. Normally performed to validate the software meets a set of agreed acceptance criteria. What is Accessibility Testing? Verifying a product is accessible to the people having disabilities (deaf, blind, mentally disabled etc.). What is <a href="http://www.pdftutorials.com/questions/testing-interview-questions.html"> read more <span class="meta-nav">&#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p>TESTING INTERVIEW QUESTIONS</p>
<p>What is Acceptance Testing?<br />
Testing<br />
conducted to enable a user/customer to determine whether to accept a software product. Normally performed to validate the software meets a set of agreed acceptance criteria.</p>
<p>What is Accessibility Testing?<br />
Verifying a product is accessible to the people having disabilities (deaf, blind, mentally disabled etc.).</p>
<p>What is Ad Hoc Testing?<br />
A testing phase where the tester tries to ‘break’ the system by randomly trying the system’s functionality. Can include negative testing as well. See also Monkey Testing.</p>
<p>What is Agile Testing?<br />
Testing practice for projects using agile methodologies, treating development as the customer of testing and emphasizing a test-first design paradigm. See also Test Driven Development.</p>
<p>What is Application Binary Interface (ABI)?<br />
A specification defining requirements for portability of applications in binary forms across defferent system platforms and environments.</p>
<p>What is Application Programming Interface (API)?<br />
A formalized set of software calls and routines that can be referenced by an application program in order to access supporting system or network services.</p>
<p>What is Automated Software Quality (ASQ)?<br />
The use of software tools, such as automated testing tools, to improve software quality.</p>
<p>What is Automated Testing?<br />
Testing employing software tools which execute tests without manual intervention. Can be applied in GUI, performance, API, etc. testing.<br />
The use of software to control the execution of tests, the comparison of actual outcomes to predicted outcomes, the setting up of test preconditions, and other test control and test reporting functions.<br />
What is Backus-Naur Form?<br />
A metalanguage used to formally describe the syntax of a language.</p>
<p>What is Basic Block?<br />
A sequence of one or more consecutive, executable statements containing no branches.</p>
<p>What is Basis Path Testing?<br />
A white box test case design technique that uses the algorithmic flow of the program to design tests.</p>
<p>What is Basis Set?<br />
The set of tests derived using basis path testing.</p>
<p>What is Baseline?<br />
The point at which some deliverable produced during the software engineering process is put under formal change control.<br />
What you will do during the first day of job?<br />
What would you like to do five years from now?</p>
<p>Tell me about the worst boss you’ve ever had.</p>
<p>What are your greatest weaknesses?</p>
<p>What are your strengths?</p>
<p>What is a successful product?</p>
<p>What do you like about Windows?</p>
<p>What is good code?</p>
<p>What are basic, core, practices for a QA specialist?</p>
<p>What do you like about QA?</p>
<p>What has not worked well in your previous QA experience and what would you change?</p>
<p>How you will begin to improve the QA process?</p>
<p>What is the difference between QA and QC?</p>
<p>What is UML and how to use it for testing?<br />
What is Beta Testing?<br />
Testing of a rerelease of a software product conducted by customers.</p>
<p>What is Binary Portability Testing?<br />
Testing an executable application for portability across system platforms and environments, usually for conformation to an ABI specification.</p>
<p>What is Black Box Testing?<br />
Testing based on an analysis of the specification of a piece of software without reference to its internal workings. The goal is to test how well the component conforms to the published requirements for the component.</p>
<p>What is Bottom Up Testing?<br />
An approach to integration testing where the lowest level components are tested first, then used to facilitate the testing of higher level components. The process is repeated until the component at the top of the hierarchy is tested.</p>
<p>What is Boundary Testing?<br />
Test which focus on the boundary or limit conditions of the software being tested. (Some of these tests are stress tests).<br />
What is Bug?<br />
A fault in a program which causes the program to perform in an unintended or unanticipated manner.</p>
<p>What is Boundary Value Analysis?<br />
BVA is similar to Equivalence Partitioning but focuses on “corner cases” or values that are usually out of range as defined by the specification. his means that if a function expects all values in range of negative 100 to positive 1000, test inputs would include negative 101 and positive 1001.</p>
<p>What is Branch Testing?<br />
Testing in which all branches in the program source code are tested at least once.</p>
<p>What is Breadth Testing?<br />
A test suite that exercises the full functionality of a product but does not test features in detail.</p>
<p>What is CAST?<br />
Computer Aided Software Testing.<br />
What is CMMI?<br />
What do you like about computers?</p>
<p>Do you have a favourite QA book? More than one? Which ones? And why.</p>
<p>What is the responsibility of programmers vs QA?</p>
<p>What are the properties of a good requirement?</p>
<p>Ho to do test if we have minimal or no documentation about the product?</p>
<p>What are all the basic elements in a defect report?</p>
<p>Is an “A fast database retrieval rate” a testable requirement?</p>
<p>What is software quality assurance?</p>
<p>What is the value of a testing group? How do you justify your work and budget?</p>
<p>What is the role of the test group vis-à-vis documentation, tech support, and so forth?</p>
<p>How much interaction with users should testers have, and why?</p>
<p>How should you learn about problems discovered in the field, and what should you learn from those problems?</p>
<p>What are the roles of glass-box and black-box testing tools?</p>
<p>What issues come up in test automation, and how do you manage them?<br />
What is Capture/Replay Tool?<br />
A test tool that records test input as it is sent to the software under test. The input cases stored can then be used to reproduce the test at a later time. Most commonly applied to GUI test tools.</p>
<p>What is CMM?<br />
The Capability Maturity Model for Software (CMM or SW-CMM) is a model for judging the maturity of the software processes of an organization and for identifying the key practices that are required to increase the maturity of these processes.</p>
<p>What is Cause Effect Graph?<br />
A graphical representation of inputs and the associated outputs effects which can be used to design test cases.</p>
<p>What is Code Complete?<br />
Phase of development where functionality is implemented in entirety; bug fixes are all that are left. All functions found in the Functional Specifications have been implemented.</p>
<p>What is Code Coverage?<br />
An analysis method that determines which parts of the software have been executed (covered) by the test case suite and which parts have not been executed and therefore may require additional attention.<br />
What is Code Inspection?<br />
A formal testing technique where the programmer reviews source code with a group who ask questions analyzing the program logic, analyzing the code with respect to a checklist of historically common programming errors, and analyzing its compliance with coding standards.</p>
<p>What is Code Walkthrough?<br />
A formal testing technique where source code is traced by a group with a small set of test cases, while the state of program variables is manually monitored, to analyze the programmer’s logic and assumptions.</p>
<p>What is Coding?<br />
The generation of source code.</p>
<p>What is Compatibility Testing?<br />
Testing whether software is compatible with other elements of a system with which it should operate, e.g. browsers, Operating Systems, or hardware.<br />
What is Component?<br />
A minimal software item for which a separate specification is available.</p>
<p>What is Component Testing?<br />
See the question what is Unit Testing.</p>
<p>What is Concurrency Testing?<br />
Multi-user testing geared towards determining the effects of accessing the same application code, module or database records. Identifies and measures the level of locking, deadlocking and use of single-threaded code and locking semaphores.</p>
<p>What is Conformance Testing?<br />
The process of testing that an implementation conforms to the specification on which it is based. Usually applied to testing conformance to a formal standard.</p>
<p>What is Context Driven Testing?<br />
The context-driven school of software testing is flavor of Agile Testing that advocates continuous and creative evaluation of testing opportunities in light of the potential information revealed and the value of that information to the organization right now.<br />
What development model should programmers and the test group use?<br />
How do you get programmers to build testability support into their code?</p>
<p>What is the role of a bug tracking system?</p>
<p>What are the key challenges of testing?</p>
<p>Have you ever completely tested any part of a product? How?</p>
<p>Have you done exploratory or specification-driven testing?</p>
<p>Should every business test its software the same way?</p>
<p>Discuss the economics of automation and the role of metrics in testing.</p>
<p>Describe components of a typical test plan, such as tools for interactive products and for database products, as well as cause-and-effect graphs and data-flow diagrams.</p>
<p>When have you had to focus on data integrity?</p>
<p>What are some of the typical bugs you encountered in your last assignment?</p>
<p>How do you prioritize testing tasks within a project?</p>
<p>How do you develop a test plan and schedule? Describe bottom-up and top-down approaches.</p>
<p>When should you begin test planning?</p>
<p>When should you begin testing?</p>
<p>What is Conversion Testing?<br />
Testing of programs or procedures used to convert data from existing systems for use in replacement systems.</p>
<p>What is Cyclomatic Complexity?<br />
A measure of the logical complexity of an algorithm, used in white-box testing.</p>
<p>What is Data Dictionary?<br />
A database that contains definitions of all data items defined during analysis.</p>
<p>What is Data Flow Diagram?<br />
A modeling notation that represents a functional decomposition of a system.</p>
<p>What is Data Driven Testing?<br />
Testing in which the action of a test case is parameterized by externally defined data values, maintained as a file or spreadsheet. A common technique in Automated Testing.</p>
<p>What is Debugging?<br />
The process of finding and removing the causes of software failures.</p>
<p>What is Defect?<br />
Nonconformance to requirements or functional / program specification</p>
<p>What is Dependency Testing?<br />
Examines an application’s requirements for pre-existing software, initial states and configuration in order to maintain proper functionality.</p>
<p>What is Depth Testing?<br />
A test that exercises a feature of a product in full detail.</p>
<p>What is Dynamic Testing?<br />
Testing software through executing it. See also Static Testing.</p>
<p>What is Emulator?<br />
A device, computer program, or system that accepts the same inputs and produces the same outputs as a given system.<br />
What is Endurance Testing?<br />
Checks for memory leaks or other problems that may occur with prolonged execution.</p>
<p>What is End-to-End testing?<br />
Testing a complete application environment in a situation that mimics real-world use, such as interacting with a database, using network communications, or interacting with other hardware, applications, or systems if appropriate.</p>
<p>What is Equivalence Class?<br />
A portion of a component’s input or output domains for which the component’s behaviour is assumed to be the same from the component’s specification.</p>
<p>What is Equivalence Partitioning?<br />
A test case design technique for a component in which test cases are designed to execute representatives from equivalence classes.</p>
<p>What is Exhaustive Testing?<br />
Testing which covers all combinations of input values and preconditions for an element of the software under test.<br />
What is Functional Decomposition?<br />
A technique used during planning, analysis and design; creates a functional hierarchy for the software.</p>
<p>What is Functional Specification?<br />
A document that describes in detail the characteristics of the product with regard to its intended features.</p>
<p>What is Functional Testing?<br />
Testing the features and operational behavior of a product to ensure they correspond to its specifications.<br />
Testing that ignores the internal mechanism of a system or component and focuses solely on the outputs generated in response to selected inputs and execution conditions.<br />
See also What is Black Box Testing.</p>
<p>What is Glass Box Testing?<br />
A synonym for White Box Testing.<br />
Do you know of metrics that help you estimate the size of the testing effort?<br />
How do you scope out the size of the testing effort?</p>
<p>How many hours a week should a tester work?</p>
<p>How should your staff be managed? How about your overtime?</p>
<p>How do you estimate staff requirements?</p>
<p>What do you do (with the project tasks) when the schedule fails?</p>
<p>How do you handle conflict with programmers?</p>
<p>How do you know when the product is tested well enough?</p>
<p>What characteristics would you seek in a candidate for test-group manager?</p>
<p>What do you think the role of test-group manager should be? Relative to senior management? Relative to other technical groups in the company? Relative to your staff?</p>
<p>How do your characteristics compare to the profile of the ideal manager that you just described?</p>
<p>How does your preferred work style work with the ideal test-manager role that you just described? What is different between the way you work and the role you described?</p>
<p>Who should you hire in a testing group and why?<br />
What is Gorilla Testing?<br />
Testing one particular module, functionality heavily.</p>
<p>What is Gray Box Testing?<br />
A combination of Black Box and White Box testing methodologies? testing a piece of software against its specification but using some knowledge of its internal workings.</p>
<p>What is High Order Tests?<br />
Black-box tests conducted once the software has been integrated.</p>
<p>What is Independent Test Group (ITG)?<br />
A group of people whose primary responsibility is software testing,</p>
<p>What is Inspection?<br />
A group review quality improvement process for written material. It consists of two aspects; product (document itself) improvement and process improvement (of both document production and inspection).<br />
What is Integration Testing?<br />
Testing of combined parts of an application to determine if they function together correctly. Usually performed after unit and functional testing. This type of testing is especially relevant to client/server and distributed systems.</p>
<p>What is Installation Testing?<br />
Confirms that the application under test recovers from expected or unexpected events without loss of data or functionality. Events can include shortage of disk space, unexpected loss of communication, or power out conditions.</p>
<p>What is Load Testing?<br />
See Performance Testing.</p>
<p>What is Localization Testing?<br />
This term refers to making software specifically designed for a specific locality.</p>
<p>What is Loop Testing?<br />
A white box testing technique that exercises program loops.<br />
What is Metric?<br />
A standard of measurement. Software metrics are the statistics describing the structure or content of a program. A metric should be a real objective measurement of something such as number of bugs per lines of code.</p>
<p>What is Monkey Testing?<br />
Testing a system or an Application on the fly, i.e just few tests here and there to ensure the system or an application does not crash out.</p>
<p>What is Negative Testing?<br />
Testing aimed at showing software does not work. Also known as “test to fail”. See also Positive Testing.</p>
<p>What is Path Testing?<br />
Testing in which all paths in the program source code are tested at least once.</p>
<p>What is Performance Testing?<br />
Testing conducted to evaluate the compliance of a system or component with specified performance requirements. Often this is performed using an automated test tool to simulate large number of users. Also know as “Load Testing”.<br />
What is Positive Testing?<br />
Testing aimed at showing software works. Also known as “test to pass”. See also Negative Testing.</p>
<p>What is Quality Assurance?<br />
All those planned or systematic actions necessary to provide adequate confidence that a product or service is of the type and quality needed and expected by the customer.</p>
<p>What is Quality Audit?<br />
A systematic and independent examination to determine whether quality activities and related results comply with planned arrangements and whether these arrangements are implemented effectively and are suitable to achieve objectives.</p>
<p>What is Quality Circle?<br />
A group of individuals with related interests that meet at regular intervals to consider problems or other matters related to the quality of outputs of a process and to the correction of problems or to the improvement of quality.<br />
What is Quality Control?<br />
The operational techniques and the activities used to fulfill and verify requirements of quality.</p>
<p>What is Quality Management?<br />
That aspect of the overall management function that determines and implements the quality policy.</p>
<p>What is Quality Policy?<br />
The overall intentions and direction of an organization as regards quality as formally expressed by top management.</p>
<p>What is Quality System?<br />
The organizational structure, responsibilities, procedures, processes, and resources for implementing quality management.</p>
<p>What is Race Condition?<br />
A cause of concurrency problems. Multiple accesses to a shared resource, at least one of which is a write, with no mechanism used by either to moderate simultaneous access.</p>
<p>What is Ramp Testing?<br />
Continuously raising an input signal until the system breaks down.<br />
What is Recovery Testing?<br />
Confirms that the program recovers from expected or unexpected events without loss of data or functionality. Events can include shortage of disk space, unexpected loss of communication, or power out conditions.</p>
<p>What is Regression Testing?<br />
Retesting a previously tested program following modification to ensure that faults have not been introduced or uncovered as a result of the changes made.</p>
<p>What is Release Candidate?<br />
A pre-release version, which contains the desired functionality of the final version, but which needs to be tested for bugs (which ideally should be removed before the final version is released).</p>
<p>What is Sanity Testing?<br />
Brief test of major functional elements of a piece of software to determine if its basically operational. See also Smoke Testing.</p>
<p>What is Scalability Testing?<br />
Performance testing focused on ensuring the application under test gracefully handles increases in work load.<br />
What is the role of metrics in comparing staff performance in human resources management?<br />
How do you estimate staff requirements?</p>
<p>What do you do (with the project staff) when the schedule fails?</p>
<p>Describe some staff conflicts youÂ’ve handled.</p>
<p>Why did you ever become involved in QA/testing?</p>
<p>What is the difference between testing and Quality Assurance?</p>
<p>What was a problem you had in your previous assignment (testing if possible)? How did you resolve it?</p>
<p>What are two of your strengths that you will bring to our QA/testing team?</p>
<p>What do you like most about Quality Assurance/Testing?</p>
<p>What do you like least about Quality Assurance/Testing?</p>
<p>What is the Waterfall Development Method and do you agree with all the steps?</p>
<p>What is the V-Model Development Method and do you agree with this model?<br />
What is Security Testing?<br />
Testing which confirms that the program can restrict access to authorized personnel and that the authorized personnel can access the functions available to their security level.</p>
<p>What is Smoke Testing?<br />
A quick-and-dirty test that the major functions of a piece of software work. Originated in the hardware testing practice of turning on a new piece of hardware for the first time and considering it a success if it does not catch on fire.</p>
<p>What is Soak Testing?<br />
Running a system at high load for a prolonged period of time. For example, running several times more transactions in an entire day (or night) than would be expected in a busy day, to identify and performance problems that appear after a large number of transactions have been executed.</p>
<p>What is Software Requirements Specification?<br />
A deliverable that describes all data, functional and behavioral requirements, all constraints, and all validation requirements for software/</p>
<p>What is Software Testing?<br />
A set of activities conducted with the intent of finding errors in software.<br />
What is Static Analysis?<br />
Analysis of a program carried out without executing the program.</p>
<p>What is Static Analyzer?<br />
A tool that carries out static analysis.</p>
<p>What is Static Testing?<br />
Analysis of a program carried out without executing the program.</p>
<p>What is Storage Testing?<br />
Testing that verifies the program under test stores data files in the correct directories and that it reserves sufficient space to prevent unexpected termination resulting from lack of space. This is external storage as opposed to internal storage.</p>
<p>What is Stress Testing?<br />
Testing conducted to evaluate a system or component at or beyond the limits of its specified requirements to determine the load under which it fails and how. Often this is performance testing using a very high level of simulated load.<br />
What is Structural Testing?<br />
Testing based on an analysis of internal workings and structure of a piece of software. See also White Box Testing.</p>
<p>What is System Testing?<br />
Testing that attempts to discover defects that are properties of the entire system rather than of its individual components.</p>
<p>What is Testability?<br />
The degree to which a system or component facilitates the establishment of test criteria and the performance of tests to determine whether those criteria have been met.</p>
<p>What is Testing?<br />
The process of exercising software to verify that it satisfies specified requirements and to detect errors.<br />
The process of analyzing a software item to detect the differences between existing and required conditions (that is, bugs), and to evaluate the features of the software item (Ref. IEEE Std 829).<br />
The process of operating a system or component under specified conditions, observing or recording the results, and making an evaluation of some aspect of the system or component.<br />
What is Test Automation? It is the same as Automated Testing.</p>
<p>What is Test Bed?<br />
An execution environment configured for testing. May consist of specific hardware, OS, network topology, configuration of the product under test, other application or system software, etc. The Test Plan for a project should enumerated the test beds(s) to be used.<br />
What is Test Case?<br />
Test Case is a commonly used term for a specific test. This is usually the smallest unit of testing. A Test Case will consist of information such as requirements testing, test steps, verification steps, prerequisites, outputs, test environment, etc.<br />
A set of inputs, execution preconditions, and expected outcomes developed for a particular objective, such as to exercise a particular program path or to verify compliance with a specific requirement.<br />
Test Driven Development? Testing methodology associated with Agile Programming in which every chunk of code is covered by unit tests, which must all pass all the time, in an effort to eliminate unit-level and regression bugs during development. Practitioners of TDD write a lot of tests, i.e. an equal number of lines of test code to the size of the production code.</p>
<p>What is Test Driver?<br />
A program or test tool used to execute a tests. Also known as a Test Harness.</p>
<p>What is Test Environment?<br />
The hardware and software environment in which tests will be run, and any other software with which the software under test interacts when under test including stubs and test drivers.</p>
<p>What is Test First Design?<br />
Test-first design is one of the mandatory practices of Extreme Programming (XP).It requires that programmers do not write any production code until they have first written a unit test.<br />
What is a “Good Tester”?</p>
<p>Could you tell me two things you did in your previous assignment (QA/Testing related hopefully) that you are proud of?</p>
<p>List 5 words that best describe your strengths.</p>
<p>What are two of your weaknesses?</p>
<p>What methodologies have you used to develop test cases?</p>
<p>In an application currently in production, one module of code is being modified. Is it necessary to re- test the whole application or is it enough to just test functionality associated with that module?</p>
<p>How do you go about going into a new organization? How do you assimilate?</p>
<p>Define the following and explain their usefulness: Change Management, Configuration Management, Version Control, and Defect Tracking.</p>
<p>What is ISO 9000? Have you ever been in an ISO shop?</p>
<p>When are you done testing?</p>
<p>What is the difference between a test strategy and a test plan?</p>
<p>What is ISO 9003? Why is it important<br />
What is Test Harness?<br />
A program or test tool used to execute a tests. Also known as a Test Driver.</p>
<p>What is Test Plan?<br />
A document describing the scope, approach, resources, and schedule of intended testing activities. It identifies test items, the features to be tested, the testing tasks, who will do each task, and any risks requiring contingency planning. Ref IEEE Std 829.</p>
<p>What is Test Procedure?<br />
A document providing detailed instructions for the execution of one or more test cases.</p>
<p>What is Test Script?<br />
Commonly used to refer to the instructions for a particular test that will be carried out by an automated test tool.</p>
<p>What is Test Specification?<br />
A document specifying the test approach for a software feature or combination or features and the inputs, predicted results and execution conditions for the associated tests.<br />
What is Test Suite?<br />
A collection of tests used to validate the behavior of a product. The scope of a Test Suite varies from organization to organization. There may be several Test Suites for a particular product for example. In most cases however a Test Suite is a high level concept, grouping together hundreds or thousands of tests related by what they are intended to test.</p>
<p>What is Test Tools?<br />
Computer programs used in the testing of a system, a component of the system, or its documentation.</p>
<p>What is Thread Testing?<br />
A variation of top-down testing where the progressive integration of components follows the implementation of subsets of the requirements, as opposed to the integration of components by successively lower levels.</p>
<p>What is Top Down Testing?<br />
An approach to integration testing where the component at the top of the component hierarchy is tested first, with lower level components being simulated by stubs. Tested components are then used to test lower level components. The process is repeated until the lowest level components have been tested.<br />
What is Total Quality Management?<br />
A company commitment to develop a process that achieves high quality product and customer satisfaction.</p>
<p>What is Traceability Matrix?<br />
A document showing the relationship between Test Requirements and Test Cases.</p>
<p>What is Usability Testing?<br />
Testing the ease with which users can learn and use a product.</p>
<p>What is Use Case?<br />
The specification of tests that are conducted from the end-user perspective. Use cases tend to focus on operating software as an end-user would conduct their day-to-day activities.</p>
<p>What is Unit Testing?<br />
Testing of individual software components.<br />
What is Validation?<br />
The process of evaluating software at the end of the software development process to ensure compliance with software requirements. The techniques for validation is testing, inspection and reviewing<br />
What is Verification?<br />
The process of determining whether of not the products of a given phase of the software development cycle meet the implementation steps and can be traced to the incoming objectives established during the previous phase. The techniques for verification are testing, inspection and reviewing.<br />
What is Volume Testing?<br />
Testing which confirms that any values that may become large over time (such as accumulated counts, logs, and data files), can be accommodated by the program and will not cause the program to stop working or degrade its operation in any manner.</p>
<p>What is Walkthrough?<br />
A review of requirements, designs or code characterized by the author of the material under review guiding the progression of the review.<br />
What is White Box Testing?<br />
Testing based on an analysis of internal workings and structure of a piece of software. Includes techniques such as Branch Testing and Path Testing. Also known as Structural Testing and Glass Box Testing. Contrast with Black Box Testing.</p>
<p>What is Workflow Testing?<br />
Scripted end-to-end testing which duplicates specific workflows which are expected to be utilized by the end-user.<br />
What are ISO standards? Why are they important?<br />
What is IEEE 829? (This standard is important for Software Test Documentation-Why?)</p>
<p>What is IEEE? Why is it important?</p>
<p>Do you support automated testing? Why?</p>
<p>We have a testing assignment that is time-driven. Do you think automated tests are the best solution?</p>
<p>What is your experience with change control? Our development team has only 10 members. Do you think managing change is such a big deal for us?</p>
<p>Are reusable test cases a big plus of automated testing and explain why.</p>
<p>Can you build a good audit trail using Compuware’s QACenter products. Explain why.</p>
<p>How important is Change Management in today’s computing environments?</p>
<p>Do you think tools are required for managing change. Explain and please list some tools/practices which can help you managing change.</p>
<p>We believe in ad-hoc software processes for projects. Do you agree with this? Please explain your answer.</p>
<p>When is a good time for system testing?<br />
Are regression tests required or do you feel there is a better use for resources?</p>
<p>Our software designers use UML for modeling applications. Based on their use cases, we would like to plan a test strategy. Do you agree with this approach or would this mean more effort for the testers.</p>
<p>Tell me about a difficult time you had at work and how you worked through it.</p>
<p>Give me an example of something you tried at work but did not work out so you had to go at things another way.</p>
<p>How can one file compare future dated output files from a program which has change, against the baseline run which used current date for input. The client does not want to mask dates on the output files to allow compares<br />
Test Automation<br />
What automating testing tools are you familiar with?<br />
How did you use automating testing tools in your job?</p>
<p>Describe some problem that you had with automating testing tool.</p>
<p>How do you plan test automation?</p>
<p>Can test automation improve test effectiveness?</p>
<p>What is data – driven automation?</p>
<p>What are the main attributes of test automation?</p>
<p>Does automation replace manual testing?</p>
<p>How will you choose a tool for test automation?</p>
<p>How you will evaluate the tool for test automation?</p>
<p>What are main benefits of test automation?</p>
<p>What could go wrong with test automation?</p>
<p>How you will describe testing activities?</p>
<p>What testing activities you may want to automate?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pdftutorials.com/questions/testing-interview-questions.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SQL interview Questions</title>
		<link>http://www.pdftutorials.com/questions/sql-interview-questions.html</link>
		<comments>http://www.pdftutorials.com/questions/sql-interview-questions.html#comments</comments>
		<pubDate>Thu, 13 Oct 2011 13:36:07 +0000</pubDate>
		<dc:creator>Tutorial Master</dc:creator>
				<category><![CDATA[questions]]></category>

		<guid isPermaLink="false">http://www.pdftutorials.com/test/?p=3858</guid>
		<description><![CDATA[What is the full form of SQL ? Structured Query Language (SQL). It is pronounced “sequel”.SQl is a language that provides an interface to relational database systems. It was developed by IBM. What are two methods of retrieving SQL? What is a deadlock in SQL ? Deadlock is a situation when two processes, each having <a href="http://www.pdftutorials.com/questions/sql-interview-questions.html"> read more <span class="meta-nav">&#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p>What is the full form of SQL ?</p>
<p>Structured Query Language (SQL). It is pronounced “sequel”.SQl is a language that provides an interface to relational database systems. It was developed by IBM.</p>
<p>What are two methods of retrieving SQL?</p>
<p>What is a deadlock in SQL ?</p>
<p>Deadlock is a situation when two processes, each having a lock on one piece of data, attempt to acquire a lock on the other’s piece. Each process  would wait indefinitely for the other to release the lock, unless one of the user processes is terminated. SQL Server detects deadlocks and terminates one user’s process.</p>
<p>What is livelock in SQL ?</p>
<p>A livelock is one, where a  request for an exclusive lock is repeatedly denied because a series of overlapping shared locks keeps interfering. SQL Server detects the situation after four denials and refuses further shared locks. A livelock also occurs when read transactions monopolize a table or page, forcing a write transaction to wait indefinitely.</p>
<p>Some important system function to get the current user details</p>
<p>USER_ID()<br />
USER_NAME()<br />
SESSION_USER<br />
CURRENT_USER<br />
USER<br />
SUSER_SID()<br />
HOST_NAME().</p>
<p>What’s the difference between a primary key and a unique key?</p>
<p>Both primary key and unique enforce uniqueness of the column on which they are defined. But by default primary key creates a clustered index on the column, where are unique creates a nonclustered index by default. Another major difference is that, primary key doesn’t allow NULLs, but unique key allows one NULL only.</p>
<p>What cursor type do you use to retrieve multiple recordsets?</p>
<p>What is candidate key, alternate key, composite key in SQL ?</p>
<p>A candidate key is one that can identify each row of a table  uniquely.Generally a candidate key becomes the primary key of the table. If the table has more than one candidate key, one of them will become the primary key, and the rest are called alternate keys.A key formed by combining at least two or more columns is called composite key.</p>
<p>Explain the architecture of SQL Server</p>
<p>What is the difference between a “where” clause and a “having” clause in SQL ?</p>
<p>“Where” Clause in SQL is a kind of restiriction statement. You use where clause to restrict all the data from DB.Where clause is using before result retrieving. But Having clause is using after retrieving the data.Having clause is a kind of filtering command from the selected data.</p>
<p>What is the basic form of a SQL statement to read data out of a table?</p>
<p>Basic form to read data out of table in SQL is “SELECT * FROM tablename”. Answer with “where” close wont be proper because it is an additional thing with basic select statement.</p>
<p>What’s the maximum size of a row in SQL table?<br />
8060 bytes.</p>
<p>What are the tradeoffs with having indexes?</p>
<p>Faster selects<br />
slower updates<br />
Extra storage space to store indexes<br />
Updates are slower because in addition to updating the table you have to update the index.</p>
<p>What’s the difference between DELETE TABLE and TRUNCATE TABLE commands in SQL?</p>
<p>DELETE TABLE is a logged operation, so the deletion of each row gets logged in the transaction log, which makes it slow. TRUNCATE TABLE also deletes all the rows in a table, but it won’t log the deletion of each row, instead it logs the de allocation of the data pages of the table, which makes it faster. TRUNCATE TABLE can be rolled back</p>
<p>What is a “join” statement in SQL?<br />
‘join’ used to connect two or more tables logically with or without common field.</p>
<p>What is “normalization”? “Denormalization”? Why do you sometimes want to denormalize?</p>
<p>Normalizing data means eliminating redundant information from a table and organizing the data so that future changes to the table are easier. Denormalization means allowing redundancy in a table. The main benefit of denormalization is improved performance with simplified data retrieval and manipulation. This is done by reduction in the number of joins needed for data processing.</p>
<p>How to restart SQL Server?<br />
from command line, using the SQLSERVR.EXE.</p>
<p>-m is used for starting SQL Server in single user mode<br />
-f is used to start the SQL Server in minimal confuguration mode.</p>
<p>What is a “constraint” in SQL?</p>
<p>A constraint allows you to apply simple referential integrity checks to a table. There are four primary types of constraints that are currently supported by SQL Server</p>
<p>PRIMARY/UNIQUE – enforces uniqueness of a particular table column.<br />
DEFAULT – specifies a default value for a column in case an insert operation does not provide one.<br />
FOREIGN KEY – validates that every value in a column exists in a column of another table.<br />
CHECK – checks that every value stored in a column is in some specified list.<br />
NOT NULL is one more constraint which does not allow values in the specific column to be null. And also it the only constraint which is not a table level constraint.</p>
<p>Each type of constraint performs a specific type of action. Default is not a constraint.</p>
<p>Different Types of joins in SQL</p>
<p>INNER JOINs<br />
OUTER JOINs<br />
LEFT OUTER JOINS<br />
RIGHT OUTER JOINS<br />
FULL<br />
CROSS JOINs</p>
<p>What types of index data structures can you have?<br />
An index helps to faster search values in tables. The three most commonly used index-types are:</p>
<p>B-Tree: builds a tree of possible values with a list of row IDs that have the leaf value. Needs a lot of space and is the default index type for most databases.<br />
Bitmap: string of bits for each possible value of the column. Each bit string has one bit for each row. Needs only few space and is very fast.(however, domain of value cannot be large, e.g. SEX(m,f); degree(BS,MS,PHD)<br />
Hash: A hashing algorithm is used to assign a set of characters to represent a text string such as a composite of keys or partial keys, and compresses the underlying data. Takes longer to build and is supported by relatively few databases.</p>
<p>Types of cursors in SQL ?</p>
<p>Static<br />
Dynamic<br />
Forward-only<br />
Keyset-driven</p>
<p>What is a “primary key”?</p>
<p>Primary Key is a type of a constraint enforcing uniqueness and data integrity for each row of a table. All columns participating in a primary key constraint must possess the NOT NULL property.For example “user Id” should be unique for users, so we can make that field a s primary key in some tables for making sure that value wont repeat.</p>
<p>What is a “trigger”?</p>
<p>Triggers are stored procedures created in order to enforce integrity rules in a database. A trigger is executed every time a data-modification operation occurs (i.e., insert, update or delete). Triggers are executed automatically on occurrence of one of the data-modification operations. A trigger is a database object directly associated with a particular table. It fires whenever a specific statement/type of statement is issued against that table. The types of statements are insert,update,delete and query statements. Basically, trigger is a set of SQL statements A trigger is a solution to the restrictions of a constraint.</p>
<p>What is “index covering” of a query?<br />
Index covering means that “Data can be found only using indexes, without touching the tables”</p>
<p>What is a SQL view?</p>
<p>An output of a query can be stored as a view. View acts like small table which meets our criterion. View is a precomplied SQL query which is used to select data from one or more tables. A view is like a table but it doesn’t physically take any space. View is a good way to present data in a particular format if you use that query quite often. View can also be used to restrict users from accessing the tables directly.Its mainly used to view the data from various tables.</p>
<p>What is blocking and when it is happening?</p>
<p>Blocking happens when one connection from an application holds a lock and a second connection requires a conflicting lock type. This forces the second connection to wait, blocked on the first.</p>
<p>How do you implement one-to-one, one-to-many and many-to-many relationships while designing tables?</p>
<p>One-to-One relationship can be implemented as a single table and rarely as two tables with primary and foreign key relationships.One-to-Many relationships are implemented by splitting the data into two tables with primary key and foreign key relationships.Many-to-Many relationships are implemented using a junction table with the keys from both the tables forming the composite primary key of the junction table.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pdftutorials.com/questions/sql-interview-questions.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SAP ABAP INTERVIEW QUESTIONS</title>
		<link>http://www.pdftutorials.com/questions/sap-abap-interview-questions.html</link>
		<comments>http://www.pdftutorials.com/questions/sap-abap-interview-questions.html#comments</comments>
		<pubDate>Thu, 13 Oct 2011 13:35:31 +0000</pubDate>
		<dc:creator>Tutorial Master</dc:creator>
				<category><![CDATA[questions]]></category>

		<guid isPermaLink="false">http://www.pdftutorials.com/test/?p=3856</guid>
		<description><![CDATA[ABAP / 4 INTERVIEW QUESTIONS WITH ANSWERS 1)         What is SAP R/3? Ans      SAP R/3 refers to Systems Application and Product for data processing Real-time having a 3 tier architecture i.e. Presentation layer, Application layer and Database layer. 2)         What are the programming standards followed? 3)         What are the contents in technical specifications? Ans      There <a href="http://www.pdftutorials.com/questions/sap-abap-interview-questions.html"> read more <span class="meta-nav">&#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p>ABAP / 4 INTERVIEW QUESTIONS WITH ANSWERS</p>
<p>1)         What is SAP R/3?</p>
<p>Ans      SAP R/3 refers to Systems Application and Product for data processing Real-time having a 3 tier architecture i.e. Presentation layer, Application layer and Database layer.</p>
<p>2)         What are the programming standards followed?</p>
<p>3)         What are the contents in technical specifications?</p>
<p>Ans      There are five contents in Technical Settings: Data Class, Size Category, Buffering Permission, Buffering Type and Logging.</p>
<p>4)         What is an instance?</p>
<p>Ans      When you call a function module, an instance of its function group plus its data, is loaded into the memory area of the internal session. An ABAP program can load several instances by calling function modules from different function groups.</p>
<p>5)         How to take care of performance in ABAP Development?</p>
<p>6)         What is Function group? Difference between function group and function module?</p>
<p>Ans      Function Groups act as containers for Function Modules that logically belong together.</p>
<p>Function Groups</p>
<p>1)      These cannot be defined in a Function Module.</p>
<p>2)      It cannot be called.</p>
<p>3)      They are containers for Function Module.</p>
<p>Function Modules</p>
<p>1)      These must be defined in a Function Group.</p>
<p>2)      It can be called from any program.</p>
<p>3)      They are not containers for Function Group.</p>
<p>7)         What is the difference between ‘Select single * ‘ and ‘Select upto 1 rows’?</p>
<p>Ans      ‘Select single *’ – The result of the selection should be a single entry. If it is not possible to identify a unique entry, the system uses the first line of the selection. For e.g.</p>
<p>DATA : ITAB TYPE ZREKHA_EMP.</p>
<p>SELECT SINGLE * FROM ZREKHA_EMP INTO ITAB</p>
<p>WHERE EMPNO = ‘00101’ AND DEPTNO = ‘0010’.</p>
<p>WRITE : / ITAB-EMPNO, ITAB-EMPNAME,ITAB-DEPTNO.</p>
<p>Select upto 1 rows -</p>
<p>8)         What Function does data dictionary perform?</p>
<p>Ans      Central information repository for application and system data. The ABAP Dictionary contains data definitions (metadata) that allow you to describe all of the data structures in the system (like tables, views, and data types) in one place. This eliminates redundancy.</p>
<p>9)         Difference between domain and data element? What are aggregate object?</p>
<p>Ans      Domain – Specifies the technical attributes of a data element – its data type, length, possible values, and appearance on the screen. Each data element has an underlying domain. A single domain can be the basis for several data elements. Domains are objects in the ABAP Dictionary.</p>
<p>Data Element – Describes the business function of a table field. Its technical attributes are based on a domain, and its business function is described by its field labels and documentation.</p>
<p>Aggregate Object – Views, Match Code and Lock objects are called aggregate objects because they are formed from several related table.</p>
<p>10)       What is view? Different types of view. Explain?</p>
<p>Ans      View – A view is a virtual table containing fields from one or more tables. A virtual table that does not contain any data, but instead provides an application-oriented view of one or more ABAP Dictionary tables.</p>
<p>Different Types of View:</p>
<p>1)      Maintenance</p>
<p>2)      Database – It is on more than two tables.</p>
<p>3)      Projection – It is only on one table.</p>
<p>4)      Help</p>
<p>11)       Can u print decimals in type N? What is difference between float and packed data type?</p>
<p>Ans      No, we cannot print decimals in type N because decimal places are not permitted with N</p>
<p>data type.</p>
<p>Float Data Type: It cannot be declared in Parameters.</p>
<p>Packed Number: It can be declared in Parameters. For e.g.</p>
<p>PARAMETERS : A(4) TYPE P DECIMALS 2,</p>
<p>B(4) TYPE P DECIMALS 2.</p>
<p>DATA : C(4) TYPE P DECIMALS 2.</p>
<p>C = A + B.</p>
<p>WRITE : / ‘THE SUM IS’ , C.</p>
<p>12)       What is step-loop? Explain all the steps?</p>
<p>Ans      A step loop is a repeated series of field-blocks in a screen. Each block can contain one or more fields, and can extend over more than one line on the screen.</p>
<p>Step loops as structures in a screen do not have individual names. The screen can contain more than one step-loop, but if so, you must program the LOOP…ENDLOOPs in the flow logic accordingly. The ordering of the LOOP…ENDLOOPs must exactly parallel the order of the step loops in the screen. The ordering tells the system which loop processing to apply to which loop. Step loops in a screen are ordered primarily by screen row, and secondarily by screen column.</p>
<p>Transaction TZ61 (development class SDWA) implements a step loop version of the table you saw in transaction TZ60.</p>
<p>Static and Dynamic Step Loops</p>
<p>Step loops fall into two classes: static and dynamic. Static step loops have a fixed size that cannot be changed at runtime. Dynamic step loops are variable in size. If the user re-sizes the window, the system automatically increases or decreases the number of step loop blocks displayed. In any given screen, you can define any number of static step loops, but only a single dynamic one.</p>
<p>You specify the class for a step loop in the Screen Painter. Each loop in a screen has the attributes Looptype (fixed=static, variable=dynamic) and Loopcount. If a loop is fixed, the Loopcount tells the number of loop-blocks displayed for the loop. This number can never change.</p>
<p>Programming with static and dynamic step loops is essentially the same. You can use both the LOOP and LOOP AT statements for both types.</p>
<p>Looping in a Step Loop</p>
<p>When you use LOOP AT &lt;internal-table&gt; with a step loop, the system automatically displays the step loop with vertical scroll bars. The scroll bars, and the updated (scrolled) table display, are managed by the system.</p>
<p>Use the following additional parameters if desired:</p>
<p>FROM &lt;line1&gt; and TO &lt;line2&gt;<br />
CURSOR &lt;scroll-var&gt;<br />
14)       What are the ways to find out the tables used in the program?</p>
<p>Ans</p>
<p>15)       Can you have two detail lists from the basic list at the same time?</p>
<p>If yes how and if no why?</p>
<p>Ans</p>
<p>19)       What function module upload data from application server?</p>
<p>Ans</p>
<p>20)       What are the various types of selection screen event?</p>
<p>Ans      SELECTION-SCREEN BEGIN OF BLOCK ABC WITH FRAME TITLE T01.</p>
<p>SELECTION-SCREEN BEGIN OF SCREEN 500 AS WINDOW.</p>
<p>CALL SELECTION-SCREEN 500 STARTING AT 10 10.</p>
<p>21)       What do you know about a client?</p>
<p>Ans</p>
<p>22)       What are the system fields? Explain?</p>
<p>Ans      The ABAP system fields are active in all ABAP programs. They are filled by the runtime environment, and you can query their values in a program to find out particular states of the system. Although they are variables, you should not assign your own values to them, since this may overwrite information that is important for the normal running of the program. However, there are some isolated cases in which you may need to overwrite a system variable. For example, by assigning a new value to the field SY-LSIND, you can control navigation within details lists.</p>
<p>23)       What is SAP Script? What is the purpose of SAP Script? Difference between</p>
<p>SAP Script and Report?</p>
<p>Ans      SAP Script – It is the integrated text management system of the SAP R/3 System. Two types – PC Editor &amp; Line Editor.</p>
<p>Reports -  It is the way to display data fetched from database table onto screen or directly output it to a printer. Two types – Classical and Interactive.</p>
<p>24)       What is the use of occurs in internal table? Can u change occurs value in program?</p>
<p>Ans      Use of Occurs – If you use the OCCURS parameter, the value of the INITIAL SIZE of the table is returned to the variable &lt;n&gt;</p>
<p>Data :  Begin of ITAB occurs 0,</p>
<p>End of ITAB.</p>
<p>Occurs or Initial Size – to specify the initial amount of memory that should be assigned to the table.</p>
<p>Yes, we can change the occurs value in program but output remains the same.</p>
<p>25)       Difference between SY-TABIX and SY-INDEX? Where it is used?</p>
<p>Can u check SY-SUBRC after perform?</p>
<p>Ans      SY-TABIX – Current line of an internal table. SY-TABIX is set by the statements below, but only for index tables. The field is either not set or is set to 0 for hashed tables.</p>
<p>* APPEND sets SY-TABIX to the index of the last line of the table, that is, it contains the overall number of entries in the table.</p>
<p>* COLLECT sets SY-TABIX to the index of the existing or inserted line in the table. If the table has the type HASHED TABLE, SY-TABIX is set to 0.</p>
<p>* LOOP AT sets SY-TABIX to the index of the current line at the beginning of each loop lass. At the end of the loop, SY-TABIX is reset to the value that it had before entering the loop. It is set to 0 if the table has the type HASHED TABLE.</p>
<p>* READ TABLE sets SY-TABIX to the index of the table line read. If you use a binary search, and the system does not find a line, SY-TABIX contains the total number of lines, or one more than the total number of lines. SY-INDEX is undefined if a linear search fails to return an entry.</p>
<p>* SEARCH &lt;itab&gt; FOR sets SY-TABIX to the index of the table line in which the search string is found.</p>
<p>SY_INDEX – In a DO or WHILE loop, SY-INDEX contains the number of loop passes including the current pass.</p>
<p>16)       What are the different functions used in sap script? What are the parameters used in each Function?</p>
<p>Ans      There are three different functions used in SAP Script:</p>
<p>1) OPEN_FORM</p>
<p>2) WRITE_FORM</p>
<p>3) CLOSE_FORM</p>
<p>Parameters in Each Function:</p>
<p>1) OPEN_FORM–</p>
<p>Exporting</p>
<p>Form</p>
<p>Language</p>
<p>2) WRITE_FORM–</p>
<p>Exporting</p>
<p>Element</p>
<p>Window</p>
<p>3)   CLOSE_FORM</p>
<p>17)       What is sequence of event triggered in report?</p>
<p>Ans      There are 6 events in report:</p>
<p>1) Initialization</p>
<p>2) At Selection-Screen</p>
<p>3) Start-of-Selection</p>
<p>4) Get</p>
<p>5) Get Late</p>
<p>6) End-of-Selection</p>
<p>7) Top-of-Page</p>
<p> <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> End-of-Page</p>
<p>9) At Line Selection</p>
<p>10) At User Command</p>
<p>11) At PF (nn)</p>
<p>18)       What are standard layouts sets in the SAP Script?</p>
<p>Ans      There are four standard layouts in the SAP Script:</p>
<p>1) Header</p>
<p>2) Logo</p>
<p>3) Main Window</p>
<p>4) Footer</p>
<p>26)       Difference between UPLOAD and WS_UPLOAD?</p>
<p>Ans      UPLOAD – File transfer with dialog from presentation server file to internal table. Data which is available in a file on the presentation server is transferred in an internal table. ASCII &amp; Binary files can be transferred.</p>
<p>WS_UPLOAD – To read data from the presentation server into an internal table without a user dialog, use the function module WS_UPLOAD. The most important parameters are listed below.<br />
27)       Why did u switch to SAP?</p>
<p>Ans</p>
<p>28) What is a Logical Database?</p>
<p>Ans Logical Databases are special ABAP programs that retrieve data and make it available to application programs.</p>
<p>Use of LDB – is used to read data from database tables by linking them to executable ABAP programs.</p>
<p>29) What are the events used for Logical Database?</p>
<p>Ans Two Events –</p>
<p>1) GET – This is the most important event for executable programs that use a logical database. It occurs when the logical database has read a line from the node<br />
and made it available to the program in the work area declared using the statement NODES<br />
. The depth to which the logical database is read is determined by the GET statements2) PUT – The PUT statement directs the program flow according to the structure of</p>
<p>the logical database.</p>
<p>30) What is the difference between Get and Get Late?</p>
<p>Ans GET – After the logical database has read an entry from the node<br />
.GET LATE – After all of the nodes of the logical database have been processed that are below<br />
in the database hierarchy.31) What are the data types of Internal Tables?</p>
<p>Ans There are three types:</p>
<p>1) Line</p>
<p>2) Key</p>
<p>3) Table</p>
<p>32) What are the events used in ABAP in the order of execution?</p>
<p>Ans Events are:</p>
<p>1. INITIALIZATION</p>
<p>2. AT SELECTION-SCREEN</p>
<p>3. AT SELECTION-SCREEN ON</p>
<p>4. START-OF-SELECTION</p>
<p>5. TOP-OF-PAGE</p>
<p>6. TOP-OF-PAGE DURING LINE SELECTION</p>
<p>7. END-OF-PAGE</p>
<p>8. END-OF-SELECTION</p>
<p>9. AT USER-COMMAND</p>
<p>10. AT LINE-SELECTION</p>
<p>11. AT PF</p>
<p>12. GET</p>
<p>13. GET LATE.</p>
<p>14. AT User Command</p>
<p>33) What are Interactive Reports?</p>
<p>Ans An output list which displays just the basic details &amp; allow user to interact, so that a new list is populated based on user-selection. With interactive list, the user can actively control data retrieval and display during the session.</p>
<p>34) What are the commands used for interactive reports?</p>
<p>Ans Top-of-Page during line-selection</p>
<p>35) What are the system fields u have worked with? Explain?</p>
<p>Ans I had worked with the following (30) system fields:</p>
<p>1) SY-DBSYS – Central Database</p>
<p>2) SY-HOST – Server</p>
<p>3) SY-OPSYS – Operating System</p>
<p>4) SY-SAPRL – SAP Release</p>
<p>5) SY-SYSID – System Name</p>
<p>6) SY-LANGU – User Logon Language</p>
<p>7) SY-MANDT – Client</p>
<p> <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> SY-UNAME – Logon User Name</p>
<p>9) SY-DATLO – Local Date</p>
<p>10) SY-DATUM – Server Date</p>
<p>11) SY-TIMLO – Local Time</p>
<p>12) SY-UZEIT – Server Time</p>
<p>13) SY-DYNNR – Screen Number</p>
<p>14) SY-REPID – Current ABAP program</p>
<p>15) SY-TCODE – Transaction Code</p>
<p>16) SY-ULINE – Horizontal Line</p>
<p>17) SY-VLINE – Vertical Line</p>
<p>18) SY-INDEX – Number of current loop Pass</p>
<p>19) SY-TABIX – Current line of internal table</p>
<p>20) SY-DBCNT – Number of table entries processed</p>
<p>21) SY-SUBRC – Return Code</p>
<p>22) SY-UCOMM – Function Code</p>
<p>23) SY-LINCT – Page Length of list</p>
<p>24) SY-LINNO – Current Line</p>
<p>25) SY-PAGNO – Current Page Number</p>
<p>26) SY-LSIND – Index of List</p>
<p>27) SY-MSGID – Message Class</p>
<p>28) SY-MSGNO – Message Number</p>
<p>29) SY-MSGTY – Message Type</p>
<p>30) SY-SPONO – Spool number during printing</p>
<p>36) What is the difference between Primary key and Unique Key?</p>
<p>Ans Primary Key – It can accepts 0 value and cannot be NULL.</p>
<p>Unique Key – It can be NULL.</p>
<p>37) What is the transaction code for Table maintenance?</p>
<p>Ans SM30</p>
<p>38) If u are using Logical Databases how will u modify the selection-screen elements?</p>
<p>Ans Select-options : dname for deptt-dname.</p>
<p>39) What is an RFC?</p>
<p>Ans Remote Function Call</p>
<p>40) If u are using RFC and passing values to a remote system how does it work?</p>
<p>Ans</p>
<p>41) What are the events in Screen Programming?</p>
<p>Ans There are two events in Screen Programming:</p>
<p>1. PBO (Process Before Output) – Before the screen is displayed, the PBO event is processed.<br />
2. PAI (Process After Input) – When the user interacts with the screen, the PAI event is processed.<br />
3. POH (Process On Help) – are triggered when the user requests field help (F1). You can program the appropriate coding in the corresponding event blocks. At the end of processing, the system carries on processing the current screen.<br />
4. POV (Process On Value) – are triggered when the user requests possible values help (F4). You can program the appropriate coding in the corresponding event blocks. At the end of processing, the system carries on processing the current screen.</p>
<p>42) What is the significance of HIDE?</p>
<p>Ans Its stores the click value and display the related record in the secondary list.</p>
<p>43) Where do u code the HIDE statement?</p>
<p>Ans In a LOOP statement</p>
<p>44) Types of BDC’s?</p>
<p>Ans There are two types of BDC’s:</p>
<p>1) Transaction Method</p>
<p>2) Session Method</p>
<p>45) Advantages &amp; Disadvantages of different types of BDC’s?</p>
<p>Ans Transaction Method:</p>
<p>1) It is faster than session method.</p>
<p>2) While executing, it starts from starting.</p>
<p>Session Method:</p>
<p>1) It is slower than transaction method.</p>
<p>2) While executing, it does not start from starting.</p>
<p>46) What are the events used in Interactive Reports.</p>
<p>Ans There are three events of Interactive Reports:</p>
<p>I. At PF(nn)</p>
<p>II. At line-selection</p>
<p>III. At user-command</p>
<p>47) What is an RDBMS?</p>
<p>Ans RDBMS – Relational Database Management System. It helps to create relationship between two or more table.</p>
<p>48) What standards u use to follow while coding ABAP programs?</p>
<p>Ans</p>
<p>49) What will you code in START-OF-SELECTION &amp; END-OF-SELECTON &amp; why?</p>
<p>Ans START-OF-SELECTION</p>
<p>SELECT * FROM DEPTT INTO CORRESPONDING FIELDS OF ITAB</p>
<p>WHERE DEPTNO IN DEPTNO.</p>
<p>APPEND ITAB.</p>
<p>ENDSELECT.</p>
<p>LOOP AT ITAB.</p>
<p>WRITE : / 10 ITAB-DEPTNO.</p>
<p>HIDE : ITAB-DEPTNO.</p>
<p>ENDLOOP.</p>
<p>END-OF-SELECTION</p>
<p>50) What are joins and different types joins?</p>
<p>Ans There are four types of Joins:</p>
<p>1) Self Join</p>
<p>2) Inner Join</p>
<p>3) Outer Join</p>
<p>4) Equi Join</p>
<p>51) Which is the default join?</p>
<p>Ans</p>
<p>52) How do u display a data in a Detail List?</p>
<p>Ans By using two statements:</p>
<p>1) Top-of-page during line-selection</p>
<p>2) At line-selection</p>
<p>53) What are the types of windows in SAP Script?</p>
<p>Ans There are five Standard Layouts in SAP Script:</p>
<p>1) Page</p>
<p>2) Window</p>
<p>3) Page Window</p>
<p>4) Paragraph Format</p>
<p>5) Character Format</p>
<p>54) What are the function modules used in a SAP Script driver program?</p>
<p>Ans There are three functions used in SAP Script:</p>
<p>1) OPEN_FORM</p>
<p>2) WRITE_FORM</p>
<p>3) CLOSE_FORM</p>
<p>55) What are Extracts?</p>
<p>Ans Extracts are dynamic sequential datasets in which different lines can have different structures. We can access the individual records in an extract dataset using a LOOP.</p>
<p>56) How would u go about improving the performance of a Program, which selects data from MSEG &amp; MKPF?</p>
<p>Ans</p>
<p>57) How does System work in case of an Interactive Report?</p>
<p>Ans</p>
<p>58) What is LUW?</p>
<p>Ans Logical Unit of Work</p>
<p>59) Different types of LUWs. What r they?</p>
<p>Ans Two types of LUW are:</p>
<p>1) DB LUW – A database LUW is the mechanism used by the database to ensure that its data is always consistent. A database LUW is an inseparable sequence of database operations that ends with a database commit. The database LUW is either fully executed by the database system or not at all. Once a database LUW has been successfully executed, the database will be in a consistent state. If an error occurs within a database LUW, all of the database changes since the beginning of the database LUW are reversed. This leaves the database in the state it had before the transaction started.</p>
<p>2) SAP LUW – A logical unit consisting of dialog steps, whose changes are written to the database in a single database LUW is called an SAP LUW. Unlike a database LUW, an SAP LUW can span several dialog steps, and be executed using a series of different work processes.</p>
<p>60) What is First event triggered in program?</p>
<p>Ans</p>
<p>61) What are various Joins? What is right outer join?</p>
<p>Ans</p>
<p>62) How do u find out whether a file exits on the presentation server?</p>
<p>Ans eps_get_directory_listing for directory</p>
<p>63) Systems fields used for Interactive Lists AND Lists</p>
<p>Ans Interactive System Fields: SY-LSIND, SY-CPAGE, SY-LILLI, SY-LISEL, SY-LISTI,</p>
<p>SY-LSTAT, SY-STACO, SY-STARO</p>
<p>Lists: SY-COLNO, SY-LINCT, SY-LINNO, SY-LINSZ, SY-PAGNO,</p>
<p>SY-TVAR0…..SY-TVAR9, SY-WTITL</p>
<p>64) Logo in SAP Script?</p>
<p>Ans RSTXLDMC OR</p>
<p>Steps for making and inserting Logo in SAP Script:</p>
<p>First Procedure:</p>
<p>1) Draw the picture</p>
<p>2) Save it</p>
<p>3) /nSE78</p>
<p>4) Write name &amp; Choose Color</p>
<p>5) Click on Import</p>
<p>6) Browse picture</p>
<p>7) Enter</p>
<p>Second Procedure</p>
<p>1) /nSE71</p>
<p>2) Insert</p>
<p>3) Graphics</p>
<p>4) Click on stored on document server</p>
<p>5) Execute</p>
<p>6) Choose name of BMAP</p>
<p>65) What are the difference between call screen and leave screen?</p>
<p>Ans Call Screen: Calling a single screen is a special case of embedding a screen sequence. If you want to prevent the called screen from covering the current screen completely, you can use the CALL SCREEN statement with the STARTING AT and ENDING AT</p>
<p>CALL SCREEN 1000.</p>
<p>CALL SCREEN 1000 STARTING AT 10 10 ENDING AT 20 20.</p>
<p>LEAVE SCREEN statement ends the current screen and calls the subsequent screen.</p>
<p>LEAVE SCREEN.</p>
<p>LEAVE TO SCREEN 2000.</p>
<p>66) If internal table used in for all entries in empty then what happens</p>
<p>Ans No, records will be displayed.</p>
<p>67) If I forgot some command in SAP Script e.g.: suppress zero display – How to do find it?</p>
<p>Ans Suppressing of entire screens is possible with this command. This command allows us to perform screen processing “in the background”. Suppressing screens is useful when we are branching to list-mode from a transaction dialog step.</p>
<p>68) How to write a BDC – how do u go about it?</p>
<p>Ans Steps for writing BDC</p>
<p>1) /nSE38</p>
<p>2) Declare Tables, Data (for ITAB) and Data (for BDCITAB)</p>
<p>3) Call function ‘Upload’.</p>
<p>4) Write code for the First Screen, Radio Button, Filename, Change Button, Second Screen, Utilities (Create Entries), Third Screen and Save.</p>
<p>5) Call transaction ‘SE11’ using BDCITAB mode ‘A’.</p>
<p>6) Save, Check Errors, Activate and Execute.</p>
<p>69) What is Performance tuning?</p>
<p>Ans</p>
<p>70) Define Documentation.</p>
<p>Ans</p>
<p>71) Brief about Testing of programs.</p>
<p>Ans</p>
<p>72) How do u move on to the next screen in interactive reporting?</p>
<p>Ans Write code of the following:</p>
<p>1) Top-of-Page during line-selection</p>
<p>2) At line-selection</p>
<p>73) Create any functions? How to go about it?</p>
<p>Ans Steps for creating the Functions:</p>
<p>First Procedure:</p>
<p>1) /nSE37</p>
<p>2) Goto</p>
<p>3) Function Group (FG)</p>
<p>4) Create Group</p>
<p>5) Name of FG (ZREKHA_FG)</p>
<p>6) Short Text</p>
<p>7) Save</p>
<p> <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> Local Object</p>
<p>Second Procedure</p>
<p>1) Environment</p>
<p>2) Inactive Object</p>
<p>3) Function Group (ZREKHA_FG)</p>
<p>4) Activate</p>
<p>5) Back</p>
<p>Third Procedure</p>
<p>1) Name of Function Module (ZREKHA_FM)</p>
<p>2) Create</p>
<p>3) Write FG Name (ZREKHA_FG)</p>
<p>4) Short Text</p>
<p>5) Save</p>
<p>Fourth Step:</p>
<p>Call function ‘ZREKHA_FM’.</p>
<p>74) Advanced topics?</p>
<p>Ans</p>
<p>75) Function modules used in F4 help.</p>
<p>Ans There are two types of function modules used in F4 help:</p>
<p>1) F4IF_FIELD_VALUE_REQUEST</p>
<p>2) F4IF_INT_TABLE_VALUE_REQUEST</p>
<p>76) Work most on which module: Name a few tables.</p>
<p>Ans Sales &amp; Distribution Module</p>
<p>1) Sales Document: Item Data – VBAP</p>
<p>2) Sales Document: Partner – VBPA</p>
<p>3) Sales Document: Header Data – VBAK</p>
<p>4) Sales Document Flow – VBFA</p>
<p>5) Sales Document: Delivery Item Data – LIPS</p>
<p>6) Customer Master – KNA1</p>
<p>7) Material Data – MARA</p>
<p> <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> Conditions (Transaction Data) – KONV</p>
<p>77) System Table used</p>
<p>Ans</p>
<p>1) Sales Document: Item Data – VBAP</p>
<p>2) Sales Document: Partner – VBPA</p>
<p>3) Sales Document: Header Data – VBAK</p>
<p>4) Sales Document Flow – VBFA</p>
<p>5) Sales Document: Delivery Item Data – LIPS</p>
<p>6) Customer Master – KNA1</p>
<p>7) Material Data – MARA</p>
<p> <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> Conditions (Transaction Data) – KONV</p>
<p>78) From a table how do u find whether a material is used in another material BOM?</p>
<p>Ans</p>
<p>79) What is read line?</p>
<p>Ans READ LINE and READ CURRENT LINE – These statements are used to read data from the lines of existing list levels. These statements are closely connected to the HIDE technique.</p>
<p>80) How u used logical database? How is data transferred to program? Corresponding statement in LDB.</p>
<p>Ans</p>
<p>81) How do u suppress fields on selection screen generated by LDB?</p>
<p>Ans</p>
<p>82) Can there be more than 1 main window in SAP Script?</p>
<p>Ans No, there cannot be more than 1 main window in SAP Script because in WRITE_FORM, it asks for the parameter Window that will create the problem.</p>
<p>WRITE_FORM–</p>
<p>Exporting</p>
<p>Element</p>
<p>Window</p>
<p>83) Global and local data in function modules.</p>
<p>Ans</p>
<p>84) What are the differences between SAP memory and ABAP memory?</p>
<p>Ans ABAP Memory is a memory area in the internal session (roll area) of an ABAP program. Data within this area is retained within a sequence of program calls, allowing you to pass data between programs that call one another. It is also possible to pass data between sessions using SAP Memory.</p>
<p>SAP Memory is a memory area to which all sessions within a SAPgui have access. You can use SAP memory either to pass data from one program to another within a session (as with ABAP memory) or to pass data from one session to another.</p>
<p>85) What are differences between At selection-screen and At selection-screen output?</p>
<p>Ans AT SELECTION-SCREEN event is triggered in the PAI of the selection screen once the ABAP runtime environment has passed all of the input data from the selection screen to the ABAP program.</p>
<p>AT SELECTION-SCREEN OUTPUT – This event block allows you to modify the selection screen directly before it is displayed.</p>
<p>86) What are the events?</p>
<p>Ans</p>
<p>87) What is get cursor field?</p>
<p>Ans GET CURSOR statement transfers the name of the screen element on which the cursor is positioned during a user action into the variable .</p>
<p>GET CURSOR FIELD [OFFSET ] [LINE<br />
] [VALUE ] LENGTH ].</p>
<p>88) What is the inside concept in select-options?</p>
<p>Ans Select-options specify are displayed on the selection screen for the user to enter values.</p>
<p>Different Properties of Select-options:</p>
<p>1) Visible Length</p>
<p>2) Matchcode Object</p>
<p>3) Memory ID</p>
<p>4) Lowercase</p>
<p>5) Obligatory</p>
<p>6) No Display</p>
<p>7) Modify ID</p>
<p>89) What is the difference between occurs 1 and occurs 2?</p>
<p>Ans</p>
<p>90) What is the difference between Free and Refresh?</p>
<p>Ans Free – You can use FREE to initialize an internal table and release its memory space without first using the REFRESH or CLEAR statement. Like REFRESH, FREE works on the table body, not on the table work area. After a FREE statement, you can address the internal table again. It still occupies the amount of memory required for its header (currently 256 bytes). When you refill the table, the system has to allocate new memory space to the lines.</p>
<p>Refresh – This always applies to the body of the table. As with the CLEAR statement, the memory used by the table before you initialized it remains allocated. To release the memory space, use the statement</p>
<p>91) What are elements?</p>
<p>Ans</p>
<p>92) Can we have more than one selection-screen and how?</p>
<p>Ans Yes, we can have more than one selection screen.</p>
<p>Selection-screen begin of block honey with frame title text-101.</p>
<p>Select-options : deptno for zrekha_deptt-deptno.</p>
<p>Selection-screen end of block honey.</p>
<p>Selection-screen begin of block honey1 with frame title text-102.</p>
<p>Select-options : dname for zrekha_deptt-dname.</p>
<p>Selection-screen end of block honey1.</p>
<p>93) How to declare select-option as a parameter?</p>
<p>Ans SELECT-OPTIONS: specify are displayed on the selection screen for the user to enter values.</p>
<p>Parameters: dname like dept-dname.</p>
<p>Select-options: dname for dept-dname.</p>
<p>94) How can u write programmatically value help to a field without using search help and</p>
<p>match codes?</p>
<p>Ans By using two types of function modules to be called in SAP Script:</p>
<p>1) HELP_OBJECT_SHOW_FOR_FIELD</p>
<p>2) HELP_OBJECT_SHOW</p>
<p>95) What are the differences between SE01, SE09 and SE10?</p>
<p>Ans SE01 – Correction &amp; Transport Organizer</p>
<p>SE09 – Workbench Organizer</p>
<p>SE10 – Customizing Organizer</p>
<p>96) How to set destination?</p>
<p>Ans</p>
<p>97) What are the function module types?</p>
<p>Ans</p>
<p>98) What are tables?</p>
<p>Ans Tables : ZREKHA_EMP.</p>
<p>It creates a structure – the table work area in a program for the database tables, views or structure ZREKHA_EMP. The table work area has the same name as the object for which we created it. ZREKHA_EMP must be declared in the ABAP dictionary. The name and sequence of fields in the table work area ZREKHA_EMP corresponds exactly to the sequence of fields in the database table, view definition in the ABAP dictionary.</p>
<p>99) What are client-dependant tables and independent tables?</p>
<p>Ans</p>
<p>100) How to distinguish client-dependant tables from independent tables?</p>
<p>Ans</p>
<p>101) What is the use of Table maintenance allowed?</p>
<p>Ans Mark the Table maintenance allowed flag if users with the corresponding authorization may change the data in the table using the Data Browser (Transaction SE16). If the data in the table should only be maintained with programs or with the table view maintenance transaction (Transaction SM30), you should not set the flag.</p>
<p>102) How to define Selection Screen?</p>
<p>Ans Parameters, Select-options &amp; Selection-Screen</p>
<p>103) What are the check tables and value tables?</p>
<p>Ans Check Table: The ABAP Dictionary allows you to define relationships between tables using foreign keys . A dependent table is called a foreign key table, and the referenced table is called the check table. Each key field of the check table corresponds to a field in the foreign key table. These fields are called foreign key fields. One of the foreign key fields is designated as the check field for checking the validity of values. The key fields of the check table can serve as input help for the check field.</p>
<p>Value Table: Prior to Release 4.0, it was possible to use the value table of a domain to provide input help. This is no longer possible, primarily because unexpected results could occur if the value table had more than one key field. It was not possible to restrict the other key fields, which meant that the environment of the field was not considered, as is normal with check tables.</p>
<p>In cases where this kind of value help was appropriate, you can reconstruct it by creating a search help for the data elements that use the domain in question, and using the value table as the selection method.</p>
<p>Check table will be at field level checking.</p>
<p>Value table will be at domain level checking ex: scarr table is check table for carrid.</p>
<p>104) What is the difference between tables and structures?</p>
<p>Ans Tables:</p>
<p>1) Data is permanently stored in tables in the database.</p>
<p>2) Database tables are generated from them.</p>
<p>Structure:</p>
<p>1) It contains data temporarily during program run-time.</p>
<p>2) No Database tables are generated from it.</p>
<p>105) How to declare one internal table without header line without using structures?</p>
<p>Ans No, we cannot declare internal table without header line and without structure because it gives error “ITAB cannot be a table, a reference, a string or contain any of these object”.</p>
<p>Code with Header without Structure</p>
<p>TABLES : ZREKHA_EMP.</p>
<p>DATA : ITAB LIKE ZREKHA_EMP OCCURS 0 WITH HEADER LINE.</p>
<p>SELECT * FROM ZREKHA_EMP INTO CORRESPONDING FIELDS OF ITAB.</p>
<p>APPEND ITAB.</p>
<p>ENDSELECT.</p>
<p>LOOP AT ITAB.</p>
<p>WRITE : / ITAB-EMPNO, ITAB-EMPNAME,ITAB-DEPTNO.</p>
<p>ENDLOOP.</p>
<p>Code without Header with Structure</p>
<p>TABLES : ZREKHA_EMP.</p>
<p>DATA : BEGIN OF ITAB OCCURS 0,</p>
<p>EMPNO LIKE XREKHA_EMP-EMPNO,</p>
<p>EMPNAME LIKE XREKHA_EMP-EMPNAME,</p>
<p>DEPTNO LIKE XREKHA_EMP-DEPTNO,</p>
<p>END OF ITAB.</p>
<p>SELECT * FROM ZREKHA_EMP INTO CORRESPONDING FIELDS OF ITAB.</p>
<p>APPEND ITAB.</p>
<p>ENDSELECT.</p>
<p>LOOP AT ITAB.</p>
<p>WRITE : / ITAB-EMPNO, ITAB-EMPNAME,ITAB-DEPTNO.</p>
<p>ENDLOOP.</p>
<p>106) What are lock objects?</p>
<p>Ans Reason for Setting Lock: Suppose a travel agent want to book a flight. The customer wants to fly to a particular city with a certain airline on a certain day. The booking must only be possible if there are still free places on the flight. To avoid the possibility of overbooking, the database entry corresponding to the flight must be locked against access from other transactions. This ensures that one user can find out the number of free places, make the booking, and change the number of free places without the data being changed in the meantime by another transaction.</p>
<p>The R/3 System synchronizes simultaneous access of several users to the same data records with a lock mechanism. When interactive transactions are programmed, locks are set and released by calling function modules (see Function Modules for Lock Requests). These function modules are automatically generated from the definition of lock objects in the ABAP Dictionary.</p>
<p>Two types of Lock: Shared and Exclusive</p>
<p>107) What are datasets? What are the different syntaxes?</p>
<p>Ans The sequential files (ON APPLICATION SERVER) are called datasets. They are used for file handling in SAP.</p>
<p>OPEN DATASET [DATASET NAME] FOR [OUTPUT / INPUT / APPENDING]</p>
<p>IN [BINARY / TEXT] MODE</p>
<p>AT POSITION [POSITION]</p>
<p>MESSAGE [FIELD]</p>
<p>READ DATASET [DATASET NAME] INTO [FIELD]</p>
<p>DELETE DATASET [DATASET NAME]</p>
<p>CLOSE DATASET [DATASET NAME]</p>
<p>TRANSFER [FIELD] TO [DATASET NAME]</p>
<p>108) What are the events we use in dialog programming and explain them?</p>
<p>Ans There are two events in Dialog Programming i.e. screen:</p>
<p>1. PBO (Process Before Output) – Before the screen is displayed, the PBO event is processed.<br />
2. PAI (Process After Input) – When the user interacts with the screen, the PAI event is processed.<br />
3. POH (Process On Help) – are triggered when the user requests field help (F1). You can program the appropriate coding in the corresponding event blocks. At the end of processing, the system carries on processing the current screen.<br />
4. POV (Process On Value) – are triggered when the user requests possible values help (F4). You can program the appropriate coding in the corresponding event blocks. At the end of processing, the system carries on processing the current screen.</p>
<p>109) What is the difference between OPEN_FORM and CLOSE_FORM?</p>
<p>Ans OPEN_FORM – This module opens layout set printing. This function must be called up before we can work with other layout set function like WRITE_FORM.</p>
<p>WRITE_FORM – Output text element in form window. The specified element of the layout set window entered is output. The element must be defined in the layout set.</p>
<p>CLOSE_FORM – End layout set printing. Form printing started with OPEN_FORM is completed. Possible closing operations on the form last opened are carried out. Form printing must be completed by this function module. If this is not carried out, nothing is printed or displayed on the screen.</p>
<p>110) What are the page windows? How many main windows will be there in a page window?</p>
<p>Ans Page Window: In this window, we define the margins for left, width, upper and height for the layout of Header, Logo, Main, &amp; Footer.</p>
<p>111)     What are control events in a loop?</p>
<p>Ans      Control level processing is allowed within a LOOP over an internal table. This means that we can divide sequences of entries into groups based on the contents of certain fields.</p>
<p>AT &lt;level&gt;.<br />
&lt;statement block&gt;<br />
ENDAT.<br />
112)     How to debugg a script?</p>
<p>Ans      Go to SE71, give layout set name, go to utilities select debugger mode on.</p>
<p>113)     How many maximum sessions can be open in SAPgui?</p>
<p>Ans      There are maximum 6 sessions open in SAPgui.</p>
<p>114)     SAP Scripts and ABAP programs are client dependent or not? Why?</p>
<p>Ans</p>
<p>115)     What are System Variable?</p>
<p>Ans      System variables have been predefined by SAP. We can use these variables in formulas or, for example, to pass on certain pieces of information to a function module. How the function called by the function module behaves depends on the type of information passed on.<br />
116)     Is it compulsory to use all the events in Reports?</p>
<p>Ans</p>
<p>117) What is the difference between sum and collect?</p>
<p>Ans Sum: You can only use this statement within a LOOP. If you use SUM in an AT – ENDAT block, the system calculates totals for the numeric fields of all lines in the current line group and writes them to the corresponding fields in the work area. If you use the SUM statement outside an AT – ENDAT block (single entry processing), the system calculates totals for the numeric fields of all lines of the internal table in each loop pass and writes them to the corresponding fields of the work area. It therefore only makes sense to use the SUM statement in AT…ENDAT blocks.</p>
<p>If the table contains a nested table, you cannot use the SUM statement. Neither can you use it if you are using a field symbol instead of a work area in the LOOP statement.</p>
<p>Collect:</p>
<p>118) What are session method and call transaction method and explain about them?</p>
<p>Ans Session method – Use the BDC_OPEN_GROUP to create a session. Once we have created a session, then we can insert the batch input data into it with BDC_INSERT. Use the BDC_INSERT to add a transaction to a batch input session. We specify the transaction that is to be started in the call to BDC_INSERT. We must provide a BDCDATA structure that contains all the data required to process the transaction completely. Use the BDC_CLOSE_GROUP to close a session after we have inserted all of our batch input data into it. Once a session is closed, it can be processed.</p>
<p>Call Transaction -</p>
<p>In this method, we use CALL TRANSACTION USING to run an SAP transaction. External data does not have to be deposited in a session for later processing. Instead, the entire batch input process takes place inline in our program.</p>
<p>119) If you have 10000 records in your file, which method you use in BDC?</p>
<p>Ans Call transaction is faster then session method. But usually we use session method in real time…because we can transfer large amount of data from internal table to database and if any errors in a session, then process will not complete until session get correct.</p>
<p>120) What are different modes of Call Transaction method and explain them?</p>
<p>Ans There are three modes of Call Transaction method:</p>
<p>1) A – Display All Screens</p>
<p>2) E – Display Errors</p>
<p>3) N – Background Processing</p>
<p>——————————————————————————————————————–</p>
<p>121) What is the typical structure of an ABAP program?</p>
<p>Ans HEADER, BODY, FOOTER.</p>
<p>122) What are field symbols and field groups? Have you used “component idx of structure” clause with field groups?</p>
<p>Ans Field Symbols – They are placeholder or symbolic names for the other fields. They do not physically reserve space for a field, but point to its contents. It can point to any data objects.</p>
<p>Field-symbols</p>
<p>Field Groups – Field groups does not reserve storage space but contains pointers to existing fields.</p>
<p>An extract dataset consists of a sequence of records. These records may have different structures. All records with the same structure form a record type. You must define each record type of an extract dataset as a field group, using the FIELD-GROUPS statement.</p>
<p>Field-groups</p>
<p>123) What should be the approach for writing a BDC program?</p>
<p>Ans STEP 1: CONVERTING THE LEGACY SYSTEM DATA TO A FLAT FILE</p>
<p>to internal table CALLED “CONVERSION”.</p>
<p>STEP 2: TRANSFERING THE FLAT FILE INTO SAP SYSTEM CALLED</p>
<p>“SAP DATA TRANSFER”.</p>
<p>STEP 3: DEPENDING UPON THE BDC TYPE</p>
<p>i) Call transaction (Write the program explicitly)</p>
<p>ii) Create sessions (sessions are created and processed. If success, data will transfer).</p>
<p>124) What is a batch input session?</p>
<p>Ans BATCH INPUT SESSION is an intermediate step between internal table and database table. Data along with the action is stored in session i.e. data for screen fields, to which screen it is passed, program name behind it, and how next screen is processed.</p>
<p>Create session – BDC_OPEN_GROUP</p>
<p>Insert batch input – BDC_INSERT</p>
<p>Close session – BDC_CLOSE_GROUP</p>
<p>125) What is the alternative to batch input session?</p>
<p>Ans Call Transaction Method &amp; Call Dialog</p>
<p>126) A situation: An ABAP program creates a batch input session. We need to submit the</p>
<p>program and the batch session in background. How to do it?</p>
<p>Ans Go to SM36 and create background job by giving job name, job class and job steps</p>
<p>(JOB SCHEDULING)</p>
<p>127) What is the difference between a pool table and a transparent table and how they are</p>
<p>stored at the database level?</p>
<p>Ans Pool Table -</p>
<p>1) Many to One Relationship.</p>
<p>2) Table in the Dictionary has the different name, different number of fields, and the fields have the different name as in the R3 Table definition.</p>
<p>3) It can hold only pooled tables.</p>
<p>Transparent Table –</p>
<p>1) One to One relationship.</p>
<p>2) Table in the Dictionary has the same name, same number of fields, and the fields have the same name as in the R3 Table definition.</p>
<p>3) It can hold Application data.</p>
<p>128) What are the problems in processing batch input sessions? How is batch input process</p>
<p>different from processing on line?</p>
<p>Ans Two Problems: -</p>
<p>1) If the user forgets to opt for keep session then the session will be automatically removed from the session queue (log remains). However, if session is processed we may delete it manually.</p>
<p>2) If session processing fails, data will not be transferred to SAP database table.</p>
<p>129) Is Session Method, Asynchronous or Synchronous?</p>
<p>Ans Synchronous</p>
<p>130) What are the different types of data dictionary objects?</p>
<p>Ans Different types of data dictionary objects:</p>
<p>1) Tables</p>
<p>2) Views</p>
<p>3) Data elements</p>
<p>4) Structure</p>
<p>5) Domains</p>
<p>6) Search Helps</p>
<p>7) Local Objects</p>
<p> <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> Matchcode</p>
<p>131) How many types of tables exist and what are they in data dictionary?</p>
<p>Ans 4 Types of Tables:</p>
<p>1. Transparent tables – Exists with the same structure both in dictionary as well as in database exactly with the same data and fields. Both Open SQL and Native SQL can be used.<br />
2. Pool tables<br />
3. Cluster tables – These are logical tables that are arranged as records of transparent tables. One cannot use Native SQL on these tables (only Open SQL). They are not manageable directly using database system tools.<br />
4. Internal tables</p>
<p>132) What is the step-by-step process to create a table in data dictionary?</p>
<p>Ans Steps to create a table:</p>
<p>Step 1: creating domains (data type, field length, Range).</p>
<p>Step 2: creating data elements (properties and type for a table field).</p>
<p>Step 3: creating tables (SE11).</p>
<p>133) Can a transparent table exist in data dictionary but not in the database physically?</p>
<p>Ans No, Transparent table do exist with the same structure both in the dictionary as well as in the database, exactly with the same data and fields.</p>
<p>134) In SAP Scripts, how will u link FORM with the Event Driven?</p>
<p>Ans In PAI, define function code and write code for the same.</p>
<p>135) Can you create a table with fields not referring to data elements?</p>
<p>Ans YES. e.g.:- ITAB LIKE SPFLI.</p>
<p>Here we are refering to a data object (SPFLI) not data element.</p>
<p>136) What is the advantage of structures? How do you use them in the ABAP programs?</p>
<p>Ans GLOBAL EXISTANCE (these could be used by any other program without creating it again).</p>
<p>137) What does an extract statement do in the ABAP program?</p>
<p>Ans Once you have declared the possible record types as field groups and defined their structure, you can fill the extract dataset using the following statements:</p>
<p>EXTRACT .</p>
<p>When the first EXTRACT statement occurs in a program, the system creates the extract dataset and adds the first extract record to it. In each subsequent EXTRACT statement, the new extract record is added to the dataset</p>
<p>EXTRACT HEADER.</p>
<p>When you extract the data, the record is filled with the current values of the corresponding fields.</p>
<p>As soon as the system has processed the first EXTRACT statement for a field group , the structure of the corresponding extract record in the extract dataset is fixed. You can no longer insert new fields into the field groups and HEADER. If you try to modify one of the field groups afterwards and use it in another EXTRACT statement, a runtime error occurs.</p>
<p>By processing EXTRACT statements several times using different field groups, you fill the extract dataset with records of different length and structure. Since you can modify field groups dynamically up to their first usage in an EXTRACT statement, extract datasets provide the advantage that you need not determine the structure at the beginning of the program.</p>
<p>138) What is a collect statement? How is it different from append?</p>
<p>Ans Collect : If an entry with the same key already exists, the COLLECT statement does not append a new line, but adds the contents of the numeric fields in the work area to the contents of the numeric fields in the existing entry.</p>
<p>Append – Duplicate entries occurs.</p>
<p>139) What is OPEN SQL vs NATIVE SQL?</p>
<p>Ans Open SQL – These statements are a subset of standard SQL. It consists of DML command (Select, Insert, Update, Delete). It can simplify and speed up database access. Buffering is partly stored in the working memory and shared memory. Data in buffer is not always up-to-date.</p>
<p>Native SQL – They are loosely integrated into ABAP. It allows access to all functions containing programming interface. They are not checked and converted. They are sent directly to the database system. Programs that use Native SQL are specific to the database system for which they were written. For e.g. to create or change table definition in the ABAP.</p>
<p>140) What does an EXEC SQL stmt do in ABAP? What is the disadvantage of using it?</p>
<p>Ans To use a Native SQL statement, you must precede it with the EXEC SQL statement, and follow it with the ENDEXEC statement as follows:</p>
<p>EXEC SQL [PERFORMING<br />
].</p>
<p>ENDEXEC.</p>
<p>There is no period after Native SQL statements. Furthermore, using inverted commas (“) or an asterisk (*) at the beginning of a line in a native SQL statement does not introduce a comment as it would in normal ABAP syntax. You need to know whether table and field names are case-sensitive in your chosen database.</p>
<p>141) What is the meaning of ABAP editor integrated with ABAP data dictionary?</p>
<p>Ans ABAP Editor: Tool in the ABAP Workbench in which you enter the source code of ABAP programs and check their syntax. You can also navigate from the ABAP Editor to the other tools in the ABAP Workbench.</p>
<p>142) What are the events in ABAP language?</p>
<p>Ans The events are as follows:</p>
<p>1. Initialization</p>
<p>2. At selection-screen</p>
<p>3. Start-of-selection</p>
<p>4. End-of-selection</p>
<p>5. Top-of-page</p>
<p>6. End-of-page</p>
<p>7. At line-selection</p>
<p>8. At user-command</p>
<p>9. At PF</p>
<p>10. Get</p>
<p>11. At New</p>
<p>12. At LAST</p>
<p>13. AT END</p>
<p>14. AT FIRST</p>
<p>143) What is an interactive report? What is the obvious difference of such report compared</p>
<p>with classical type reports?</p>
<p>Ans An Interactive report is a dynamic drill down report that produces the list on users choice.</p>
<p>Difference: -</p>
<p>a) The list produced by classical report doesn’t allow user to interact with the system where as the list produced by interactive report allows the user to interact with the system.</p>
<p>B) Once a classical report, executed user looses control where as Interactive, user has control.</p>
<p>C) In classical report, drilling is not possible where as in interactive, drilling is possible.</p>
<p>144) What is a drill down report?</p>
<p>Ans Its an Interactive report where in the user can get more relevant data by selecting explicitly.</p>
<p>145) How do you write a function module in SAP? Describe.</p>
<p>Ans</p>
<p>1. Called program – SE37 – Creating function group, function module by assigning attributes, importing, exporting, tables, and exceptions.</p>
<p>2. Calling program – SE38 – In program, click pattern and write function name- provide export, import, tables, exception values.</p>
<p>146) What are the exceptions in function module?</p>
<p>Ans Exceptions: Our function module needs an exception that it can trigger if there are no entries in table SPFLI that meet the selection criterion. The exception NOT_FOUND serves this function.</p>
<p>COMMUNICATION_FAILURE &amp; SYSTEM_FAILURE</p>
<p>147)</p>
<p>Ans</p>
<p>148) How are the date and time field values stored in SAP?</p>
<p>Ans DD.MM.YYYY. HH:MM:SS</p>
<p>149) What are the fields in a BDC_Tab and BDCDATA Table?</p>
<p>Ans Fields of BDC_Tab &amp; BDCDATA Table:</p>
<p>Sr.No Fields – Description</p>
<p>1) Program – BDC Module pool</p>
<p>2) Dynpro – BDC Screen Number</p>
<p>3) Dynbegin – BDC Screen Start</p>
<p>4) Fname – Field Name</p>
<p>5) Fval – BDC field value</p>
<p>150) Name a few data dictionary objects?</p>
<p>Ans Different types of data dictionary objects:</p>
<p>1) Tables</p>
<p>2) Views</p>
<p>3) Data elements</p>
<p>4) Structure</p>
<p>5) Matchcode</p>
<p>6) Domains</p>
<p>7) Search Helps</p>
<p> <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> Local Objects</p>
<p>151) What happens when a table is activated in DD?</p>
<p>Ans When the table is activated, a physical table definition is created in the database for the table definition stored in the ABAP dictionary. The table definition is translated from the ABAP dictionary of the particular database.</p>
<p>It is available for any insertion, modification and updation of records by any user.</p>
<p>152)</p>
<p>Ans</p>
<p>153) What are matchcodes? Describe?</p>
<p>Ans It is similar to table index that gives list of possible values for either primary keys or non-primary keys.</p>
<p>154) What transactions do you use for data analysis?</p>
<p>Ans</p>
<p>155) What are the elements of selection screen?</p>
<p>Ans There are 5 elements of selection screen:</p>
<p>Selection-screen include blocks</p>
<p>Selection-screen include parameters</p>
<p>Selection-screen include select-options</p>
<p>Selection-screen include comment</p>
<p>Selection-screen include push-button</p>
<p>156) What are ranges? What are number ranges?</p>
<p>Ans Main function of ranges to pass data to the actual selection tables without displaying the selection screen.</p>
<p>Min, Max values provided in selection screens.</p>
<p>It is often necessary to directly access individual records in a data structure. This is done using unique keys. Number ranges are used to assign numbers to individual database records for a commercial object, to complete the key. Such numbers are e.g. order numbers or material master numbers.</p>
<p>157) What are select options and what is the diff from parameters?</p>
<p>Ans Parameters : We can enter a single value.</p>
<p>PARAMETERS: PARAM(10).</p>
<p>Select-options: We can enter low and high value i.e. range has to be specify. By using NO-INTERVAL user can process only single fields.</p>
<p>SELECT-OPTIONS: DNO FOR DEPT-DNO.</p>
<p>SELECT-OPTIONS: DNO FOR DEPT-DNO NO-INTERVAL.</p>
<p>SELECT-OPTIONS declares an internal table, which is automatically filled with values or ranges of values entered by the end user. For each SELECT-OPTIONS, the system creates a selection table.</p>
<p>SELECT-OPTIONS FOR .</p>
<p>A selection table is an internal table with fields SIGN, OPTION, LOW and HIGH.</p>
<p>The type of LOW and HIGH is the same as that of .</p>
<p>The SIGN field can take the following values: I Inclusive (should apply) E Exclusive (should not apply)</p>
<p>The OPTION field can take the following values: EQ Equal GT Greater than NE Not equal BT Between LE Less than or equal NB Not between LT Less than CP Contains pattern GE Greater than or equal NP No pattern.</p>
<p>Differences-</p>
<p>PARAMETERS allow users to enter a single value into an internal field within a report.</p>
<p>SELECT-OPTIONS allows users to fill an internal table with a range of values.</p>
<p>Select-options provide ranges where as parameters do not.</p>
<p>For each PARAMETERS or SELECT-OPTIONS statement you should define text elements by choosing</p>
<p>Goto – Text elements – Selection texts – Change.</p>
<p>Eg:- Parameters name(30).</p>
<p>When the user executes the ABAP/4 program, an input field for ‘name’ will appear on the selection screen. You can change the comments on the left side of the input fields by using text elements as described in Selection Texts.</p>
<p>158) How do you validate the selection criteria of a report? And how do you display initial</p>
<p>values in a selection screen?</p>
<p>Ans The selection criteria is validated in the processing block of the AT SELECTION SCREEN event for the input values on the screen and respective messages can be sent.</p>
<p>To display initial values in the selection screen:</p>
<p>1) Use INITIALIZATION EVENT</p>
<p>2) Use DEFAULT VALUE option of PARAMETERS Statement</p>
<p>3) Use SPA/GPA Parameters (PIDs).</p>
<p>Validate: – by using match code objects.</p>
<p>Display :- Parameters default ‘xxx’.</p>
<p>Select-options for spfli-carrid.</p>
<p>Initial values in a selection screen:</p>
<p>INITIALIZATION.</p>
<p>DNO-LOW = 10.</p>
<p>DNO-HIGH = 30</p>
<p>SIGN I.</p>
<p>OPTION NB.</p>
<p>APPEND DNO.</p>
<p>159) What are selection texts?</p>
<p>Ans</p>
<p>160) What is CTS and what do you know about it?</p>
<p>Ans CTS stands for Correction and Transport System. The CTS provides a range of functions that help you to choose a transport strategy optimally suited to your requirements. We recommend that you follow the transport strategy while you plan and set up your system landscape.</p>
<p>Correction and Transport System (CTS) is a tool that helps you to organize development projects in the ABAP Workbench and in Customizing, and then transport the changes between the SAP Systems and clients in your system landscape. This documentation provides you with an overview of how to manage changes with the CTS and essential information on setting up your system and client landscape and deciding on a transport strategy. Read and follow this documentation when planning your development project. For practical information on working with the Correction and Transport System, see Correction and Transport Organizer and Transport Management System.</p>
<p>161) When a program is created and need to be transported to prodn does selection texts always go with it? If not how do you make sure? Can you change the CTS entries? How do you do it?</p>
<p>Ans</p>
<p>162) What is the client concept in SAP? What is the meaning of client independent?</p>
<p>Ans In commercial, organizational and technical terms, the client is a self-contained unit in the R3 system, with separate set of Master data and its own set of Tables. When a change is made in one client all other clients are affected in the system – this type of objects are called Client independent objects.</p>
<p>163) Are programs client dependent?</p>
<p>Ans Yes, group of users can access these programs with a client number.</p>
<p>164) Name a few system global variables you can use in ABAP programs?</p>
<p>Ans SY-SUBRC, SY-DBCNT, SY-LILLI, SY-DATUM, SY-UZEIT, SY-UCOMM,</p>
<p>SY-TABIX…..</p>
<p>SY-LILLI is absolute number of lines from which the event was triggered.</p>
<p>165) What are internal tables? How do you get the number of lines in an internal table? How to use a specific number occurs statement?</p>
<p>Ans</p>
<p>1) It is a standard data type object, which exists only during the runtime of the program. They are used to perform table calculations on subsets of database tables and for re-organizing the contents of database tables according to users need.</p>
<p>2) Using SY-DBCNT.</p>
<p>3) The number of memory allocations the system need to allocate for the next record population.</p>
<p>166) How do you take care of performance issues in your ABAP programs?</p>
<p>Ans Performance of ABAP programs can be improved by minimizing the amount of data to be transferred. The data set must be transferred through the network to the applications, so reducing the amount of time and also reduces the network traffic.</p>
<p>Some measures that can be taken are:</p>
<p>- Use views defined in the ABAP/4 DDIC (also has the advantage of better reusability).</p>
<p>- Use field list (SELECT clause) rather than SELECT *.</p>
<p>- Range tables should be avoided (IN operator)</p>
<p>- Avoid nested SELECTS.</p>
<p>167) What are datasets?</p>
<p>Ans The sequential files (ON APPLICATION SERVER) are called datasets. They are used for file handling in SAP.</p>
<p>168) How to find the return code of an stmt in ABAP programs?</p>
<p>Ans Open SQL has 2 system fields with return codes:</p>
<p>1) SY-SUBRC</p>
<p>2) SY-DBCNT</p>
<p>Using function modules</p>
<p>169) What are Conversion &amp; Interface programs in SAP?</p>
<p>Ans CONVERSION: Legacy system to flat file.</p>
<p>INTERFACE: Flat file to SAP system.</p>
<p>170) Have you used SAP supplied programs to load master data?</p>
<p>Ans SAP supplied BDC programs</p>
<p>RM06BBI0 (Purchase Requisitions)</p>
<p>RMDATIND (Material Master)</p>
<p>RFBIKR00 (Vendor Masters)</p>
<p>RFBIDE00 (Customer Master)</p>
<p>RVINVB00 (Sales Order)</p>
<p>171) What are the techniques involved in using SAP supplied programs? Do you prefer to</p>
<p>write your own programs to load master data? Why?</p>
<p>Ans</p>
<p>Þ Identify relevant fields</p>
<p>Þ Maintain transfer structure ( Predefined – first one is always session record)</p>
<p>Þ Session record structure, Header Data, Item ( STYPE – record type )</p>
<p>Þ Fields in session structure – STYPE, GROUP , MANDT, USERNAME , NO DATA</p>
<p>Þ Fields in header structure – consists of transaction code also – STYPE, BMM00, TCODE, MATNR and Fields in Item – ITEMS …</p>
<p>Þ Maintain transfer file – sample data set creation</p>
<p>172) What are logical databases? What are the advantages/disadvantages of logical databases?</p>
<p>Ans To read data from a database tables we use logical database.</p>
<p>A logical database provides read-only access to a group of related tables to an ABAP/4 program.</p>
<p>Advantages: – The programmer need not worry about the primary key for each table. Because Logical database knows how the different tables relate to each other, and can issue the SELECT command with proper where clause to retrieve the data.</p>
<p>1) An easy-to-use standard user interface.</p>
<p>2) Check functions, which check that user input is complete, correct, and plausible.</p>
<p>3) Meaningful data selection.</p>
<p>4) Central authorization checks for database accesses.</p>
<p>5) Good read access performance while retaining the hierarchical data view determined by the application logic.</p>
<p>6) No need of programming for retrieval, meaning for data selection</p>
<p>Disadvantages: -</p>
<p>1) If you do not specify a logical database in the program attributes, the GET events never occur.</p>
<p>2) There is no ENDGET command, so the code block associated with an event ends with the next event statement (such as another GET or an END-OF-SELECTION).</p>
<p>3) Fast in case of lesser no. of tables But if the table is in the lowest level of hierarchy, all upper level tables should be read so performance is slower.</p>
<p>173) What specific statements do you using when writing a drill down report?</p>
<p>Ans AT LINE-SELECTION</p>
<p>AT USER-COMMAND</p>
<p>AT PF.</p>
<p>174) What are different tools to report data in SAP? What all have you used?</p>
<p>Ans</p>
<p>175) What are the advantages and disadvantages of ABAP query tool?</p>
<p>Ans Advantages: No programming knowledge is required.</p>
<p>Disadvantages: Depending on the complexity of the database tables, it may not be easy for the user to select the necessary data correctly.</p>
<p>176) What are the functional areas? User groups? How does ABAP query work in relation to</p>
<p>these?</p>
<p>Ans Functional Areas – By creating functional areas, we can initially select this data. This ensures that the data is presented to the ABAP Query user in a meaningful way to accomplish the task, and that only the data that the user may use is presented.</p>
<p>User Groups – A user group is a collection of users that work with about the same data and carry out similar tasks. The members of a user group can use all programs (queries) created by any user of the group. Changes to such a program are at once visible to all users. This ensures that all members of a user group use the same evaluation programs.</p>
<p>ABAP Query: It consists of three components – queries, functional areas and user groups. The functional areas provide the user with an initial set of data in accordance with the task to be accomplished. All users must be members of at least one user group. All members of one user group can access the same data as well as the same program (queries) to create lists.</p>
<p>177) Is a logical database a requirement/must to write an ABAP query?</p>
<p>Ans No, it is not must to use LDB. Apart from it, we have other options:</p>
<p>1) Table join by Basis Table</p>
<p>2) Direct Read of table</p>
<p>3) Data Retrieval by Program</p>
<p>178) What is the structure of a BDC sessions.</p>
<p>Ans BDCDATA</p>
<p>179) What are Change header and detail tables? Have you used them?</p>
<p>Ans</p>
<p>180) What do you do when the system crashes in the middle of a BDC batch session?</p>
<p>Ans We will look into the error log file (SM35). Check number of records already updated and delete them from input file and run BDC again.</p>
<p>181) What do you do with errors in BDC batch sessions?</p>
<p>Ans We look into the list of incorrect session and process it again. To correct incorrect session, we analyze the session to determine which screen and value produced the error. For small errors in data we correct them interactively otherwise modify batch input program that has generated the session or many times even the data file.</p>
<p>182) How do you set up background jobs in SAP? What are the steps? What are the events</p>
<p>driven batch jobs?</p>
<p>Ans Go to SM36 and create background job by giving job name, job class and job steps</p>
<p>(JOB SCHEDULING)</p>
<p>183) Is it possible to run host command from SAP environment? How do you run?</p>
<p>Ans</p>
<p>184) What kind of financial periods exist in SAP? What is the relevant table for that?</p>
<p>Ans</p>
<p>185) Does SAP handle multiple currencies? Multiple languages?</p>
<p>Ans Yes.</p>
<p>186) What is a currency factoring technique?</p>
<p>Ans</p>
<p>187) How do you document ABAP programs? Do you use program documentation menu</p>
<p>option?</p>
<p>Ans</p>
<p>188) What is SAP Script and layout set?</p>
<p>Ans The tool, which is used to create layout set is called SAP Script. Layout set is a design, appearance and structure of document.</p>
<p>189) What are the ABAP commands that link to a layout set?</p>
<p>Ans Control Commands, System Commands</p>
<p>190) What is output determination?</p>
<p>Ans</p>
<p>191) What is the field length of Packed Number? What is the default decimal of packed</p>
<p>number?</p>
<p>Ans</p>
<p>192) What are the different types of data types?</p>
<p>Ans There are three types of data types:</p>
<p>Data Types</p>
<p>Elementary Complex References</p>
<p>Fixed Variable Structure Table Data Object</p>
<p>Variable</p>
<p>193) What is the syntax of Packed Number?</p>
<p>Ans Data : NUM type P decimals 2.</p>
<p>194) What are different types of attributes of Function Module?</p>
<p>Ans There are 6 attributes of FM:</p>
<p>1. Import</p>
<p>2. Export</p>
<p>3. Table</p>
<p>4. Changing</p>
<p>5. Source</p>
<p>6. Exception</p>
<p>195) List of Screen elements.</p>
<p>Ans There are 13 screen elements:</p>
<p>i. Input / output fields</p>
<p>ii. Text fields</p>
<p>iii. Checkbox</p>
<p>iv. Radio button</p>
<p>v. Push Button</p>
<p>vi. Drop down list</p>
<p>vii. Subscreen</p>
<p>viii. Table control</p>
<p>ix. Tabstrip control</p>
<p>x. Custom control</p>
<p>xi. Box</p>
<p>xii. Status icons</p>
<p>xiii. OK_CODE fields</p>
<p>196) How many default Tab Strips are there? How to insert more Tabs in it?</p>
<p>Ans There 2 default Tab strips. Screen painter attributes contain Tab Title, which is used to insert more tabs in tab strip.</p>
<p>197) How to define Selection Screen?</p>
<p>Ans There are 3 ways of defining selection screen:</p>
<p>1. Parameters</p>
<p>2. Select-options</p>
<p>3. Selection-Screen</p>
<p>198) What are the properties of Selection Screen?</p>
<p>Ans There are 11 properties of selection screen:</p>
<p>1) Default</p>
<p>2) Memory ID</p>
<p>3) Lowercase</p>
<p>4) Visible length</p>
<p>5) Obligatory</p>
<p>6) Matchcode</p>
<p>7) Check</p>
<p> <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> Checkbox</p>
<p>9) Radiobutton Group</p>
<p>10) No-display</p>
<p>11) Modif ID</p>
<p>199) What are the components of Selection Table?</p>
<p>Ans There are four components of selection table:</p>
<p>Low, High, Sign, Options</p>
<p>200) How to display or know if the value entered contains records or not?</p>
<p>Ans SY-SUBRC</p>
<p>201) What are the sequences of event block?</p>
<p>Ans</p>
<p>i. Reports</p>
<p>ii. Nodes</p>
<p>iii. Data</p>
<p>iv. Initialization</p>
<p>v. At selection-screen</p>
<p>vi. Start-of-selection</p>
<p>vii. Get deptt</p>
<p>viii. Get emp</p>
<p>ix. Get deptt late</p>
<p>x. End-of-selection</p>
<p>xi. Form</p>
<p>xii. Endform</p>
<p>202) What are types of Select statements?</p>
<p>Ans SELECT SINGLE … WHERE …</p>
<p>SELECT [DISTINCT] … WHERE …</p>
<p>SELECT<br />
* …</p>
<p>203) What are DML commands?</p>
<p>Ans Select, Insert, Delete, Modify, Update.</p>
<p>204) What is Asynchronous and Synchronous Update?</p>
<p>Ans Asynchronous Update – The program does not wait for the work process to finish the</p>
<p>update. Commit Work.</p>
<p>Synchronous Update – The program wait for the work process to finish the update.</p>
<p>Commit Work and Wait.</p>
<p>205) Write syntax for Message Error (Report)?</p>
<p>Ans AT SELECTION-SCREEN.</p>
<p>SELECT * FROM ZREKHA_DEPTT INTO CORRESPONDING FIELDS OF ITAB</p>
<p>WHERE DEPTNO IN DEPTNO.</p>
<p>ENDSELECT.</p>
<p>If SY-DBCNT = 0.</p>
<p>MESSAGE E000 WITH ‘NO RECORDS FOUND’.</p>
<p>ENDIF.</p>
<p>206) How to see the list of all created session?</p>
<p>Ans There are two method to see all sessions:</p>
<p>1) SHDB (Recording)</p>
<p>2) Write code in SE38 then save, check errors activate and execute it.</p>
<p>System</p>
<p>Service</p>
<p>Batch input</p>
<p>Session</p>
<p>207) What are the function module in BDC?</p>
<p>Ans There are three function module in BDC:</p>
<p>1) BDC_OPEN_GROUP</p>
<p>2) BDC_INSERT</p>
<p>3) BDC_CLOSE_GROUP</p>
<p>208) Write the steps to execute session method.</p>
<p>Ans Steps for execution Session Method:</p>
<p>1) System</p>
<p>2) Service</p>
<p>3) Batch Input</p>
<p>4) Session</p>
<p>5) Choose Session Name</p>
<p>6) Process</p>
<p>7) Asks for Mode (Display All Screen, Display Errors &amp; Background)</p>
<p> <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> Process</p>
<p>209) What are the different types of mode (run code) in Call Transaction method?</p>
<p>Ans There are three modes in Call Transaction:</p>
<p>A – Displays All Screen</p>
<p>E – Display Errors</p>
<p>N – Background Processing</p>
<p>210) Write the transaction code of Customer Master Data, Pricing, Inquiry, Quotation and Sales Order.</p>
<p>Ans Customer Master Data – XD01</p>
<p>Pricing -</p>
<p>Inquiry – VA11</p>
<p>Quotation – VA21</p>
<p>Sales Order – VA01</p>
<p>- MM01</p>
<p>211) What are the fields of Sales Order?</p>
<p>Ans Transaction Code of Sales Order: VA01</p>
<p>Table of Sales Order: VBAK</p>
<p>Order Type – AUART</p>
<p>Sales Org – VKORG</p>
<p>Dist Channel – VTWEG</p>
<p>Division – SPART</p>
<p>Sales Office – VKBUR</p>
<p>Sales Group – VKGRP</p>
<p>212) What are different types of screen keywords?</p>
<p>Ans There are four types of screen keywords: Module, Loop, Chain and Field.</p>
<p>213) Write special commands of List.</p>
<p>Ans There are four specials commands of lists: Write, Uline, Skip and New-Page</p>
<p>214) Write the following in different manner.</p>
<p>IF ( A GE B ) AND ( A LE C)</p>
<p>Ans IF A BETWEEN B AND C</p>
<p>215) What are the different types of ABAP statements?</p>
<p>Ans There are six types of ABAP statements:</p>
<p>1) Declarative – Types, Data, Tables</p>
<p>2) Modularization – Event Keywords and Defining Keywords</p>
<p>3) Control – If…Else, While, Case</p>
<p>4) Call – Perform, Call, Set User Command, Submit, Leave to</p>
<p>5) Operational – Write, Add, Move</p>
<p>6) Database – Open SQL &amp; Native SQL</p>
<p>216) How data is stored in cluster table?</p>
<p>Ans Each field of cluster table behaves as tables, which contains the number of entries.</p>
<p>217) What are client dependant objects in ABAP / SAP?</p>
<p>Ans SAP Script layout, text element, and some DDIC objects.</p>
<p>218) On which event we can validate the input fields in module programs?</p>
<p>Ans In PAI (Write field statement on field you want to validate, if you want to validate group of fields put in chain and End chain statement.)</p>
<p>219) In selection screen, I have three fields, plant material number and material group. If I input plant how do I get the material number and material group based on plant dynamically?</p>
<p>Ans AT SELECTION-SCREEN ON VALUE-REQUEST FOR MATERIAL.</p>
<p>CALL FUNCTION ‘F4IF_INT_TABLE_VALUE_REQUEST’</p>
<p>to get material and material group for the plant.</p>
<p>220) How do you get output from IDOC?</p>
<p>Ans Data in IDOC is stored in segments; the output from IDOC is obtained by reading the data stored in its respective segments.</p>
<p>221) When top of the page event is triggered?</p>
<p>Ans After executing first write statement in start-of-selection event.</p>
<p>222) Can we create field without data element and how?</p>
<p>Ans In SE11, one option is available above the fields strip i.e. Data element / direct type.</p>
<p>223) Fields of VBAK Table.</p>
<p>Ans VBAK – Sales Document : Header Data</p>
<p>Details about Sales Organization, Distribution Channel, Division, Sales Group, Sales Office, Business Area, Outline Agreements, etc</p>
<p>224) Which transaction code can I used to analyze the performance of ABAP program.</p>
<p>Ans Transaction Code AL21.</p>
<p>225) How can I copy a standard table to make my own Z_TABLE?</p>
<p>Ans Go to transaction SE11. Then there is one option to copy table. Press that button. Enter the name of the standard table and in the Target table enter Z_table name and press enter.</p>
<p>226) What is runtime analysis? Have you used this?</p>
<p>Ans It checks program execution time in microseconds. When you go to SE30. If you give desired program name in performance file. It will take you to below screen. You can get how much fast is your program.</p>
<p>227) What is meant by performance analysis?</p>
<p>Ans</p>
<p>228) How to transfer the objects? Have you transferred any objects?</p>
<p>Ans</p>
<p>229) How did you test the developed objects?</p>
<p>Ans There are two types of testing</p>
<p>- Negative testing</p>
<p>- Positive testing</p>
<p>In negative testing, we will give negative data in input and we check any errors occurs.</p>
<p>In positive testing, we will give positive data in input for checking errors.</p>
<p>230) How did you handle errors in Call Transaction?</p>
<p>Ans We can create an internal table like ‘bsgmcgcoll’. All the messages will go to internal table. We can get errors in this internal table.</p>
<p>Below messages are go to internal table. When you run the call transaction.</p>
<p>1) TCODE</p>
<p>2) Message Type</p>
<p>3) Message Id</p>
<p>4) Message Number</p>
<p>5) MSGV1</p>
<p>6) MSGV2</p>
<p>7) MSGV3</p>
<p> <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> MSGV4</p>
<p>CALL TRANSACTION TCODE USING BDCDATA MODE A/N/E.</p>
<p>UPDATE MODE A/S MESSAGE INTO BDCDATA.</p>
<p>THEN PUT LOOP…ENDLOOP OF BDCMSGCOLL</p>
<p>CALL FUNCTION ‘FORMAT_WRITE’</p>
<p>EXPORT = SYSTEM FIELD</p>
<p>IMPORT = MSG TEXT ERROR</p>
<p>231) Among the Call Transaction and Session Method, which is faster?</p>
<p>Ans Call transaction is faster then session method. But usually we use session method in real time…because we can transfer large amount of data from internal table to database and if any errors in a session, then process will not complete until session get correct.</p>
<p>232) What are the difference between Interactive and Drill Down Reports?</p>
<p>Ans ABAP/4 provides some interactive events on lists such as AT LINE-SELECTION (double click) or AT USER-COMMAND (pressing a button). You can use these events to move through layers of information about individual items in a list.</p>
<p>Drill down report is nothing but interactive report…drilldown means above paragraph only.</p>
<p>233) How to pass the variables to forms?</p>
<p>Ans</p>
<p>234) What is the table, which contain the details of all the name of the programs and forms?</p>
<p>Ans Table contains vertical and horizontal lines. We can store the data in table as blocks. We can scroll depends upon your wish. And these all are stored in database (data dictionary).</p>
<p>235) What are Standard Texts?</p>
<p>Ans</p>
<p>236) What is the difference between Clustered Tables and Pooled Tables?</p>
<p>Ans A pooled table is used to combine several logical tables in the ABAP/4 dictionary. Pooled tables are logical tables that must be assigned to a table pool when they are defined.</p>
<p>Cluster table are logical tables that must be assigned to a table cluster when they are defined. Cluster table can be used to store control data. They can also used to store temporary data or text such as documentation.</p>
<p>237) What is PF-STATUS?</p>
<p>Ans PF-Status is used in interactive report for enhancing the functionality. If we go to SE41, we can get menus, items and different function keys, which we are using for secondary list in interactive report.</p>
<p>238) Among “Move” and “Move Corresponding”, which is efficient one?</p>
<p>Ans I guess, ‘move corresponding’ is very efficient then ‘move’ statement. Because usually we use this statement for internal table fields only…so if we give move corresponding. Those fields only moving to other place (what ever you want).</p>
<p>239) What are the Output Type, Transaction codes, Page Format?</p>
<p>Ans</p>
<p>240) Where we use Chain and End chain?</p>
<p>Ans In Screen Programming</p>
<p>241) Do you use select statement in loop…end loop, how will be the performance? To improve the performance?</p>
<p>Ans</p>
<p>242) In select-options, how to get the default values as current month first date and last date by default? Eg: 1/12/2004 and 31/12/2004</p>
<p>Ans</p>
<p>243) What are IDOCs?</p>
<p>Ans IDOCs are intermediate documents to hold the messages as a container.</p>
<p>244) What are screen painter? Menu painter? Gui status? ..etc.</p>
<p>Ans dynpro – flow logic + screens.</p>
<p>menu painter -</p>
<p>GUI Status – It is subset of the interface elements (title bar, menu bar, standard tool bar, push buttons) used for a certain screen.</p>
<p>The status comprises those elements that are currently needed by the transaction.</p>
<p>245) What is screen flow logic? What are the sections in it? Explain PAI and PBO.</p>
<p>Ans The control statements that control the screen flow.</p>
<p>PBO – This event is triggered before the screen is displayed.</p>
<p>PAI – This event is responsible for processing of screen after the user enters the data and clicks the pushbutton.</p>
<p>246) Overall how do you write transaction programs in SAP?</p>
<p>Ans Create program-SE93-create transaction code -Run it from command field.</p>
<p>Create the transaction using object browser (SE80)</p>
<p>Define the objects e.g. screen, Transactions. – Modules – PBO, PAI.</p>
<p>247) Does SAP has a GUI screen painter or not? If yes what operating systems is it available on? What is the other type of screen painter called?</p>
<p>Ans Yes.</p>
<p>Operating System – Windows based</p>
<p>Screen Painter – Alpha numeric Screen Painter</p>
<p>248) What are step loops? How do you program page down page up in step loops?</p>
<p>Ans Step loops are repeated blocks of field in a screen.</p>
<p>Step loops: Method of displaying a set of records.</p>
<p>Page down &amp; Page up: decrement / increment base counter</p>
<p>Index = base + sy-step1 – 1</p>
<p>249) Is ABAP a GUI language?</p>
<p>Ans Yes, ABAP IS AN EVENT DRIVEN LANGUAGE.</p>
<p>250) Normally how many and what files get created when a transaction program is written?</p>
<p>What is the XXXXXTOP program?</p>
<p>Ans Main program with A Includes</p>
<p>1. TOP INCLUDE – GLOBAL DATA<br />
2. Include for PBO<br />
3. Include for PAI<br />
4. Include for Forms</p>
<p>251) What are the include programs?</p>
<p>Ans When the same sequence of statements in several programs is to be written repeatedly. They are coded in include programs (External programs) and are included in ABAP/4 programs.</p>
<p>252) Can you call a subroutine of one program from another program?</p>
<p>Ans Yes, only external subroutines Using ‘SUBMIT’ statement.</p>
<p>253) What are user exits? What is involved in writing them? What precautions are needed?</p>
<p>Ans User defined functionality included to predefined SAP standards. Point in an SAP program where a customer’s own program can be called. In contrast to customer exits, user exits allow developers to access and modify program components and data objects in the standard system. On upgrade, each user exit must be checked to ensure that it conforms to the standard system.</p>
<p>There are two types of user exit:</p>
<p>1. User exits that use INCLUDEs – These are customer enhancements that are called directly in the program.<br />
2. User exits that use TABLEs – These are used and managed using Customizing. Should find the customer enhancements belonging to particular development class.</p>
<p>254) What are RFCs? How do you write RFCs on SAP side?</p>
<p>Ans</p>
<p>255) What are the general naming conventions of ABAP programs?</p>
<p>Ans Should start with Y or Z.</p>
<p>256) How do you find if a logical database exists for your program requirements?</p>
<p>Ans SLDB-F4.</p>
<p>257) How do you find the tables to report from when the user just tell you the transaction he uses? And all the underlying data is from SAP structures?</p>
<p>Ans Transaction code is entered in command field to open the table – Utilities –</p>
<p>Table contents display.</p>
<p>258) How do you find the menu path for a given transaction in SAP?</p>
<p>Ans</p>
<p>259) What are the different modules of SAP?</p>
<p>Ans FI, CO, SD, MM, PP, HR.</p>
<p>260) How do you get help in ABAP?</p>
<p>Ans HELP-SAP LIBRARY, by pressing F1 on a keyword.</p>
<p>261) What are different ABAP/4 editors? What are the differences?</p>
<p>Ans</p>
<p>262) What are the different elements in layout sets?</p>
<p>Ans PAGES, Page windows, Header, Paragraph, Character String, Windows.</p>
<p>263) Can you use if then else, perform..etc statements in sap script?</p>
<p>Ans Yes.</p>
<p>264) What type of variables normally used in sap script to output data?</p>
<p>Ans</p>
<p>265) How do you number pages in SAP Script layout outputs?</p>
<p>Ans &amp; page &amp; &amp;next Page &amp;</p>
<p>266) What takes most time in SAP script programming?</p>
<p>Ans LAYOUT DESIGN AND LOGO INSERTION.</p>
<p>267) How do you use tab sets in layout sets?</p>
<p>Ans Define paragraph with defined tabs.</p>
<p>268) How do you backup SAP Script layout sets? Can you download and upload? How?</p>
<p>Ans SAP script backup :- In transaction SE71 goto Utilities -&gt; Copy from client -&gt; Give source form name, source client (000 default), Target form name.</p>
<p>Download :- SE71, type form name -&gt; Display -&gt; Utilities -&gt; form info -&gt; List -&gt; Save to PC file.</p>
<p>Upload :- Create form with page, window, page window with the help of downloaded PC file. Text elements for Page windows to be copied from PC file.</p>
<p>269) What are presentation and application servers in SAP?</p>
<p>Ans The application layer of an R/3 System is made up of the application servers and the message server. Application programs in an R/3 System are run on application servers. The application servers communicate with the presentation components, the database, and also with each other, using the message server.</p>
<p>270) In an ABAP/4 program, how do you access data that exists on Presentation Server vs on an Application Server?</p>
<p>Ans Using loop statements and Flat</p>
<p>271) What are different data types in ABAP/4?</p>
<p>Ans</p>
<p>Elementary -</p>
<p>Predefined: C, D, F, I, N, P, T, X.</p>
<p>User defined: TYPES.</p>
<p>Structured -</p>
<p>Predefined: TABLES.</p>
<p>User defined: Field Strings and internal tables.</p>
<p>272) What is difference between session method and Call Transaction?</p>
<p>Ans Call Transaction –</p>
<p>1. Single transaction</p>
<p>2. Synchronous processing</p>
<p>3. Asynchronous and Synchronous update</p>
<p>4. No session log is created</p>
<p>5. Faster</p>
<p>Session –</p>
<p>1. Multiple Transaction<br />
2. Asynchronous processing<br />
3. Synchronous update<br />
4. Session log is created<br />
5. Slower</p>
<p>273) Setting up a BDC program where you find information from?</p>
<p>Ans</p>
<p>274) What has to be done to the packed fields before submitting to a BDC session.</p>
<p>Ans Fields converted into character type.</p>
<p>275) What is the structure of a BDC sessions.</p>
<p>Ans BDCDATA (standard structure).</p>
<p>276) What are the fields in a BDC_Tab Table.</p>
<p>Ans PROGRAM, DYNPRO, DYNBEGIN, FNAM, FVAL.</p>
<p>277) What do you define in the domain and data element.</p>
<p>Ans Domain – Technical details are defined in Domain like data type, number of decimal places and length.</p>
<p>Data Element – Functionality details are defined in Data elements – Field Text, Column Captions, Parameters ID, and Online Field Documentation.</p>
<p>278) What is the difference between a pool table and a transparent table and how they are stored at the database level.</p>
<p>Ans Pool tables are a logical representation of transparent tables. Hence no existence at database level.</p>
<p>Where as transparent tables are physical tables and exist at database level.</p>
<p>Pool Table -</p>
<p>4) Many to One Relationship.</p>
<p>5) Table in the Dictionary has the different name, different number of fields, and the fields have the different name as in the R3 Table definition.</p>
<p>6) It can hold only pooled tables.</p>
<p>Transparent Table –</p>
<p>4) One to One relationship.</p>
<p>5) Table in the Dictionary has the same name, same number of fields, and the fields have the same name as in the R3 Table definition.</p>
<p>6) It can hold Application data.</p>
<p>279) What is cardinality?</p>
<p>Ans For cardinality one out of two (domain or data element) should be the same for Ztest1 and Ztest2 tables. M:N Cardinality specifies the number of dependent(Target) and independent (source) entities which can be in a relationship.</p>
<p>280) For Sales Document: Item Data, which table is used?</p>
<p>Ans VBAP – Sales Document, Sales Document Item, Material Number, Material Entered, Batch Number, Material Group, Target Quantity in Sales Document.</p>
<p>281) What are the types of tables?</p>
<p>Ans</p>
<p>1) Transparent table 5) Pool table</p>
<p>2) Cluster table are data dictionary table objects 6) Sorted table</p>
<p>3) Indexed table 7) Hash table</p>
<p>4) Internal tables.</p>
<p>282) What are pooled table?</p>
<p>Ans Table pools (pools) and table clusters (clusters) are special table types in the ABAP Dictionary. The data from several different tables can be stored together in a table pool or table cluster. Tables assigned to a table pool or table cluster are referred to as pooled tables or cluster tables.</p>
<p>A table in the database in which all records from the pooled tables assigned to the table pool are stored corresponds to a table pool. The definition of a pool consists essentially of two key fields (Tabname and Varkey) and a long argument field (Vardata).</p>
<p>Table Clusters Several logical data records from different cluster tables can be stored together in one physical record in a table cluster.</p>
<p>A cluster key consists of a series of freely definable key fields and a field (Pageno) for distinguishing continuation records. A cluster also contains a long field (Vardata) that contains the contents of the data fields of the cluster tables for this key. If the data does not fit into the long field, continuation records are created. Control information on the structure of the data string is still written at the beginning of the Vardata field.</p>
<p>283) What are Hashed Tables?</p>
<p>Ans Hashed tables – This is the most appropriate type for any table where the main operation is key access. You cannot access a hashed table using its index. The response time for key access remains constant, regardless of the number of table entries. Like database tables, hashed tables always have a unique key. Hashed tables are useful if you want to construct and use an internal table, which resembles a database table or for processing large amounts of data.</p>
<p>SAMPLE PROG: THIS DOES NOTHING.</p>
<p>REPORT Z_1 .</p>
<p>TABLES: MARA.</p>
<p>DATA: I TYPE HASHED TABLE OF MARA WITH UNIQUE KEY MATNR</p>
<p>284) How did you test the form u developed? How did you take the print of it?</p>
<p>Ans</p>
<p>285) How many maximum number of fields can be there in a table?</p>
<p>Ans</p>
<p>286) How many primary keys can be there in a table?</p>
<p>Ans</p>
<p>287) What are the steps to perform Performance Tuning? What will you do increase the performance of your system?</p>
<p>Ans</p>
<p>288) What is mandatory in Screen Painter?</p>
<p>Ans</p>
<p>289) If u are entering large amount of data, and system fails, then how many records will be entered or no records or half records will be entered?</p>
<p>Ans</p>
<p>290) In Screen Painter, if two fields are mandatory and user do not want to enter anything but he wants to come out of the screen, then what will he do?</p>
<p>Ans</p>
<p>291) What is At-Exit and User-Exit?</p>
<p>Ans</p>
<p>292) How will you find the standard tables, you only know there names like Customer Master Table?</p>
<p>Ans</p>
<p>293) How will change Development Class?</p>
<p>Ans</p>
<p>294) How will you call both Function Module and Function Group?</p>
<p>Ans</p>
<p>295) What is ALV?</p>
<p>Ans</p>
<p>296) What is Chain-Field &amp; Chain-Loop?</p>
<p>Ans</p>
<p>297) What is Value-Ranges?</p>
<p>Ans</p>
<p>298) How will you provide help for value request particular fields?</p>
<p>Ans</p>
<p>299) How will you find relationship between two or more tables?</p>
<p>Ans</p>
<p>300) In BDC’s, if you forget to write one field, then how will you modify that field in your BDC program?</p>
<p>Ans</p>
<p>301) Detail concept of Transport Organizer.</p>
<p>Ans</p>
<p>302) Which is slower “Select *” and “Select field1,field2”?</p>
<p>Ans</p>
<p>303) What are the errors in “Call Transaction”?</p>
<p>Ans</p>
<p>304) What is QA and production?</p>
<p>Ans</p>
<p>305) How will you display only 10 lines in Report?</p>
<p>Ans</p>
<p>306) In BDC, if out of 10 records, 7 are successful and there are 3 records with some missing fields, how will you modify those fields?</p>
<p>Ans</p>
<p>307) How will you set breakpoint to 100 messages?</p>
<p>Ans</p>
<p>308) How will you set Reports to Background job?</p>
<p>Ans</p>
<p>309) Name the tables, which is used to see all the transaction available.</p>
<p>Ans See tables, TSTC and TSTCT for all the transaction available<br />
311) How to schedule a Report in background? what is the use of background job please explain about it?</p>
<p>Ans There are 3 ways to schedule in background:</p>
<p>SM36</p>
<p>SE38</p>
<p>SA38</p>
<p>The easiest of the three is SA38.</p>
<p>Why background? In foreground jobs are only allowed a certain amount of runtime. Long running jobs usually times out in foreground, and have to be run background. Some customers has day-end jobs to fill custom tables, and these only run late at night, so they are scheduled as background jobs as well. There may be any of a hundred reasons why you want a job to run in background instead of foreground, and these are only 2 of them.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pdftutorials.com/questions/sap-abap-interview-questions.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP Interview Questions</title>
		<link>http://www.pdftutorials.com/questions/php-interview-questions.html</link>
		<comments>http://www.pdftutorials.com/questions/php-interview-questions.html#comments</comments>
		<pubDate>Thu, 13 Oct 2011 13:30:56 +0000</pubDate>
		<dc:creator>Tutorial Master</dc:creator>
				<category><![CDATA[questions]]></category>

		<guid isPermaLink="false">http://www.pdftutorials.com/test/?p=3854</guid>
		<description><![CDATA[PHP Interview Questions Frequently asked PHP Interview Questions What’s PHP ? difference between PHP4 and PHP5? What Is a Session? How can we register the variables into a session? What is meant by PEAR in php? How can we repair a MySQL table? What Is a Persistent Cookie? What does a special set of tags <a href="http://www.pdftutorials.com/questions/php-interview-questions.html"> read more <span class="meta-nav">&#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p>PHP Interview Questions</p>
<p>Frequently asked PHP Interview Questions</p>
<p>What’s PHP ?<br />
difference between PHP4 and PHP5?<br />
What Is a Session?<br />
How can we register the variables into a session?<br />
What is meant by PEAR in php?<br />
How can we repair a MySQL table?<br />
What Is a Persistent Cookie?<br />
What does a special set of tags &lt;?= and ?&gt; do in PHP?<br />
How do you define a constant?<br />
What are the differences between require and include, include_once?<br />
How can I execute a PHP script using command line?<br />
What is meant by urlencode and urldecode?<br />
What is the difference between include and require?<br />
What is the difference between mysql_fetch_object and mysql_fetch_array?<br />
How can I execute a PHP script using command line?<br />
How To Create a Table using PHP?<br />
How can we encrypt the username and password using PHP?<br />
How do you pass a variable by value?<br />
difference between ereg_replace() and eregi_replace()?<br />
differences between DROP a table and TRUNCATE a table?<br />
DIFFERENT TYPES OF ERRORS IN PHP?<br />
How can we submit a form without a submit button?<br />
How can we get the browser properties using PHP?<br />
Would you initialize your strings with single quotes or double quotes?<br />
What are the differences between GET and POST methods in form submitting?<br />
difference between the functions unlink and unset?<br />
How can we know the count/number of elements of an array?<br />
How many ways we can pass the variable through the navigation between the pages?<br />
How can we find the number of rows in a result set using PHP?<br />
How many ways we can we find the current date using MySQL?<br />
How can we know the number of days between two given dates using MySQL?<br />
What is the difference between GROUP BY and ORDER BY in SQL?<br />
differences between  mysql_fetch_array(),  mysql_fetch_object(), mysql_fetch_row()?<br />
What is meant by nl2br()?<br />
difference between htmlentities() and htmlspecialchars()?<br />
can we increase the execution time of a php script?<br />
What are cookies and  How to set cookies?<br />
How can we destroy the cookie?<br />
What is the use of friend function?<br />
What is the maximum size of a file that can be uploaded using PHP and how can we change this?<br />
What are the difference between abstract class and interface?<br />
What type of inheritance that php supports?<br />
How do I find out the number of parameters passed into function?<br />
How can increase the performance of MySQL select query?<br />
How to store the uploaded file to the final location?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pdftutorials.com/questions/php-interview-questions.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ORACLE INTERVIEW QUESTIONS</title>
		<link>http://www.pdftutorials.com/questions/oracle-interview-questions.html</link>
		<comments>http://www.pdftutorials.com/questions/oracle-interview-questions.html#comments</comments>
		<pubDate>Thu, 13 Oct 2011 13:30:13 +0000</pubDate>
		<dc:creator>Tutorial Master</dc:creator>
				<category><![CDATA[questions]]></category>

		<guid isPermaLink="false">http://www.pdftutorials.com/test/?p=3852</guid>
		<description><![CDATA[What is the maximum number of columns in a table of oracle DB ? 254 What are the various types of queries in Oracle ? The types of queries are: Normal Queries Sub Queries Co-related queries Nested queries Compound queries What are the components of physical database structure of Oracle database? Oracle database is comprised <a href="http://www.pdftutorials.com/questions/oracle-interview-questions.html"> read more <span class="meta-nav">&#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p>What is the maximum number of columns in a table of oracle DB ?<br />
254</p>
<p>What are the various types of queries in Oracle ?</p>
<p>The types of queries are:</p>
<p>Normal Queries<br />
Sub Queries<br />
Co-related queries<br />
Nested queries<br />
Compound queries</p>
<p>What are the components of physical database structure of Oracle database?<br />
Oracle database is comprised of three types of files. One or more datafiles, two are more redo log files, and one or more control files.</p>
<p>What are actual and formal parameters ?<br />
Actual Parameters : Subprograms pass information using parameters.The variables or expressions referenced in the parameter list of a subprogram call are actual parameters.For example, the following procedure call lists two actual parameters named emp_num and amount:<br />
Eg.raise_salary(emp_num, amount);<br />
Formal Parameters : The variables declared in a subprogram specification and referenced in the subprogram body are formal parameters.For example, the following procedure declares two formal parameters named emp_id and increase:<br />
Eg.PROCEDURE raise_salary (emp_id INTEGER, increase REAL) IS current_salary REAL;</p>
<p>What are various types of joins in Oracle ?<br />
Types of joins are:</p>
<p>Equijoins<br />
Non-equijoins<br />
self join<br />
outer join</p>
<p>What are the components of logical database structure of Oracle database?<br />
There are tablespaces and database’s schema objects.</p>
<p>What’s the length of SQL integer?<br />
32 bit</p>
<p>What is a tablespace?<br />
A database is divided into Logical Storage Unit called tablespaces. A tablespace is used to grouped related logical structures together.</p>
<p>What is an oracle instance?<br />
What is an Archiver in Oracle?<br />
What is a partition of table in Oracle?</p>
<p>What is a transaction in Oracle ?<br />
A transaction is a set of SQL statements between any two COMMIT and ROLLBACK statements.</p>
<p>What is SYSTEM tablespace and when is it created?<br />
Every Oracle database contains a tablespace named SYSTEM, which is automatically created when the database is created. The SYSTEM tablespace always contains the data dictionary tables for the entire database.</p>
<p>Explain the relationship among database, tablespace and data file ?<br />
Each databases logically divided into one or more tablespaces one or more data files are explicitly created for each tablespace.</p>
<p>What are the various types of Exceptions in Oracle ?<br />
User defined Exceptions<br />
Predefined Exceptions</p>
<p>What is implicit cursor and how is it used by Oracle ?<br />
An implicit cursor is a cursor which is internally created by Oracle.It is created by Oracle for each individual SQL</p>
<p>What is schema?<br />
A schema is collection of database objects of a user.</p>
<p>What are the types of Notation in Oracle ?<br />
Position, Named, Mixed and Restrictions.</p>
<p>What is an exception in Oracle?<br />
What is a synonym in Oracle?<br />
What is a join, and what are the different types of joins in Oracle?</p>
<p>What are Schema Objects?<br />
Schema objects are the logical structures that directly refer to the database’s data. Schema objects include tables, views, sequences, synonyms, indexes, clusters, database triggers, procedures, functions packages and database links.</p>
<p>Can objects of the same schema reside in different tablespaces?<br />
Yes.</p>
<p>Can a tablespace hold objects from different schemes?<br />
Yes.</p>
<p>What is Oracle table?<br />
A table is the basic unit of data storage in an Oracle database. The tables of a database hold all of the user accessible data. Table data is stored in rows and columns.</p>
<p>What is an Oracle view?<br />
A view is a virtual table. Every view has a query attached to it. (The query is a SELECT statement that identifies the columns and rows of the table(s) the view uses.)</p>
<p>What is Partial Backup ?<br />
A Partial Backup is any operating system backup short of a full backup, taken while the database is open or shut down.</p>
<p>What is Mirrored on-line Redo Log ?</p>
<p>A mirrored on-line redo log consists of copies of on-line redo log files physically located on separate disks, changes made to one member of the group are made to all members.</p>
<p>What are the various types of parameter modes in a procedure in Oracle ?</p>
<p>IN<br />
OUT<br />
INOUT</p>
<p>What is Full Backup ?<br />
A full backup is an operating system backup of all data files, on-line redo log files and control file that constitute ORACLE database and the parameter.</p>
<p>Can a View based on another View ?<br />
Yes.</p>
<p>Can a Tablespace hold objects from different Schemes ?<br />
Yes.</p>
<p>Can objects of the same Schema reside in different tablespace ?<br />
Yes.</p>
<p>What is the use of Control File ?<br />
When an instance of an ORACLE database is started, its control file is used to identify the database and redo log files that must be opened for database operation to proceed. It is also used in database recovery.</p>
<p>hat is a schema in Oracle?<br />
ODBC stands for?<br />
What is mean by de-normalization?</p>
<p>Do View contain Data ?<br />
Views do not contain or store data.</p>
<p>What are the Referential actions supported by FOREIGN KEY integrity constraint ?<br />
UPDATE and DELETE Restrict – A referential integrity rule that disallows the update or deletion of referenced data. DELETE Cascade – When a referenced row is deleted all associated dependent rows are deleted.</p>
<p>What are the type of Synonyms?<br />
There are two types of Synonyms Private and Public.</p>
<p>What is a Redo Log ?<br />
The set of Redo Log files YSDATE,UID,USER or USERENV SQL functions, or the pseudo columns LEVEL or ROWNUM.</p>
<p>What is an Index Segment ?<br />
Each Index has an Index segment that stores all of its data.</p>
<p>What is a cursor?<br />
Advantages of redo log files?<br />
What is referential integrity?</p>
<p>Explain the relationship among Database, Tablespace and Data file?<br />
Each databases logically divided into one or more tablespaces one or more data files are explicitly created for each tablespace</p>
<p>What are the different type of Segments ?<br />
Data Segment, Index Segment, Rollback Segment and Temporary Segment.</p>
<p>What are Clusters ?<br />
Clusters are groups of one or more tables physically stores together to share common columns and are often used together.</p>
<p>What is an Integrity Constrains ?<br />
An integrity constraint is a declarative way to define a business rule for a column of a table.</p>
<p>What is an Index ?<br />
An Index is an optional structure associated with a table to have direct access to rows, which can be created to increase the</p>
<p>performance of data retrieval. Index can be created on one or more columns of a table.</p>
<p>What is an Extent ?<br />
An Extent is a specific number of contiguous data blocks, obtained in a single allocation, and used to store a specific type of information.</p>
<p>What is a View ?<br />
A view is a virtual table. Every view has a Query attached to it. (The Query is a SELECT statement that identifies the</p>
<p>columns and rows of the table(s) the view uses.)</p>
<p>What is Table ?<br />
A table is the basic unit of data storage in an ORACLE database. The tables of a database hold all of the user accessible data. Table data is stored in rows and columns.</p>
<p>What is a co-related sub-query?<br />
What are the steps in a two-phase commit?</p>
<p>Can a view based on another view?<br />
Yes.</p>
<p>What are the advantages of views?<br />
- Provide an additional level of table security, by restricting access to a predetermined set of rows and columns of a table.<br />
- Hide data complexity.<br />
- Simplify commands for the user.<br />
- Present the data in a different perspective from that of the base table.<br />
- Store complex queries.</p>
<p>What is an Oracle sequence?<br />
A sequence generates a serial list of unique numbers for numerical columns of a database’s tables.</p>
<p>What is a synonym?<br />
A synonym is an alias for a table, view, sequence or program unit.</p>
<p>What are the types of synonyms?<br />
There are two types of synonyms private and public.</p>
<p>What is a private synonym?<br />
Only its owner can access a private synonym.</p>
<p>What is a public synonym?<br />
Any database user can access a public synonym.</p>
<p>What are synonyms used for?<br />
- Mask the real name and owner of an object.<br />
- Provide public access to an object<br />
- Provide location transparency for tables, views or program units of a remote database.<br />
- Simplify the SQL statements for database users.</p>
<p>What is an Oracle index?<br />
An index is an optional structure associated with a table to have direct access to rows, which can be created to increase the performance of data retrieval. Index can be created on one or more columns of a table.</p>
<p>How are the index updates?<br />
Indexes are automatically maintained and used by Oracle. Changes to table data are automatically incorporated into all relevant indexes.</p>
<p>Describe the Normalization principles?<br />
Data-type used to work with integers is?</p>
<p>What is a Tablespace?<br />
A database is divided into Logical Storage Unit called tablespace. A tablespace is used to grouped related logical structures</p>
<p>together</p>
<p>What is Rollback Segment ?<br />
A Database contains one or more Rollback Segments to temporarily store “undo” information.</p>
<p>What are the Characteristics of Data Files ?<br />
A data file can be associated with only one database. Once created a data file can’t change size. One or more data files form a logical unit of database storage called a tablespace.</p>
<p>How to define Data Block size ?<br />
A data block size is specified for each ORACLE database when the database is created. A database users and allocated free database space in ORACLE data blocks. Block size is specified in INIT.ORA file and can’t be changed latter.</p>
<p>What does a Control file Contain ?<br />
A Control file records the physical structure of the database. It contains the following information.<br />
Database Name<br />
Names and locations of a database’s files and redolog files.<br />
Time stamp of database creation.</p>
<p>What is difference between UNIQUE constraint and PRIMARY KEY constraint ?</p>
<p>A column defined as UNIQUE can contain Nulls while a column defined as PRIMARY KEY can’t contain Nulls.</p>
<p>What is Index Cluster ?<br />
A Cluster with an index on the Cluster Key</p>
<p>When does a Transaction end ?<br />
When it is committed or Rollbacked.</p>
<p>What is the effect of setting the value “ALL_ROWS” for OPTIMIZER_GOAL parameter of the ALTER SESSION command ? What are the factors that affect OPTIMIZER in choosing an Optimization approach ?<br />
Answer The OPTIMIZER_MODE initialization parameter Statistics in the Data Dictionary the OPTIMIZER_GOAL parameter of the</p>
<p>ALTER SESSION command hints in the statement.</p>
<p>What is the effect of setting the value “CHOOSE” for OPTIMIZER_GOAL, parameter of the ALTER SESSION Command ?<br />
The Optimizer chooses Cost_based approach and optimizes with the goal of best throughput if statistics for atleast one of the tables accessed by the SQL statement exist in the data dictionary. Otherwise the OPTIMIZER chooses RULE_based approach.</p>
<p>How does one create a new database? (for DBA)<br />
One can create and modify Oracle databases using the Oracle “dbca” (Database Configuration Assistant) utility. The dbca utility is located in the $ORACLE_HOME/bin directory. The Oracle Universal Installer (oui) normally starts it after installing the database server software.<br />
One can also create databases manually using scripts. This option, however, is falling out of fashion, as it is quite involved and error prone.</p>
<p>What is a trigger?<br />
What is a union, intersect, minus in Oracle?</p>
<p>What database block size should I use? (for DBA)<br />
Oracle recommends that your database block size match, or be multiples of your operating system block size. One can use smaller block sizes, but the performance cost is significant. Your choice should depend on the type of application you are running. If you have many small transactions as with OLTP, use a smaller block size. With fewer but larger transactions, as with a DSS application, use a larger block size. If you are using a volume manager, consider your “operating system block size” to be 8K. This is because volume manager products use 8K blocks (and this is not configurable).</p>
<p>What are the different approaches used by Optimizer in choosing an execution plan ?<br />
Rule-based and Cost-based.</p>
<p>What does ROLLBACK do ?<br />
ROLLBACK retracts any of the changes resulting from the SQL statements in the transaction.</p>
<p>How does one coalesce free space ? (for DBA)<br />
SMON coalesces free space (extents) into larger, contiguous extents every 2 hours and even then, only for a short period of time.<br />
SMON will not coalesce free space if a tablespace’s default storage parameter “pctincrease” is set to 0. With Oracle 7.3 one</p>
<p>can manually coalesce a tablespace using the ALTER TABLESPACE … COALESCE; command, until then use:<br />
SQL&gt; alter session set events ‘immediate trace name coalesce level n’;<br />
Where ‘n’ is the tablespace number you get from SELECT TS#, NAME FROM SYS.TS$;<br />
You can get status information about this process by selecting from the SYS.DBA_FREE_SPACE_COALESCED dictionary view.</p>
<p>How does one prevent tablespace fragmentation? (for DBA)<br />
Always set PCTINCREASE to 0 or 100.<br />
Bizarre values for PCTINCREASE will contribute to fragmentation. For example if you set PCTINCREASE to 1 you will see that your extents are going to have weird and wacky sizes: 100K, 100K, 101K, 102K, etc. Such extents of bizarre size are rarely re-used in their entirety. PCTINCREASE of 0 or 100 gives you nice round extent sizes that can easily be reused. E.g.. 100K, 100K, 200K, 400K, etc.</p>
<p>What is a collection of privileges?<br />
What is a database buffer cache in Oracle?</p>
<p>Use the same extent size for all the segments in a given tablespace. Locally Managed tablespaces (available from 8i onwards) with uniform extent sizes virtually eliminates any tablespace fragmentation. Note that the number of extents per segment does not cause any performance issue anymore, unless they run into thousands and thousands where additional I/O may be required to fetch the additional blocks where extent maps of the segment are stored.</p>
<p>Where can one find the high water mark for a table? (for DBA)<br />
There is no single system table, which contains the high water mark (HWM) for a table. A table’s HWM can be calculated using the results from the following SQL statements:<br />
SELECT BLOCKS<br />
FROM DBA_SEGMENTS<br />
WHERE OWNER=UPPER(owner) AND SEGMENT_NAME = UPPER(table);<br />
ANALYZE TABLE owner.table ESTIMATE STATISTICS;<br />
SELECT EMPTY_BLOCKS<br />
FROM DBA_TABLES<br />
WHERE OWNER=UPPER(owner) AND SEGMENT_NAME = UPPER(table);<br />
Thus, the tables’ HWM = (query result 1) – (query result 2) – 1<br />
NOTE: You can also use the DBMS_SPACE package and calculate the HWM = TOTAL_BLOCKS – UNUSED_BLOCKS – 1.</p>
<p>What is COST-based approach to optimization ?<br />
Considering available access paths and determining the most efficient execution plan based on statistics in the data dictionary for the tables accessed by the statement and their associated clusters and indexes.</p>
<p>What does COMMIT do ?<br />
COMMIT makes permanent the changes resulting from all SQL statements in the transaction. The changes made by the SQL statements of a transaction become visible to other user sessions transactions that start only after transaction is committed.</p>
<p>How are extents allocated to a segment? (for DBA)<br />
Oracle8 and above rounds off extents to a multiple of 5 blocks when more than 5 blocks are requested. If one requests 16K or 2 blocks (assuming a 8K block size), Oracle doesn’t round it up to 5 blocks, but it allocates 2 blocks or 16K as requested. If one asks for 8 blocks, Oracle will round it up to 10 blocks.Space allocation also depends upon the size of contiguous free space available. If one asks for 8 blocks and Oracle finds a contiguous free space that is exactly 8 blocks, it would give it you. If it were 9 blocks, Oracle would also give it to you. Clearly Oracle doesn’t always round extents to a multiple of 5 blocks.The exception to this rule is locally managed tablespaces. If a tablespace is created with local extent management and the extent size is 64K, then Oracle allocates 64K or 8 blocks assuming 8K-block size. Oracle doesn’t round it up to the multiple of 5 when a tablespace is locally managed.</p>
<p>Name the data dictionary that stores user-defined constraints?</p>
<p>Can one rename a database user (schema)? (for DBA)<br />
No, this is listed as Enhancement Request 158508. Workaround:<br />
Do a user-level export of user A<br />
create new user B<br />
Import system/manager fromuser=A touser=B<br />
Drop user A</p>
<p>Define Transaction ?<br />
A Transaction is a logical unit of work that comprises one or more SQL statements executed by a single user.</p>
<p>What is Read-Only Transaction ?<br />
A Read-Only transaction ensures that the results of each query executed in the transaction are consistant with respect to the same point in time.</p>
<p>What is a deadlock ? Explain .<br />
Two processes wating to update the rows of a table which are locked by the other process then deadlock arises. In a database environment this will often happen because of not issuing proper row lock commands. Poor design of front-end application may cause this situation and the performance of server will reduce drastically.These locks will be released automatically when a commit/rollback operation performed or any one of this processes being<br />
killed externally.</p>
<p>What is a Schema ?<br />
The set of objects owned by user account is called the schema.</p>
<p>What is a cluster Key ?<br />
The related columns of the tables are called the cluster key. The cluster key is indexed using a cluster index and its value is stored only once for multiple tables in the cluster.</p>
<p>What are the Data Control statements?</p>
<p>What is Parallel Server ?<br />
Multiple instances accessing the same database (Only In Multi-CPU environments)</p>
<p>What are the basic element of Base configuration of an oracle Database ?<br />
It consists of<br />
one or more data files.<br />
one or more control files.<br />
two or more redo log files.<br />
The Database contains<br />
multiple users/schemas<br />
one or more rollback segments<br />
one or more tablespaces<br />
Data dictionary tables<br />
User objects (table,indexes,views etc.,)<br />
The server that access the database consists of<br />
SGA (Database buffer, Dictionary Cache Buffers, Redo log buffers, Shared SQL pool)<br />
SMON (System MONito)<br />
PMON (Process MONitor)<br />
LGWR (LoG Write)<br />
DBWR (Data Base Write)<br />
ARCH (ARCHiver)<br />
CKPT (Check Point)<br />
RECO<br />
Dispatcher<br />
User Process with associated PGS</p>
<p>What is clusters ?<br />
Group of tables physically stored together because they share common columns and are often used together is called Cluster.</p>
<p>Describe data models?</p>
<p>What is an Index ? How it is implemented in Oracle Database ?<br />
An index is a database structure used by the server to have direct access of a row in a table. An index is automatically created when a unique of primary key constraint clause is specified in create table comman (Ver 7.0)</p>
<p>What is a Database instance ? Explain<br />
A database instance (Server) is a set of memory structure and background processes that access a set of database files.The process can be shared by all users. The memory structure that are used to store most queried data from database. This helps up to improve database performance by decreasing the amount of I/O performed against data file.</p>
<p>What is the use of ANALYZE command ?<br />
To perform one of these function on an index, table, or cluster:<br />
- To collect statistics about object used by the optimizer and store them in the data dictionary.<br />
- To delete statistics about the object used by object from the data dictionary.<br />
- To validate the structure of the object.<br />
- To identify migrated and chained rows of the table or cluster.</p>
<p>What is default tablespace ?<br />
The Tablespace to contain schema objects created without specifying a tablespace name.</p>
<p>What are the system resources that can be controlled through Profile ?<br />
The number of concurrent sessions the user can establish the CPU processing time available to the user’s session the CPU processing time available to a single call to ORACLE made by a SQL statement the amount of logical I/O available to the user’s session the amout of logical I/O available to a single call to ORACLE made by a SQL statement the allowed amount of<br />
idle time for the user’s session the allowed amount of connect time for the user’s session.</p>
<p>What is Tablespace Quota ?<br />
The collective amount of disk space available to the objects in a schema on a particular tablespace.</p>
<p>What are the different Levels of Auditing ?<br />
Statement Auditing, Privilege Auditing and Object Auditing.</p>
<p>What are the types of Normalization?</p>
<p>What is Statement Auditing ?<br />
Statement auditing is the auditing of the powerful system privileges without regard to specifically named objects.</p>
<p>What are the database administrators utilities available ?<br />
SQL * DBA – This allows DBA to monitor and control an ORACLE database. SQL * Loader – It loads data from standard operating system files (Flat files) into ORACLE database tables. Export (EXP) and Import (imp) utilities allow you to move existing data in ORACLE format to and from ORACLE database.</p>
<p>How can you enable automatic archiving ?<br />
Shut the database<br />
Backup the database<br />
Modify/Include LOG_ARCHIVE_START_TRUE in init.ora file.<br />
Start up the database.</p>
<p>What are roles? How can we implement roles ?<br />
Roles are the easiest way to grant and manage common privileges needed by different groups of database users. Creating roles and assigning provides to roles. Assign each role to group of users. This will simplify the job of assigning privileges to individual users.</p>
<p>What are Roles ?<br />
Roles are named groups of related privileges that are granted to users or other roles.</p>
<p>What are the background processes in Oracle?</p>
<p>What are the use of Roles ?<br />
REDUCED GRANTING OF PRIVILEGES – Rather than explicitly granting the same set of privileges to many users a database</p>
<p>administrator can grant the privileges for a group of related users granted to a role and then grant only the role to each member of the group.<br />
DYNAMIC PRIVILEGE MANAGEMENT – When the privileges of a group must change, only the privileges of the role need to be modified. The security domains of all users granted the group’s role automatically reflect the changes made to the role.SELECTIVE AVAILABILITY OF PRIVILEGES – The roles granted to a user can be selectively enable (available for use) or disabled (not available for use). This allows specific control of a user’s privileges in any given situation.APPLICATION AWARENESS – A database application can be designed to automatically enable and disable selective roles when a user attempts to use the application.</p>
<p>What is Privilege Auditing ?<br />
Privilege auditing is the auditing of the use of powerful system privileges without regard to specifically named objects.</p>
<p>What is Object Auditing ?<br />
Object auditing is the auditing of accesses to specific schema objects without regard to user.</p>
<p>What is Auditing ?<br />
Monitoring of user access to aid in the investigation of database use.</p>
<p>What is a snapshot?</p>
<p>Where are my TEMPFILES, I don’t see them in V$DATAFILE or DBA_DATA_FILE? (for DBA )<br />
Tempfiles, unlike normal datafiles, are not listed in v$datafile or dba_data_files. Instead query v$tempfile or</p>
<p>dba_temp_files:<br />
SELECT * FROM v$tempfile;<br />
SELECT * FROM dba_temp_files;</p>
<p>How do I find used/free space in a TEMPORARY tablespace? (for DBA )<br />
Unlike normal tablespaces, true temporary tablespace information is not listed in DBA_FREE_SPACE. Instead use the V$TEMP_SPACE_HEADER view:SELECT tablespace_name, SUM (bytes used), SUM (bytes free)<br />
FROM V$temp_space_header<br />
GROUP BY tablespace_name;</p>
<p>What is a profile ?<br />
Each database user is assigned a Profile that specifies limitations on various system resources available to the user.</p>
<p>How will you enforce security using stored procedures?<br />
Don’t grant user access directly to tables within the application. Instead grant the ability to access the procedures that access the tables. When procedure executed it will execute the privilege of procedures owner. Users cannot access tables except via the procedure.</p>
<p>What is a sequence?</p>
<p>How does one get the view definition of fixed views/tables?<br />
Query v$fixed_view_definition. Example: SELECT * FROM v$fixed_view_definition WHERE view_name=’V$SESSION’;</p>
<p>What are the dictionary tables used to monitor a database spaces ?<br />
DBA_FREE_SPACE<br />
DBA_SEGMENTS<br />
DBA_DATA_FILES.</p>
<p>How can we specify the Archived log file name format and destination?<br />
By setting the following values in init.ora file. LOG_ARCHIVE_FORMAT = arch %S/s/T/tarc (%S – Log sequence number and is zero</p>
<p>left paded, %s – Log sequence number not padded. %T – Thread number lef-zero-paded and %t – Thread number not padded). The file name created is arch 0001 are if %S is used. LOG_ARCHIVE_DEST = path.</p>
<p>What is user Account in Oracle database?<br />
An user account is not a physical structure in Database but it is having important relationship to the objects in the database and will be having certain privileges.</p>
<p>When will the data in the snapshot log be used?<br />
We must be able to create a after row trigger on table (i.e., it should be not be already available) After giving table privileges. We cannot specify snapshot log name because oracle uses the name of the master table in the name of the database objects that support its snapshot log. The master table name should be less than or equal to 23 characters. (The table name created will be MLOGS_tablename, and trigger name will be TLOGS name).</p>
<p>What dynamic data replication?<br />
Updating or Inserting records in remote database through database triggers. It may fail if remote database is having any problem.</p>
<p>What is Two-Phase Commit ?<br />
Two-phase commit is mechanism that guarantees a distributed transaction either commits on all involved nodes or rolls back on all involved nodes to maintain data consistency across the global distributed database. It has two phase, a Prepare Phase and a Commit Phase.</p>
<p>How can you Enforce Referential Integrity in snapshots ?<br />
Time the references to occur when master tables are not in use. Peform the reference the manually immdiately locking the master tables. We can join tables in snopshots by creating a complex snapshots that will based on the master tables.</p>
<p>What is a SQL * NET?<br />
SQL *NET is ORACLE’s mechanism for interfacing with the communication protocols used by the networks that facilitate distributed processing and distributed databases. It is used in Clint-Server and Server-Server communications.</p>
<p>What is a SNAPSHOT ?<br />
Snapshots are read-only copies of a master table located on a remote node which is periodically refreshed to reflect changes made to the master table.</p>
<p>What is the mechanism provided by ORACLE for table replication ?<br />
Snapshots and SNAPSHOT LOGs</p>
<p>What is snapshots?<br />
Snapshot is an object used to dynamically replicate data between distribute database at specified time intervals. In ver 7.0 they are read only.</p>
<p>What are the various type of snapshots?<br />
Simple and Complex.</p>
<p>Describe two phases of Two-phase commit ?<br />
Prepare phase – The global coordinator (initiating node) ask a participants to prepare (to promise to commit or rollback the transaction, even if there is a failure) Commit – Phase – If all participants respond to the coordinator that they are prepared, the coordinator asks all nodes to commit the transaction, if all participants cannot prepare, the coordinator asks all nodes to roll back the transaction.</p>
<p>What are the min.extents allocated to a rollback extent in Oracle ?<br />
Two</p>
<p>What is snapshot log ?<br />
It is a table that maintains a record of modifications to the master table in a snapshot. It is stored in the same database as master table and is only available for simple snapshots. It should be created before creating snapshots.</p>
<p>What are the benefits of distributed options in databases?<br />
Database on other servers can be updated and those transactions can be grouped together with others in a logical unit.<br />
Database uses a two phase commit.</p>
<p>What are the options available to refresh snapshots ?<br />
COMPLETE – Tables are completely regenerated using the snapshots query and the master tables every time the snapshot referenced.<br />
FAST – If simple snapshot used then a snapshot log can be used to send the changes to the snapshot tables.<br />
FORCE – Default value. If possible it performs a FAST refresh; Otherwise it will perform a complete refresh.</p>
<p>What is a SNAPSHOT LOG ?<br />
A snapshot log is a table in the master database that is associated with the master table. ORACLE uses a snapshot log to track the rows that have been updated in the master table. Snapshot logs are used in updating the snapshots based on the master table.</p>
<p>What is Distributed database ?<br />
A distributed database is a network of databases managed by multiple database servers that appears to a user as single</p>
<p>logical database. The data of all databases in the distributed database can be simultaneously accessed and modified.</p>
<p>How can we reduce the network traffic?<br />
- Replication of data in distributed environment.<br />
- Using snapshots to replicate data.<br />
- Using remote procedure calls.</p>
<p>Differentiate simple and complex, snapshots ?<br />
- A simple snapshot is based on a query that does not contains GROUP BY clauses, CONNECT BY clauses, JOINs, sub-query or</p>
<p>snashot of operations.<br />
- A complex snapshots contain atleast any one of the above.</p>
<p>What are the Built-ins used for sending Parameters to forms?<br />
You can pass parameter values to a form when an application executes the call_form, New_form, Open_form or Run_product.</p>
<p>Can you have more than one content canvas view attached with a window?<br />
Yes. Each window you create must have atleast one content canvas view assigned to it. You can also create a window that has</p>
<p>manipulated content canvas view. At run time only one of the content canvas views assign to a window is displayed at a time.</p>
<p>Is the After report trigger fired if the report execution fails?<br />
Yes.</p>
<p>What is Multi Threaded Server (MTA) in Oracle ?<br />
In a Single Threaded Architecture (or a dedicated server configuration) the database manager creates a separate process for</p>
<p>each database user.But in MTA the database manager can assign multiple users (multiple user processes) to a single dispatcher</p>
<p>(server process), a controlling process that queues request for work thus reducing the databases memory requirement and</p>
<p>resources.</p>
<p>Does a Before form trigger fire when the parameter form is suppressed?<br />
Yes.</p>
<p>What is SGA?<br />
The System Global Area in an Oracle database is the area in memory to facilitate the transfer of information between users.</p>
<p>It holds the most recently requested structural information between users. It holds the most recently requested structural</p>
<p>information about the database. The structure is database buffers, dictionary cache, redo log buffer and shared pool area.</p>
<p>What is a shared pool?<br />
The data dictionary cache is stored in an area in SGA called the shared pool. This will allow sharing of parsed SQL</p>
<p>statements among concurrent users.</p>
<p>What is mean by Program Global Area (PGA)?<br />
It is area in memory that is used by a single Oracle user process.</p>
<p>What is a data segment?<br />
Data segment are the physical areas within a database block in which the data associated with tables and clusters are stored.</p>
<p>What are the factors causing the reparsing of SQL statements in SGA?<br />
Due to insufficient shared pool size.<br />
Monitor the ratio of the reloads takes place while executing SQL statements. If the ratio is greater than 1 then increase the</p>
<p>SHARED_POOL_SIZE.</p>
<p>What are clusters?<br />
Clusters are groups of one or more tables physically stores together to share common columns and are often used together.</p>
<p>What is cluster key?<br />
The related columns of the tables in a cluster are called the cluster key.</p>
<p>Do a view contain data?<br />
Views do not contain or store data.</p>
<p>What is user Account in Oracle database?<br />
A user account is not a physical structure in database but it is having important relationship to the objects in the database</p>
<p>and will be having certain privileges.</p>
<p>How will you enforce security using stored procedures?<br />
Don’t grant user access directly to tables within the application. Instead grant the ability to access the procedures that</p>
<p>access the tables. When procedure executed it will execute the privilege of procedures owner. Users cannot access tables</p>
<p>except via the procedure.</p>
<p>What are the dictionary tables used to monitor a database space?<br />
DBA_FREE_SPACE<br />
DBA_SEGMENTS<br />
DBA_DATA_FILES.</p>
<p>Can a property clause itself be based on a property clause?<br />
Yes</p>
<p>If a parameter is used in a query without being previously defined, what diff. exist between. report 2.0 and 2.5 when the</p>
<p>query is applied?<br />
While both reports 2.0 and 2.5 create the parameter, report 2.5 gives a message that a bind parameter has been created.</p>
<p>What are the sql clauses supported in the link property sheet?<br />
Where start with having.</p>
<p>What is trigger associated with the timer?<br />
When-timer-expired.</p>
<p>What are the trigger associated with image items?<br />
When-image-activated fires when the operators double clicks on an image itemwhen-image-pressed fires when an operator clicks</p>
<p>or double clicks on an image item</p>
<p>What are the different windows events activated at runtimes?<br />
When_window_activated<br />
When_window_closed<br />
When_window_deactivated<br />
When_window_resized<br />
Within this triggers, you can examine the built in system variable system. event_window to determine the name of the window</p>
<p>for which the trigger fired.</p>
<p>When do you use data parameter type?<br />
When the value of a data parameter being passed to a called product is always the name of the record group defined in the</p>
<p>current form. Data parameters are used to pass data to products invoked with the run_product built-in subprogram.</p>
<p>What is difference between open_form and call_form?<br />
when one form invokes another form by executing open_form the first form remains displayed, and operators can navigate</p>
<p>between the forms as desired. when one form invokes another form by executing call_form, the called form is modal with</p>
<p>respect to the calling form. That is, any windows that belong to the calling form are disabled, and operators cannot navigate</p>
<p>to them until they first exit the called form.</p>
<p>What is new_form built-in?<br />
When one form invokes another form by executing new_form oracle form exits the first form and releases its memory before</p>
<p>loading the new form calling new form completely replace the first with the second. If there are changes pending in the first</p>
<p>form, the operator will be prompted to save them before the new form is loaded.</p>
<p>What is the “LOV of Validation” Property of an item? What is the use of it?<br />
When LOV for Validation is set to True, Oracle Forms compares the current value of the text item to the values in the first</p>
<p>column displayed in the LOV. Whenever the validation event occurs. If the value in the text item matches one of the values in</p>
<p>the first column of the LOV, validation succeeds, the LOV is not displayed, and processing continues normally. If the value</p>
<p>in the text item does not match one of the values in the first column of the LOV, Oracle Forms displays the LOV and uses the</p>
<p>text item value as the search criteria to automatically reduce the list.</p>
<p>What is the diff. when Flex mode is mode on and when it is off?<br />
When flex mode is on, reports automatically resizes the parent when the child is resized.</p>
<p>What is the diff. when confine mode is on and when it is off?<br />
When confine mode is on, an object cannot be moved outside its parent in the layout.</p>
<p>What are visual attributes?<br />
Visual attributes are the font, color, pattern proprieties that you set for form and menu objects that appear in your</p>
<p>application interface.</p>
<p>Which of the two views should objects according to possession?<br />
view by structure.</p>
<p>What are the two types of views available in the object navigator(specific to report 2.5)?<br />
View by structure and view by type .</p>
<p>What are the vbx controls?<br />
Vbx control provide a simple method of building and enhancing user interfaces. The controls can use to obtain user inputs and</p>
<p>display program outputs.vbx control where originally develop as extensions for the ms visual basic environments and include</p>
<p>such items as sliders, rides and knobs.</p>
<p>What is the use of transactional triggers?<br />
Using transactional triggers we can control or modify the default functionality of the oracle forms.</p>
<p>How do you create a new session while open a new form?<br />
Using open_form built-in setting the session option Ex. Open_form(‘Stocks ‘,active, session). when invoke the multiple forms</p>
<p>with open form and call_form in the same application, state whether the following are true/False</p>
<p>What are the ways to monitor the performance of the report?<br />
Use reports profile executable statement. Use SQL trace facility.</p>
<p>If two groups are not linked in the data model editor, What is the hierarchy between them?<br />
Two group that is above are the left most rank higher than the group that is to right or below it.</p>
<p>An open form can not be execute the call_form procedure if you chain of called forms has been initiated by another open form?<br />
True</p>
<p>Explain about horizontal, Vertical tool bar canvas views?<br />
Tool bar canvas views are used to create tool bars for individual windows. Horizontal tool bars are display at the top of a</p>
<p>window, just under its menu bar. Vertical Tool bars are displayed along the left side of a window</p>
<p>What is the purpose of the product order option in the column property sheet?<br />
To specify the order of individual group evaluation in a cross products.</p>
<p>What is the use of image_zoom built-in?<br />
To manipulate images in image items.</p>
<p>How do you reference a parameter indirectly?<br />
To indirectly reference a parameter use the NAME IN, COPY ‘built-ins to indirectly set and reference the parameters value’</p>
<p>Example name_in (‘capital parameter my param’), Copy (‘SURESH’,&#8217;Parameter my_param’)</p>
<p>What is a timer?<br />
Timer is an “internal time clock” that you can programmatically create to perform an action each time the times.</p>
<p>What are the two phases of block coordination?<br />
There are two phases of block coordination: the clear phase and the population phase. During, the clear phase, Oracle Forms</p>
<p>navigates internally to the detail block and flushes the obsolete detail records. During the population phase, Oracle Forms</p>
<p>issues a SELECT statement to repopulate the detail block with detail records associated with the new master record. These</p>
<p>operations are accomplished through the execution of triggers.</p>
<p>What are Most Common types of Complex master-detail relationships?<br />
There are three most common types of complex master-detail relationships:<br />
master with dependent details<br />
master with independent details<br />
detail with two masters</p>
<p>What is a text list?<br />
The text list style list item appears as a rectangular box which displays the fixed number of values. When the text list</p>
<p>contains values that can not be displayed, a vertical scroll bar appears, allowing the operator to view and select</p>
<p>undisplayed values.</p>
<p>What is term?<br />
The term is terminal definition file that describes the terminal form which you are using r20run.</p>
<p>What is use of term?<br />
The term file which key is correspond to which oracle report functions.</p>
<p>What is pop list?<br />
The pop list style list item appears initially as a single field (similar to a text item field). When the operator selects</p>
<p>the list icon, a list of available choices appears.</p>
<p>What is the maximum no of chars the parameter can store?<br />
The maximum no of chars the parameter can store is only valid for char parameters, which can be upto 64K. No parameters</p>
<p>default to 23Bytes and Date parameter default to 7Bytes.</p>
<p>What are the default extensions of the files created by library module?<br />
The default file extensions indicate the library module type and storage format .pll – pl/sql library module binary</p>
<p>What are the Coordination Properties in a Master-Detail relationship?<br />
The coordination properties are<br />
Deferred<br />
Auto-Query<br />
These Properties determine when the population phase of block<br />
coordination should occur.</p>
<p>How do you display console on a window ?<br />
The console includes the status line and message line, and is displayed at the bottom of the window to which it is</p>
<p>assigned.To specify that the console should be displayed, set the console window form property to the name of any window in</p>
<p>the form. To include the console, set console window to Null.</p>
<p>What are the different Parameter types?<br />
Text ParametersData Parameters</p>
<p>State any three mouse events system variables?<br />
System.mouse_button_pressedSystem.mouse_button_shift</p>
<p>What are the types of calculated columns available?<br />
Summary, Formula, Placeholder column.</p>
<p>Explain about stacked canvas views?<br />
Stacked canvas view is displayed in a window on top of, or “stacked” on the content canvas view assigned to that same window.</p>
<p>Stacked canvas views obscure some part of the underlying content canvas view, and or often shown and hidden programmatically.</p>
<p>How does one do off-line database backups? (for DBA )<br />
Shut down the database from sqlplus or server manager. Backup all files to secondary storage (eg. tapes). Ensure that you</p>
<p>backup all data files, all control files and all log files. When completed, restart your database.<br />
Do the following queries to get a list of all files that needs to be backed up:<br />
select name from sys.v_$datafile;<br />
select member from sys.v_$logfile;<br />
select name from sys.v_$controlfile;<br />
Sometimes Oracle takes forever to shutdown with the “immediate” option. As workaround to this problem, shutdown using these</p>
<p>commands:<br />
alter system checkpoint;<br />
shutdown abort<br />
startup restrict<br />
shutdown immediate<br />
Note that if you database is in ARCHIVELOG mode, one can still use archived log files to roll forward from an off-line</p>
<p>backup. If you cannot take your database down for a cold (off-line) backup at a convenient time, switch your database into</p>
<p>ARCHIVELOG mode and perform hot (on-line) backups.</p>
<p>What is the difference between SHOW_EDITOR and EDIT_TEXTITEM?<br />
Show editor is the generic built-in which accepts any editor name and takes some input string and returns modified output</p>
<p>string. Whereas the edit_textitem built-in needs the input focus to be in the text item before the built-in is executed.</p>
<p>What are the built-ins that are used to Attach an LOV programmatically to an item?<br />
set_item_property<br />
get_item_property<br />
(by setting the LOV_NAME property)</p>
<p>How does one do on-line database backups? (for DBA )<br />
Each tablespace that needs to be backed-up must be switched into backup mode before copying the files out to secondary</p>
<p>storage (tapes). Look at this simple example.<br />
ALTER TABLESPACE xyz BEGIN BACKUP;<br />
! cp xyfFile1 /backupDir/<br />
ALTER TABLESPACE xyz END BACKUP;<br />
It is better to backup tablespace for tablespace than to put all tablespaces in backup mode. Backing them up separately</p>
<p>incurs less overhead. When done, remember to backup your control files. Look at this example:<br />
ALTER SYSTEM SWITCH LOGFILE; — Force log switch to update control file headers<br />
ALTER DATABASE BACKUP CONTROLFILE TO ‘/backupDir/control.dbf’;<br />
NOTE: Do not run on-line backups during peak processing periods. Oracle will write complete database blocks instead of the</p>
<p>normal deltas to redo log files while in backup mode. This will lead to excessive database archiving and even database</p>
<p>freezes.</p>
<p>What are the different file extensions that are created by oracle reports?<br />
Rep file and Rdf file.</p>
<p>What is strip sources generate options?<br />
Removes the source code from the library file and generates a library files that contains only pcode. The resulting file can</p>
<p>be used for final deployment, but can not be subsequently edited in the designer.ex. f45gen module=old_lib.pll</p>
<p>userid=scott/tiger strip_source YES output_file</p>
<p>How does one put a database into ARCHIVELOG mode? (for DBA )<br />
The main reason for running in archivelog mode is that one can provide 24-hour availability and guarantee complete data</p>
<p>recoverability. It is also necessary to enable ARCHIVELOG mode before one can start to use on-line database backups. To</p>
<p>enable ARCHIVELOG mode, simply change your database startup command script, and bounce the database:<br />
SQLPLUS&gt; connect sys as sysdba<br />
SQLPLUS&gt; startup mount exclusive;<br />
SQLPLUS&gt; alter database archivelog;<br />
SQLPLUS&gt; archive log start;<br />
SQLPLUS&gt; alter database open;<br />
NOTE1: Remember to take a baseline database backup right after enabling archivelog mode. Without it one would not be able to</p>
<p>recover. Also, implement an archivelog backup to prevent the archive log directory from filling-up.<br />
NOTE2: ARCHIVELOG mode was introduced with Oracle V6, and is essential for database point-in-time recovery. Archiving can be</p>
<p>used in combination with on-line and off-line database backups.<br />
NOTE3: You may want to set the following INIT.ORA parameters when enabling ARCHIVELOG mode: log_archive_start=TRUE,</p>
<p>log_archive_dest=… and log_archive_format=…<br />
NOTE4: You can change the archive log destination of a database on-line with the ARCHIVE LOG START TO ‘directory’; statement.</p>
<p>This statement is often used to switch archiving between a set of directories.<br />
NOTE5: When running Oracle Real Application Server (RAC), you need to shut down all nodes before changing the database to</p>
<p>ARCHIVELOG mode.</p>
<p>What is the basic data structure that is required for creating an LOV?<br />
Record Group.</p>
<p>How does one backup archived log files? (for DBA )<br />
One can backup archived log files using RMAN or any operating system backup utility. Remember to delete files after backing</p>
<p>them up to prevent the archive log directory from filling up. If the archive log directory becomes full, your database will</p>
<p>hang! Look at this simple RMAN backup script:<br />
RMAN&gt; run {<br />
2&gt; allocate channel dev1 type disk;<br />
3&gt; backup<br />
4&gt; format ‘/app/oracle/arch_backup/log_t%t_s%s_p%p’<br />
5&gt; (archivelog all delete input);<br />
6&gt; release channel dev1;<br />
7&gt; }</p>
<p>Does Oracle write to data files in begin/hot backup mode? (for DBA )<br />
Oracle will stop updating file headers, but will continue to write data to the database files even if a tablespace is in</p>
<p>backup mode.<br />
In backup mode, Oracle will write out complete changed blocks to the redo log files. Normally only deltas (changes) are</p>
<p>logged to the redo logs. This is done to enable reconstruction of a block if only half of it was backed up (split blocks).</p>
<p>Because of this, one should notice increased log activity and archiving during on-line backups.</p>
<p>What is the Maximum allowed length of Record group Column?<br />
Record group column names cannot exceed 30 characters.</p>
<p>Which parameter can be used to set read level consistency across multiple queries?<br />
Read only</p>
<p>What are the different types of Record Groups?<br />
Query Record Groups<br />
NonQuery Record Groups<br />
State Record Groups</p>
<p>From which designation is it preferred to send the output to the printed?<br />
Previewer</p>
<p>What are difference between post database commit and post-form commit?<br />
Post-form commit fires once during the post and commit transactions process, after the database commit occurs. The</p>
<p>post-form-commit trigger fires after inserts, updates and deletes have been posted to the database but before the</p>
<p>transactions have been finalized in the issuing the command. The post-database-commit trigger fires after oracle forms issues</p>
<p>the commit to finalized transactions.</p>
<p>What are the different display styles of list items?<br />
Pop_listText_listCombo box</p>
<p>Which of the above methods is the faster method?<br />
performing the calculation in the query is faster.</p>
<p>With which function of summary item is the compute at options required?<br />
percentage of total functions.</p>
<p>What are parameters?<br />
Parameters provide a simple mechanism for defining and setting the valuesof inputs that are required by a form at startup.</p>
<p>Form parameters are variables of type char,number,date that you define at design time.</p>
<p>What are the three types of user exits available ?<br />
Oracle Precompiler exits, Oracle call interface, NonOracle user exits.</p>
<p>How many windows in a form can have console?<br />
Only one window in a form can display the console, and you cannot change the console assignment at runtime.</p>
<p>What is an administrative (privileged) user? (for DBA )<br />
Oracle DBAs and operators typically use administrative accounts to manage the database and database instance. An</p>
<p>administrative account is a user that is granted SYSOPER or SYSDBA privileges. SYSDBA and SYSOPER allow access to a database</p>
<p>instance even if it is not running. Control of these privileges is managed outside of the database via password files and</p>
<p>special operating system groups. This password file is created with the orapwd utility.</p>
<p>What are the two repeating frame always associated with matrix object?<br />
One down repeating frame below one across repeating frame.</p>
<p>What are the master-detail triggers?<br />
On-Check_delete_masterOn_clear_detailsOn_populate_details</p>
<p>How does one connect to an administrative user? (for DBA )<br />
If an administrative user belongs to the “dba” group on Unix, or the “ORA_DBA” (ORA_sid_DBA) group on NT, he/she can connect</p>
<p>like this:<br />
connect / as sysdba<br />
No password is required. This is equivalent to the desupported “connect internal” method.<br />
A password is required for “non-secure” administrative access. These passwords are stored in password files. Remote</p>
<p>connections via Net8 are classified as non-secure. Look at this example:<br />
connect sys/password as sysdba</p>
<p>How does one create a password file? (for DBA )<br />
The Oracle Password File ($ORACLE_HOME/dbs/orapw or orapwSID) stores passwords for users with administrative privileges. One</p>
<p>needs to create a password files before remote administrators (like OEM) will be allowed to connect.<br />
Follow this procedure to create a new password file:<br />
. Log in as the Oracle software owner<br />
. Runcommand: orapwd file=$ORACLE_HOME/dbs/orapw$ORACLE_SID password=mypasswd<br />
. Shutdown the database (SQLPLUS&gt; SHUTDOWN IMMEDIATE)<br />
. Edit the INIT.ORA file and ensure REMOTE_LOGIN_PASSWORDFILE=exclusive is set.<br />
. Startup the database (SQLPLUS&gt; STARTUP)<br />
NOTE: The orapwd utility presents a security risk in that it receives a password from the command line. This password is</p>
<p>visible in the process table of many systems. Administrators needs to be aware of this!</p>
<p>Is it possible to modify an external query in a report which contains it?<br />
No.</p>
<p>Does a grouping done for objects in the layout editor affect the grouping done in the data model editor?<br />
No.</p>
<p>How does one add users to a password file? (for DBA )<br />
One can select from the SYS.V_$PWFILE_USERS view to see which users are listed in the password file. New users can be added</p>
<p>to the password file by granting them SYSDBA or SYSOPER privileges, or by using the orapwd utility. GRANT SYSDBA TO scott;</p>
<p>If a break order is set on a column would it affect columns which are under the column?<br />
No</p>
<p>Why are OPS$ accounts a security risk in a client/server environment? (for DBA)<br />
If you allow people to log in with OPS$ accounts from Windows Workstations, you cannot be sure who they really are. With</p>
<p>terminals, you can rely on operating system passwords, with Windows, you cannot.<br />
If you set REMOTE_OS_AUTHENT=TRUE in your init.ora file, Oracle assumes that the remote OS has authenticated the user. If</p>
<p>REMOTE_OS_AUTHENT is set to FALSE (recommended), remote users will be unable to connect without a password. IDENTIFIED</p>
<p>EXTERNALLY will only be in effect from the local host. Also, if you are using “OPS$” as your prefix, you will be able to log</p>
<p>on locally with or without a password, regardless of whether you have identified your ID with a password or defined it to be</p>
<p>IDENTIFIED EXTERNALLY.</p>
<p>Do user parameters appear in the data modal editor in 2.5?<br />
No</p>
<p>Can you pass data parameters to forms?<br />
No</p>
<p>Is it possible to link two groups inside a cross products after the cross products group has been created?<br />
no</p>
<p>What are the different modals of windows?<br />
Modalless windows<br />
Modal windows</p>
<p>What are modal windows?<br />
Modal windows are usually used as dialogs, and have restricted functionality compared to modelless windows. On some platforms</p>
<p>for example operators cannot resize, scroll or iconify a modal window.</p>
<p>What are the different default triggers created when Master Deletes Property is set to Non-isolated?<br />
Master Deletes Property Resulting Triggers<br />
—————————————————-<br />
Non-Isolated(the default) On-Check-Delete-Master<br />
On-Clear-Details<br />
On-Populate-Details</p>
<p>What are the different default triggers created when Master Deletes Property is set to isolated?<br />
Master Deletes Property Resulting Triggers<br />
—————————————————<br />
Isolated On-Clear-Details<br />
On-Populate-Details</p>
<p>What are the different default triggers created when Master Deletes Property is set to Cascade?<br />
Master Deletes Property Resulting Triggers<br />
—————————————————<br />
Cascading On-Clear-Details<br />
On-Populate-Details<br />
Pre-delete</p>
<p>What is the diff. bet. setting up of parameters in reports 2.0 reports2.5?<br />
LOVs can be attached to parameters in the reports 2.5 parameter form.</p>
<p>What are the difference between lov &amp; list item?<br />
Lov is a property where as list item is an item. A list item can have only one column, lov can have one or more columns.</p>
<p>What is the advantage of the library?<br />
Libraries provide a convenient means of storing client-side program units and sharing them among multiple applications. Once</p>
<p>you create a library, you can attach it to any other form, menu, or library modules. When you can call library program units</p>
<p>from triggers menu items commands and user named routine, you write in the modules to which you have attach the library. When</p>
<p>a library attaches another library, program units in the first library can reference program units in the attached library.</p>
<p>Library support dynamic loading-that is library program units are loaded into an application only when needed. This can</p>
<p>significantly reduce the run-time memory requirements of applications.</p>
<p>What is lexical reference? How can it be created?<br />
Lexical reference is place_holder for text that can be embedded in a sql statements. A lexical reference can be created using</p>
<p>&amp; before the column or parameter name.</p>
<p>What is system.coordination_operation?<br />
It represents the coordination causing event that occur on the master block in master-detail relation.</p>
<p>What is synchronize?<br />
It is a terminal screen with the internal state of the form. It updates the screen display to reflect the information that</p>
<p>oracle forms has in its internal representation of the screen.</p>
<p>What use of command line parameter cmd file?<br />
It is a command line argument that allows you to specify a file that contain a set of arguments for r20run.</p>
<p>What is a Text_io Package?<br />
It allows you to read and write information to a file in the file system.</p>
<p>What is forms_DDL?<br />
Issues dynamic Sql statements at run time, including server side pl/SQl and DDL</p>
<p>How is link tool operation different bet. reports 2 &amp; 2.5?<br />
In Reports 2.0 the link tool has to be selected and then two fields to be linked are selected and the link is automatically</p>
<p>created. In 2.5 the first field is selected and the link tool is then used to link the first field to the second field.</p>
<p>What are the different styles of activation of ole Objects?<br />
In place activationExternal activation</p>
<p>How do you reference a Parameter?<br />
In Pl/Sql, You can reference and set the values of form parameters using bind variables syntax. Ex. PARAMETER name = ” or</p>
<p>:block.item = PARAMETER Parameter name</p>
<p>What is the difference between object embedding &amp; linking in Oracle forms?<br />
In Oracle forms, Embedded objects become part of the form module, and linked objects are references from a form module to a</p>
<p>linked source file.</p>
<p>Name of the functions used to get/set canvas properties?<br />
Get_view_property, Set_view_property</p>
<p>What are the built-ins that are used for setting the LOV properties at runtime?<br />
get_lov_property<br />
set_lov_property</p>
<p>What are the built-ins used for processing rows?<br />
Get_group_row_count(function)<br />
Get_group_selection_count(function)<br />
Get_group_selection(function)<br />
Reset_group_selection(procedure)<br />
Set_group_selection(procedure)<br />
Unset_group_selection(procedure)</p>
<p>What are built-ins used for Processing rows?<br />
GET_GROUP_ROW_COUNT(function)<br />
GET_GROUP_SELECTION_COUNT(function)<br />
GET_GROUP_SELECTION(function)<br />
RESET_GROUP_SELECTION(procedure)<br />
SET_GROUP_SELECTION(procedure)<br />
UNSET_GROUP_SELECTION(procedure)</p>
<p>What are the built-in used for getting cell values?<br />
Get_group_char_cell(function)<br />
Get_groupcell(function)<br />
Get_group_number_cell(function)</p>
<p>What are the built-ins used for Getting cell values?<br />
GET_GROUP_CHAR_CELL (function)<br />
GET_GROUPCELL(function)<br />
GET_GROUP_NUMBET_CELL(function)</p>
<p>Atleast how many set of data must a data model have before a data model can be base on it?<br />
Four</p>
<p>To execute row from being displayed that still use column in the row which property can be used?<br />
Format trigger.</p>
<p>What are different types of modules available in oracle form?<br />
Form module – a collection of objects and code routines Menu modules – a collection of menus and menu item commands that</p>
<p>together make up an application menu library module – a collection of user named procedures, functions and packages that can</p>
<p>be called from other modules in the application</p>
<p>What is the remove on exit property?<br />
For a modelless window, it determines whether oracle forms hides the window automatically when the operators navigates to an</p>
<p>item in the another window.</p>
<p>What is WHEN-Database-record trigger?<br />
Fires when oracle forms first marks a record as an insert or an update. The trigger fires as soon as oracle forms determines</p>
<p>through validation that the record should be processed by the next post or commit as an insert or update. c generally occurs</p>
<p>only when the operators modifies the first item in the record, and after the operator attempts to navigate out of the item.</p>
<p>What is a difference between pre-select and pre-query?<br />
Fires during the execute query and count query processing after oracle forms constructs the select statement to be issued,</p>
<p>but before the statement is actually issued. The pre-query trigger fires just before oracle forms issues the select statement</p>
<p>to the database after the operator as define the example records by entering the query criteria in enter query mode.Pre-query</p>
<p>trigger fires before pre-select trigger.</p>
<p>What are built-ins associated with timers?<br />
find_timercreate_timerdelete_timer</p>
<p>What are the built-ins used for finding object ID functions?<br />
Find_group(function)<br />
Find_column(function)</p>
<p>What are the built-ins used for finding Object ID function?<br />
FIND_GROUP(function)<br />
FIND_COLUMN(function)</p>
<p>Any attempt to navigate programmatically to disabled form in a call_form stack is allowed?<br />
False</p>
<p>Use the Add_group_row procedure to add a row to a static record group 1. true or false?<br />
False</p>
<p>What third party tools can be used with Oracle EBU/ RMAN? (for DBA)<br />
The following Media Management Software Vendors have integrated their media management software packages with Oracle Recovery</p>
<p>Manager and Oracle7 Enterprise Backup Utility. The Media Management Vendors will provide first line technical support for the</p>
<p>integrated backup/recover solutions.<br />
Veritas NetBackup<br />
EMC Data Manager (EDM)<br />
HP OMNIBack II<br />
IBM’s Tivoli Storage Manager – formerly ADSM<br />
Legato Networker<br />
ManageIT Backup and Recovery<br />
Sterling Software’s SAMS:Alexandria – formerly from Spectralogic<br />
Sun Solstice Backup</p>
<p>Why and when should one tune? (for DBA)<br />
One of the biggest responsibilities of a DBA is to ensure that the Oracle database is tuned properly. The Oracle RDBMS is</p>
<p>highly tunable and allows the database to be monitored and adjusted to increase its performance. One should do performance</p>
<p>tuning for the following reasons:<br />
The speed of computing might be wasting valuable human time (users waiting for response); Enable your system to keep-up with</p>
<p>the speed business is conducted; and Optimize hardware usage to save money (companies are spending millions on hardware).</p>
<p>Although this FAQ is not overly concerned with hardware issues, one needs to remember than you cannot tune a Buick into a</p>
<p>Ferrari.</p>
<p>How can a break order be created on a column in an existing group? What are the various sub events a mouse double click event</p>
<p>involves?<br />
By dragging the column outside the group.</p>
<p>What is the use of place holder column? What are the various sub events a mouse double click event involves?<br />
A placeholder column is used to hold calculated values at a specified place rather than allowing is to appear in the actual</p>
<p>row where it has to appear.</p>
<p>What is the use of hidden column? What are the various sub events a mouse double click event involves?<br />
A hidden column is used to when a column has to embed into boilerplate text.</p>
<p>What database aspects should be monitored? (for DBA)<br />
One should implement a monitoring system to constantly monitor the following aspects of a database. Writing custom scripts,</p>
<p>implementing Oracle’s Enterprise Manager, or buying a third-party monitoring product can achieve this. If an alarm is</p>
<p>triggered, the system should automatically notify the DBA (e-mail, page, etc.) to take appropriate action.<br />
Infrastructure availability:<br />
. Is the database up and responding to requests<br />
. Are the listeners up and responding to requests<br />
. Are the Oracle Names and LDAP Servers up and responding to requests<br />
. Are the Web Listeners up and responding to requests</p>
<p>Things that can cause service outages:<br />
. Is the archive log destination filling up?<br />
. Objects getting close to their max extents<br />
. User and process limits reached</p>
<p>Things that can cause bad performance:<br />
See question “What tuning indicators can one use?”.</p>
<p>Where should the tuning effort be directed? (for DBA)<br />
Consider the following areas for tuning. The order in which steps are listed needs to be maintained to prevent tuning side</p>
<p>effects. For example, it is no good increasing the buffer cache if you can reduce I/O by rewriting a SQL statement. Database</p>
<p>Design (if it’s not too late):<br />
Poor system performance usually results from a poor database design. One should generally normalize to the 3NF. Selective</p>
<p>denormalization can provide valuable performance improvements. When designing, always keep the “data access path” in mind.</p>
<p>Also look at proper data partitioning, data replication, aggregation tables for decision support systems, etc.<br />
Application Tuning:<br />
Experience showed that approximately 80% of all Oracle system performance problems are resolved by coding optimal SQL. Also</p>
<p>consider proper scheduling of batch tasks after peak working hours.<br />
Memory Tuning:<br />
Properly size your database buffers (shared pool, buffer cache, log buffer, etc) by looking at your buffer hit ratios. Pin</p>
<p>large objects into memory to prevent frequent reloads.<br />
Disk I/O Tuning:<br />
Database files needs to be properly sized and placed to provide maximum disk subsystem throughput. Also look for frequent</p>
<p>disk sorts, full table scans, missing indexes, row chaining, data fragmentation, etc<br />
Eliminate Database Contention:<br />
Study database locks, latches and wait events carefully and eliminate where possible. Tune the Operating System:<br />
Monitor and tune operating system CPU, I/O and memory utilization. For more information, read the related Oracle FAQ dealing</p>
<p>with your specific operating system.</p>
<p>What are the various sub events a mouse double click event involves? What are the various sub events a mouse double click</p>
<p>event involves?<br />
Double clicking the mouse consists of the mouse down, mouse up, mouse click, mouse down &amp; mouse up events.</p>
<p>What are the default parameter that appear at run time in the parameter screen? What are the various sub events a mouse</p>
<p>double click event involves?<br />
Destype and Desname.</p>
<p>What are the built-ins used for Creating and deleting groups?<br />
CREATE-GROUP (function)<br />
CREATE_GROUP_FROM_QUERY(function)<br />
DELETE_GROUP(procedure)</p>
<p>What are different types of canvas views?<br />
Content canvas views<br />
Stacked canvas views<br />
Horizontal toolbar<br />
vertical toolbar.</p>
<p>What are the different types of Delete details we can establish in Master-Details?<br />
Cascade<br />
Isolate<br />
Non-isolate</p>
<p>What is relation between the window and canvas views?<br />
Canvas views are the back ground objects on which you place the interface items (Text items), check boxes, radio groups</p>
<p>etc.,) and boilerplate objects (boxes, lines, images etc.,) that operators interact with us they run your form . Each canvas</p>
<p>views displayed in a window.</p>
<p>What is a User_exit?<br />
Calls the user exit named in the user_exit_string. Invokes a 3Gl program by name which has been properly linked into your</p>
<p>current oracle forms executable.</p>
<p>How is it possible to select generate a select set for the query in the query property sheet?<br />
By using the tables/columns button and then specifying the table and the column names.</p>
<p>How can values be passed bet. precompiler exits &amp; Oracle call interface?<br />
By using the statement EXECIAFGET &amp; EXECIAFPUT.</p>
<p>How can a square be drawn in the layout editor of the report writer?<br />
By using the rectangle tool while pressing the (Constraint) key.</p>
<p>How can a text file be attached to a report while creating in the report writer?<br />
By using the link file property in the layout boiler plate property sheet.</p>
<p>How can I message to passed to the user from reports?<br />
By using SRW.MESSAGE function.</p>
<p>Does one need to drop/ truncate objects before importing? (for DBA)<br />
Before one import rows into already populated tables, one needs to truncate or drop these tables to get rid of the old data.</p>
<p>If not, the new data will be appended to the existing tables. One must always DROP existing Sequences before re-importing. If</p>
<p>the sequences are not dropped, they will generate numbers inconsistent with the rest of the database. Note: It is also</p>
<p>advisable to drop indexes before importing to speed up the import process. Indexes can easily be recreated after the data was</p>
<p>successfully imported.</p>
<p>How can a button be used in a report to give a drill down facility?<br />
By setting the action associated with button to Execute pl/sql option and using the SRW.Run_report function.</p>
<p>Can one import/export between different versions of Oracle? (for DBA)<br />
Different versions of the import utility is upwards compatible. This means that one can take an export file created from an</p>
<p>old export version, and import it using a later version of the import utility. This is quite an effective way of upgrading a</p>
<p>database from one release of Oracle to the next.<br />
Oracle also ships some previous catexpX.sql scripts that can be executed as user SYS enabling older imp/exp versions to work</p>
<p>(for backwards compatibility). For example, one can run $ORACLE_HOME/rdbms/admin/catexp7.sql on an Oracle 8 database to allow</p>
<p>the Oracle 7.3 exp/imp utilities to run against an Oracle 8 database.</p>
<p>What are different types of images?<br />
Boiler plate imagesImage Items</p>
<p>What is bind reference and how can it be created?<br />
Bind reference are used to replace the single value in sql, pl/sql statements a bind reference can be created using a (:)</p>
<p>before a column or a parameter name.</p>
<p>How can one improve Import/ Export performance? (for DBA)<br />
EXPORT:</p>
<p>. Set the BUFFER parameter to a high value (e.g. 2M)<br />
. Set the RECORDLENGTH parameter to a high value (e.g. 64K)<br />
. Stop unnecessary applications to free-up resources for your job.<br />
. If you run multiple export sessions, ensure they write to different physical disks.<br />
. DO NOT export to an NFS mounted filesystem. It will take forever.<br />
IMPORT:</p>
<p>. Create an indexfile so that you can create indexes AFTER you have imported data. Do this by setting INDEXFILE to a filename</p>
<p>and then import. No data will be imported but a file containing index definitions will be created. You must edit this file</p>
<p>afterwards and supply the passwords for the schemas on all CONNECT statements.<br />
. Place the file to be imported on a separate physical disk from the oracle data files<br />
. Increase DB_CACHE_SIZE (DB_BLOCK_BUFFERS prior to 9i) considerably in the init$SID.ora file<br />
. Set the LOG_BUFFER to a big value and restart oracle.<br />
. Stop redo log archiving if it is running (ALTER DATABASE NOARCHIVELOG;)<br />
. Create a BIG tablespace with a BIG rollback segment inside. Set all other rollback segments offline (except the SYSTEM</p>
<p>rollback segment of course). The rollback segment must be as big as your biggest table (I think?)<br />
. Use COMMIT=N in the import parameter file if you can afford it<br />
. Use ANALYZE=N in the import parameter file to avoid time consuming ANALYZE statements<br />
. Remember to run the indexfile previously created</p>
<p>Give the sequence of execution of the various report triggers?<br />
Before form , After form , Before report, Between page, After report.</p>
<p>What are the common Import/ Export problems? (for DBA )<br />
ORA-00001: Unique constraint (…) violated – You are importing duplicate rows. Use IGNORE=NO to skip tables that already</p>
<p>exist (imp will give an error if the object is re-created).<br />
ORA-01555: Snapshot too old – Ask your users to STOP working while you are exporting or use parameter CONSISTENT=NO<br />
ORA-01562: Failed to extend rollback segment – Create bigger rollback segments or set parameter COMMIT=Y while importing<br />
IMP-00015: Statement failed … object already exists… – Use the IGNORE=Y import parameter to ignore these errors, but be</p>
<p>careful as you might end up with duplicate rows.</p>
<p>Why is it preferable to create a fewer no. of queries in the data model?<br />
Because for each query, report has to open a separate cursor and has to rebind, execute and fetch data.</p>
<p>Where is the external query executed at the client or the server?<br />
At the server.</p>
<p>Where is a procedure return in an external pl/sql library executed at the client or at the server?<br />
At the client.</p>
<p>What is coordination Event?<br />
Any event that makes a different record in the master block the current record is a coordination causing event.</p>
<p>What is the difference between OLE Server &amp; Ole Container?<br />
An Ole server application creates ole Objects that are embedded or linked in ole Containers ex. Ole servers are ms_word &amp;</p>
<p>ms_excel. OLE containers provide a place to store, display and manipulate objects that are created by ole server</p>
<p>applications. Ex. oracle forms is an example of an ole Container.</p>
<p>What is an object group?<br />
An object group is a container for a group of objects; you define an object group when you want to package related objects,</p>
<p>so that you copy or reference them in other modules.</p>
<p>What is an LOV?<br />
An LOV is a scrollable popup window that provides the operator with either a single or multi column selection list.</p>
<p>At what point of report execution is the before Report trigger fired?<br />
After the query is executed but before the report is executed and the records are displayed.</p>
<p>What are the built -ins used for Modifying a groups structure?<br />
ADD-GROUP_COLUMN (function)<br />
ADD_GROUP_ROW (procedure)<br />
DELETE_GROUP_ROW(procedure)</p>
<p>What is an user exit used for?<br />
A way in which to pass control (and possibly arguments ) form Oracle report to another Oracle products of 3 GL and then</p>
<p>return control ( and ) back to Oracle reports.</p>
<p>What is the User-Named Editor?<br />
A user named editor has the same text editing functionality as the default editor, but, because it is a named object, you can</p>
<p>specify editor attributes such as windows display size, position, and title.</p>
<p>My database was terminated while in BACKUP MODE, do I need to recover? (for DBA)<br />
If a database was terminated while one of its tablespaces was in BACKUP MODE (ALTER TABLESPACE xyz BEGIN BACKUP;), it will</p>
<p>tell you that media recovery is required when you try to restart the database. The DBA is then required to recover the</p>
<p>database and apply all archived logs to the database. However, from Oracle7.2, you can simply take the individual datafiles</p>
<p>out of backup mode and restart the database.<br />
ALTER DATABASE DATAFILE ‘/path/filename’ END BACKUP;<br />
One can select from V$BACKUP to see which datafiles are in backup mode. This normally saves a significant amount of database</p>
<p>down time.<br />
Thiru Vadivelu contributed the following:<br />
From Oracle9i onwards, the following command can be used to take all of the datafiles out of hot backup mode:<br />
ALTER DATABASE END BACKUP;<br />
The above commands need to be issued when the database is mounted.</p>
<p>What is a Static Record Group?<br />
A static record group is not associated with a query, rather, you define its structure and row values at design time, and</p>
<p>they remain fixed at runtime.</p>
<p>What is a record group?<br />
A record group is an internal Oracle Forms that structure that has a column/row framework similar to a database table.</p>
<p>However, unlike database tables, record groups are separate objects that belong to the form module which they are defined.</p>
<p>My database is down and I cannot restore. What now? (for DBA )<br />
Recovery without any backup is normally not supported, however, Oracle Consulting can sometimes extract data from an offline</p>
<p>database using a utility called DUL (Disk UnLoad). This utility reads data in the data files and unloads it into SQL*Loader</p>
<p>or export dump files. DUL does not care about rollback segments, corrupted blocks, etc, and can thus not guarantee that the</p>
<p>data is not logically corrupt. It is intended as an absolute last resort and will most likely cost your company a lot of</p>
<p>money!!!</p>
<p>I’ve lost my REDOLOG files, how can I get my DB back? (for DBA)<br />
The following INIT.ORA parameter may be required if your current redo logs are corrupted or blown away. Caution is advised</p>
<p>when enabling this parameter as you might end-up losing your entire database. Please contact Oracle Support before using it.</p>
<p>_allow_resetlogs_corruption = true</p>
<p>What is a property clause?<br />
A property clause is a named object that contains a list of properties and their settings. Once you create a property clause</p>
<p>you can base other object on it. An object based on a property can inherit the setting of any property in the clause that</p>
<p>makes sense for that object.</p>
<p>What is a physical page ? &amp; What is a logical page ?<br />
A physical page is a size of a page. That is output by the printer. The logical page is the size of one page of the actual</p>
<p>report as seen in the Previewer.</p>
<p>I’ve lost some Rollback Segments, how can I get my DB back? (for DBA)<br />
Re-start your database with the following INIT.ORA parameter if one of your rollback segments is corrupted. You can then drop</p>
<p>the corrupted rollback segments and create it from scratch.<br />
Caution is advised when enabling this parameter, as uncommitted transactions will be marked as committed. One can very well</p>
<p>end up with lost or inconsistent data!!! Please contact Oracle Support before using it. _Corrupted_rollback_segments =</p>
<p>(rbs01, rbs01, rbs03, rbs04)</p>
<p>What are the differences between EBU and RMAN? (for DBA)<br />
Enterprise Backup Utility (EBU) is a functionally rich, high performance interface for backing up Oracle7 databases. It is</p>
<p>sometimes referred to as OEBU for Oracle Enterprise Backup Utility. The Oracle Recovery Manager (RMAN) utility that ships</p>
<p>with Oracle8 and above is similar to Oracle7′s EBU utility. However, there is no direct upgrade path from EBU to RMAN.</p>
<p>How does one create a RMAN recovery catalog? (for DBA)<br />
Start by creating a database schema (usually called rman). Assign an appropriate tablespace to it and grant it the</p>
<p>recovery_catalog_owner role. Look at this example:<br />
sqlplus sys<br />
SQL&gt;create user rman identified by rman;<br />
SQL&gt; alter user rman default tablespace tools temporary tablespace temp;<br />
SQL&gt; alter user rman quota unlimited on tools;<br />
SQL&gt; grant connect, resource, recovery_catalog_owner to rman;<br />
SQL&gt; exit;<br />
Next, log in to rman and create the catalog schema. Prior to Oracle 8i this was done by running the catrman.sql script. rman</p>
<p>catalog rman/rman<br />
RMAN&gt;create catalog tablespace tools;<br />
RMAN&gt; exit;<br />
You can now continue by registering your databases in the catalog. Look at this example:<br />
rman catalog rman/rman target backdba/backdba<br />
RMAN&gt; register database;</p>
<p>How can a group in a cross products be visually distinguished from a group that does not form a cross product?<br />
A group that forms part of a cross product will have a thicker border.</p>
<p>What is the frame &amp; repeating frame?</p>
<p>A frame is a holder for a group of fields. A repeating frame is used to display a set of records when the no. of records that are to displayed is not known before.</p>
<p>What is a combo box?<br />
A combo box style list item combines the features found in list and text item. Unlike the pop list or the text list style</p>
<p>list items, the combo box style list item will both display fixed values and accept one operator entered value.</p>
<p>What are three panes that appear in the run time pl/sql interpreter?<br />
1. Source pane.<br />
2. interpreter pane.<br />
3. Navigator pane.</p>
<p>What are the two panes that Appear in the design time pl/sql interpreter?<br />
1. Source pane.<br />
2. Interpreter pane</p>
<p>What are the two ways by which data can be generated for a parameters list of values?<br />
1. Using static values.<br />
2. Writing select statement.</p>
<p>What are the various methods of performing a calculation in a report ?<br />
1. Perform the calculation in the SQL statements itself.<br />
2. Use a calculated / summary column in the data model.</p>
<p>What are the default extensions of the files created by menu module?<br />
.mmb,<br />
.mmx</p>
<p>What are the default extensions of the files created by forms modules?<br />
.fmb – form module binary<br />
.fmx – form module executable</p>
<p>To display the page no. for each page on a report what would be the source &amp; logical page no. or &amp; of physical page no.?<br />
&amp; physical page no.</p>
<p>It is possible to use raw devices as data files and what is the advantages over file. system files ?</p>
<p>Yes. The advantages over file system files. I/O will be improved because Oracle is bye-passing the kernnel which writing into disk. Disk Corruption will be very less.</p>
<p>What are disadvantages of having raw devices ?</p>
<p>We should depend on export/import utility for backup/recovery (fully reliable) The tar command cannot be used for physical file backup, instead we can use dd command which is less flexible and has limited recoveries.</p>
<p>What is the significance of having storage clause ?</p>
<p>We can plan the storage for a table as how much initial extents are required, how much can be extended next, how much % should leave free for managing row updations etc.,</p>
<p>What is the use of INCTYPE option in EXP command ?<br />
Type export should be performed COMPLETE,CUMULATIVE,INCREMENTAL. List the sequence of events when a large transaction that</p>
<p>exceeds beyond its optimal value when an entry wraps and causes the rollback segment toexpand into anotion Completes. e. will be written.</p>
<p>What is the use of FILE option in IMP command ?<br />
The name of the file from which import should be performed.</p>
<p>What is a Shared SQL pool?</p>
<p>The data dictionary cache is stored in an area in SGA called the Shared SQL Pool. This will allow sharing of parsed SQL statements among concurrent users.</p>
<p>What is hot backup and how it can be taken?<br />
Taking backup of archive log files when database is open. For this the ARCHIVELOG mode should be enabled. The following files</p>
<p>need to be backed up. All data files. All Archive log, redo log files. All control files.</p>
<p>List the Optional Flexible Architecture (OFA) of Oracle database? or How can we organize the tablespaces in Oracle database</p>
<p>to have maximum performance ?<br />
SYSTEM – Data dictionary tables.<br />
DATA – Standard operational tables.<br />
DATA2- Static tables used for standard operations<br />
INDEXES – Indexes for Standard operational tables.<br />
INDEXES1 – Indexes of static tables used for standard operations.<br />
TOOLS – Tools table.<br />
TOOLS1 – Indexes for tools table.<br />
RBS – Standard Operations Rollback Segments,<br />
RBS1,RBS2 – Additional/Special Rollback segments.<br />
TEMP – Temporary purpose tablespace<br />
TEMP_USER – Temporary tablespace for users.<br />
USERS – User tablespace.</p>
<p>How to implement the multiple control files for an existing database ?</p>
<p>Shutdown the database Copy one of the existing control file to new location Edit Config ora file by adding new control file.name Restart the database.</p>
<p>What is advantage of having disk shadowing/ Mirroring ?<br />
Shadow set of disks save as a backup in the event of disk failure. In most Operating System if any disk failure occurs it</p>
<p>automatically switchover to place of failed disk. Improved performance because most OS support volume shadowing can direct</p>
<p>file I/O request to use the shadow set of files instead of the main set of files. This reduces I/O load on the main set of</p>
<p>disks.</p>
<p>How will you force database to use particular rollback segment ?<br />
SET TRANSACTION USE ROLLBACK SEGMENT rbs_name.</p>
<p>Why query fails sometimes ?<br />
Rollback segment dynamically extent to handle larger transactions entry loads. A single transaction may wipeout all available</p>
<p>free space in the Rollback Segment Tablespace. This prevents other user using Rollback segments.</p>
<p>What is the use of RECORD LENGTH option in EXP command ?<br />
Record length in bytes.</p>
<p>How will you monitor rollback segment status ?<br />
Querying the DBA_ROLLBACK_SEGS view<br />
IN USE – Rollback Segment is on-line.<br />
AVAILABLE – Rollback Segment available but not on-line.<br />
OFF-LINE – Rollback Segment off-line<br />
INVALID – Rollback Segment Dropped.<br />
NEEDS RECOVERY – Contains data but need recovery or corupted.<br />
PARTLY AVAILABLE – Contains data from an unresolved transaction involving a distributed database.</p>
<p>What is meant by Redo Log file mirroring ? How it can be achieved?</p>
<p>Process of having a copy of redo log files is called mirroring. This can be achieved by creating group of log files together, so that LGWR will automatically writes them to all the members of the current on-line redo log group. If any one group fails then database automatically switch over to next group. It degrades performance.</p>
<p>Which parameter in Storage clause will reduce no. of rows per block?<br />
PCTFREE parameter<br />
Row size also reduces no of rows per block.</p>
<p>What is meant by recursive hints ?</p>
<p>Number of times processes repeatedly query the dictionary table is called recursive hints. It is due to the data dictionary cache is too small. By increasing the SHARED_POOL_SIZE parameter we can optimize the size of Data Dictionary Cache.</p>
<p>What is the use of PARFILE option in EXP command ?<br />
Name of the parameter file to be passed for export.</p>
<p>What is the difference between locks, latches, enqueues and semaphores? (for DBA)<br />
A latch is an internal Oracle mechanism used to protect data structures in the SGA from simultaneous access. Atomic hardware</p>
<p>instructions like TEST-AND-SET is used to implement latches. Latches are more restrictive than locks in that they are always</p>
<p>exclusive. Latches are never queued, but will spin or sleep until they obtain a resource, or time out.<br />
Enqueues and locks are different names for the same thing. Both support queuing and concurrency. They are queued and serviced</p>
<p>in a first-in-first-out (FIFO) order.<br />
Semaphores are an operating system facility used to control waiting. Semaphores are controlled by the following Unix</p>
<p>parameters: semmni, semmns and semmsl. Typical settings are:<br />
semmns = sum of the “processes” parameter for each instance<br />
(see init.ora for each instance)<br />
semmni = number of instances running simultaneously;<br />
semmsl = semmns</p>
<p>What is a logical backup?<br />
Logical backup involves reading a set of database records and writing them into a file. Export utility is used for taking</p>
<p>backup and Import utility is used to recover from backup.</p>
<p>What is a database EVENT and how does one set it? (for DBA)<br />
Oracle trace events are useful for debugging the Oracle database server. The following two examples are simply to demonstrate</p>
<p>syntax. Refer to later notes on this page for an explanation of what these particular events do.<br />
Either adding them to the INIT.ORA parameter file can activate events. E.g.<br />
event=’1401 trace name errorstack, level 12′<br />
… or, by issuing an ALTER SESSION SET EVENTS command: E.g.<br />
alter session set events ’10046 trace name context forever, level 4′;<br />
The alter session method only affects the user’s current session, whereas changes to the INIT.ORA file will affect all</p>
<p>sessions once the database has been restarted.</p>
<p>What is a Rollback segment entry ?<br />
It is the set of before image data blocks that contain rows that are modified by a transaction. Each Rollback Segment entry</p>
<p>must be completed within one rollback segment. A single rollback segment can have multiple rollback segment entries.</p>
<p>What database events can be set? (for DBA)<br />
The following events are frequently used by DBAs and Oracle Support to diagnose problems:<br />
” 10046 trace name context forever, level 4 Trace SQL statements and show bind variables in trace output.<br />
” 10046 trace name context forever, level 8 This shows wait events in the SQL trace files<br />
” 10046 trace name context forever, level 12 This shows both bind variable names and wait events in the SQL trace files<br />
” 1401 trace name errorstack, level 12 1401 trace name errorstack, level 4 1401 trace name processstate Dumps out trace</p>
<p>information if an ORA-1401 “inserted value too large for column” error occurs. The 1401 can be replaced by any other Oracle</p>
<p>Server error code that you want to trace.<br />
” 60 trace name errorstack level 10 Show where in the code Oracle gets a deadlock (ORA-60), and may help to diagnose the</p>
<p>problem.<br />
The following lists of events are examples only. They might be version specific, so please call Oracle before using them:<br />
” 10210 trace name context forever, level 10 10211 trace name context forever, level 10 10231 trace name context forever,</p>
<p>level 10 These events prevent database block corruptions<br />
” 10049 trace name context forever, level 2 Memory protect cursor<br />
” 10210 trace name context forever, level 2 Data block check<br />
” 10211 trace name context forever, level 2 Index block check<br />
” 10235 trace name context forever, level 1 Memory heap check<br />
” 10262 trace name context forever, level 300 Allow 300 bytes memory leak for connections<br />
Note: You can use the Unix oerr command to get the description of an event. On Unix, you can type “oerr ora 10053″ from the</p>
<p>command prompt to get event details.</p>
<p>How can one dump internal database structures? (for DBA)<br />
The following (mostly undocumented) commands can be used to obtain information about internal database structures.<br />
o Dump control file contents<br />
alter session set events ‘immediate trace name CONTROLF level 10′<br />
/<br />
o Dump file headers<br />
alter session set events ‘immediate trace name FILE_HDRS level 10′<br />
/<br />
o Dump redo log headers<br />
alter session set events ‘immediate trace name REDOHDR level 10′<br />
/<br />
o Dump the system state<br />
NOTE: Take 3 successive SYSTEMSTATE dumps, with 10-minute intervals alter session set events ‘immediate trace name</p>
<p>SYSTEMSTATE level 10′<br />
/<br />
o Dump the process state<br />
alter session set events ‘immediate trace name PROCESSSTATE level 10′<br />
/<br />
o Dump Library Cache details<br />
alter session set events ‘immediate trace name library cache level 10′<br />
/<br />
o Dump optimizer statistics whenever a SQL statement is parsed (hint: change statement or flush pool) alter session set</p>
<p>events ’10053 trace name context forever, level 1′<br />
/<br />
o Dump a database block (File/ Block must be converted to DBA address) Convert file and block number to a DBA (database block</p>
<p>address).<br />
Eg: variable x varchar2;<br />
exec <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_mad.gif' alt=':x' class='wp-smiley' />  := dbms_utility.make_data_block_address(1,12);<br />
print x<br />
alter session set events ‘immediate trace name blockdump level 50360894′<br />
/</p>
<p>What are the different kind of export backups?<br />
Full back – Complete database<br />
Incremental – Only affected tables from last incremental date/full backup date.<br />
Cumulative backup – Only affected table from the last cumulative date/full backup date.</p>
<p>How free extents are managed in Ver 6.0 and Ver 7.0 ?<br />
Free extents cannot be merged together in Ver 6.0.<br />
Free extents are periodically coalesces with the neighboring free extent in Ver 7.0</p>
<p>What is the use of RECORD option in EXP command?<br />
For Incremental exports, the flag indirects whether a record will be stores data dictionary tables recording the export.</p>
<p>What is the use of ROWS option in EXP command ?<br />
Flag to indicate whether table rows should be exported. If ‘N’ only DDL statements for the database objects will be created.</p>
<p>What is the use of COMPRESS option in EXP command ?<br />
Flag to indicate whether export should compress fragmented segments into single extents.</p>
<p>How will you swap objects into a different table space for an existing database ?<br />
Export the user<br />
Perform import using the command imp system/manager file=export.dmp indexfile=newrite.sql.<br />
This will create all definitions into newfile.sql. Drop necessary objects.<br />
Run the script newfile.sql after altering the tablespaces.<br />
Import from the backup for the necessary objects.</p>
<p>How does Space allocation table place within a block ?<br />
Each block contains entries as follows<br />
Fixed block header<br />
Variable block header<br />
Row Header,row date (multiple rows may exists)<br />
PCTEREE (% of free space for row updation in future)</p>
<p>What are the factors causing the reparsing of SQL statements in SGA?<br />
Due to insufficient Shared SQL pool size. Monitor the ratio of the reloads takes place while executing SQL statements. If the</p>
<p>ratio is greater than 1 then increase the SHARED_POOL_SIZE. LOGICAL &amp; PHYSICAL ARCHITECTURE OF DATABASE.</p>
<p>What is dictionary cache ?<br />
Dictionary cache is information about the databse objects stored in a data dictionary table.</p>
<p>What is a Control file ?<br />
Database overall physical architecture is maintained in a file called control file. It will be used to maintain internal</p>
<p>consistency and guide recovery operations. Multiple copies of control files are advisable.</p>
<p>What is Database Buffers ?</p>
<p>Database buffers are cache in the SGA used to hold the data blocks that are read from the data segments in the database such as tables, indexes and clusters DB_BLOCK_BUFFERS parameter in INIT.ORA decides the size.</p>
<p>How will you create multiple rollback segments in a database ?<br />
Create a database which implicitly creates a SYSTEM Rollback Segment in a SYSTEM tablespace. Create a Second Rollback Segment</p>
<p>name R0 in the SYSTEM tablespace. Make new rollback segment available (After shutdown, modify init.ora file and Start</p>
<p>database) Create other tablespaces (RBS) for rollback segments. Deactivate Rollback Segment R0 and activate the newly created</p>
<p>rollback segments.</p>
<p>What is cold backup? What are the elements of it?<br />
Cold backup is taking backup of all physical files after normal shutdown of database. We need to take.<br />
- All Data files.<br />
- All Control files.<br />
- All on-line redo log files.<br />
- The init.ora file (Optional)</p>
<p>What is meant by redo log buffer ?<br />
Changes made to entries are written to the on-line redo log files. So that they can be used in roll forward operations during</p>
<p>database recoveries. Before writing them into the redo log files, they will first brought to redo log buffers in SGA and LGWR</p>
<p>will write into files frequently. LOG_BUFFER parameter will decide the size.</p>
<p>How will you estimate the space required by a non-clustered tables?<br />
Calculate the total header size<br />
Calculate the available dataspace per data block<br />
Calculate the combined column lengths of the average row<br />
Calculate the total average row size.<br />
Calculate the average number rows that can fit in a block<br />
Calculate the number of blocks and bytes required for the table.<br />
After arriving the calculation, add 10 % additional space to calculate the initial extent size for a working table.</p>
<p>How will you monitor the space allocation ?<br />
By querying DBA_SEGMENT table/view.</p>
<p>What is meant by free extent ?<br />
A free extent is a collection of continuous free blocks in tablespace. When a segment is dropped its extents are reallocated</p>
<p>and are marked as free.</p>
<p>What is the use of IGNORE option in IMP command ?<br />
A flag to indicate whether the import should ignore errors encounter when issuing CREATE commands.</p>
<p>What is the use of ANALYSE ( Ver 7) option in EXP command ?<br />
A flag to indicate whether statistical information about the exported objects should be written to export dump file.</p>
<p>What is the use of ROWS option in IMP command ?<br />
A flag to indicate whether rows should be imported. If this is set to ‘N’ then only DDL for database objects will be</p>
<p>executed.</p>
<p>What is the use of INDEXES option in EXP command ?<br />
A flag to indicate whether indexes on tables will be exported.</p>
<p>What is the use of INDEXES option in IMP command ?<br />
A flag to indicate whether import should import index on tables or not.</p>
<p>What is the use of GRANT option in EXP command?<br />
A flag to indicate whether grants on databse objects will be exported or not. Value is ‘Y’ or ‘N’.</p>
<p>What is the use of GRANT option in IMP command ?<br />
A flag to indicate whether grants on database objects will be imported.</p>
<p>What is the use of FULL option in EXP command ?<br />
A flag to indicate whether full databse export should be performed.</p>
<p>What is the use of SHOW option in IMP command ?<br />
A flag to indicate whether file content should be displayed or not.</p>
<p>What is the use of CONSTRAINTS option in EXP command ?<br />
A flag to indicate whether constraints on table need to be exported.</p>
<p>What is the use of CONSISTENT (Ver 7) option in EXP command ?<br />
A flag to indicate whether a read consistent version of all the exported objects should be maintained.</p>
<p>What are the different methods of backing up oracle database ?<br />
- Logical Backups<br />
- Cold Backups<br />
- Hot Backups (Archive log)</p>
<p>What is the difference between ON-VALIDATE-FIELD trigger and a POST-CHANGE trigger ?<br />
When you changes the Existing value to null, the On-validate field trigger will fire post change trigger will not fire. At</p>
<p>the time of execute-query post-change trigger will fire, on-validate field trigger will not fire.</p>
<p>When is PRE-QUERY trigger executed ?<br />
When Execute-query or count-query Package procedures are invoked.</p>
<p>How do you trap the error in forms 3.0 ?<br />
using On-Message or On-Error triggers.</p>
<p>How many pages you can in a single form ?<br />
Unlimited</p>
<p>While specifying master/detail relationship between two blocks specifying the join condition is a must ?<br />
True or False. ?<br />
True</p>
<p>EXIT_FORM is a restricted package procedure ?<br />
a. True b. False<br />
True</p>
<p>What is the usage of an ON-INSERT,ON-DELETE and ON-UPDATE TRIGGERS ?<br />
These triggers are executes when inserting, deleting and updating operations are performed and can be used to change the</p>
<p>default function of insert, delete or update respectively. For Eg, instead of inserting a row in a table an existing row can</p>
<p>be updated in the same table.</p>
<p>What are the types of Pop-up window ?<br />
the pop-up field editor<br />
pop-up list of values<br />
pop-up pages.<br />
Alert :</p>
<p>What is an SQL *FORMS ?<br />
SQL *forms is 4GL tool for developing and executing; Oracle based interactive application.</p>
<p>How do you control the constraints in forms ?<br />
Select the use constraint property is ON Block definition screen.<br />
BLOCK</p>
<p>What is the difference between restricted and unrestricted package procedure ?<br />
Restricted package procedure that affects the basic functions of SQL * Forms. It cannot used in all triggers except key</p>
<p>triggers. Unrestricted package procedure that does not interfere with the basic functions of SQL * Forms it can be used in</p>
<p>any triggers.</p>
<p>A query fetched 10 records How many times does a PRE-QUERY Trigger and POST-QUERY Trigger will get executed ?<br />
PRE-QUERY fires once.<br />
POST-QUERY fires 10 times.</p>
<p>Give the sequence in which triggers fired during insert operations, when the following 3 triggers are defined at the same</p>
<p>block level ?<br />
a. ON-INSERT b. POST-INSERT c. PRE-INSERT</p>
<p>State the order in which these triggers are executed ?<br />
POST-FIELD,ON-VALIDATE-FIELD,POST-CHANGE and KEY-NEXTFLD. KEY-NEXTFLD,POST-CHANGE, ON-VALIDATE-FIELD, POST-FIELD. g.</p>
<p>What the PAUSE package procedure does ?<br />
Pause suspends processing until the operator presses a function key</p>
<p>What do you mean by a page ?<br />
Pages are collection of display information, such as constant text and graphics</p>
<p>What are the type of User Exits ?<br />
ORACLE Precompliers user exits<br />
OCI (ORACLE Call Interface)<br />
Non-ORACEL user exits.<br />
Page :</p>
<p>What is the difference between an ON-VALIDATE-FIELD trigger and a trigger ?<br />
On-validate-field trigger fires, when the field Validation status New or changed. Post-field-trigger whenever the control</p>
<p>leaving form the field, it will fire.</p>
<p>Can we use a restricted package procedure in ON-VALIDATE-FIELD Trigger ?<br />
No</p>
<p>Is a Key startup trigger fires as result of a operator pressing a key explicitly ?<br />
No</p>
<p>Can we use GO-BLOCK package in a pre-field trigger ?<br />
No</p>
<p>Can we create two blocks with the same name in form 3.0 ?<br />
No</p>
<p>What does an on-clear-block Trigger fire?<br />
It fires just before SQL * forms the current block.</p>
<p>Name the two files that are created when you generate the form give the filex extension ?<br />
INP (Source File)<br />
FRM (Executable File)</p>
<p>What package procedure used for invoke sql *plus from sql *forms ?<br />
Host (E.g. Host (sqlplus))</p>
<p>What is the significance of PAGE 0 in forms 3.0 ?<br />
Hide the fields for internal calculation.</p>
<p>What are the different types of key triggers ?<br />
Function Key<br />
Key-function<br />
Key-others<br />
Key-startup</p>
<p>What is the difference between a Function Key Trigger and Key Function Trigger ?<br />
Function key triggers are associated with individual SQL*FORMS function keys You can attach Key function triggers to 10 keys</p>
<p>or key sequences that normally do not perform any SQL * FORMS operations. These keys referred as key F0 through key F9.</p>
<p>Committed block sometimes refer to a BASE TABLE ?<br />
False</p>
<p>Error_Code is a package proecdure ?<br />
a. True b. false<br />
False</p>
<p>When is cost based optimization triggered? (for DBA)<br />
It’s important to have statistics on all tables for the CBO (Cost Based Optimizer) to work correctly. If one table involved</p>
<p>in a statement does not have statistics, Oracle has to revert to rule-based optimization for that statement. So you really</p>
<p>want for all tables to have statistics right away; it won’t help much to just have the larger tables analyzed.<br />
Generally, the CBO can change the execution plan when you:<br />
1. Change statistics of objects by doing an ANALYZE;<br />
2. Change some initialization parameters (for example: hash_join_enabled, sort_area_size, db_file_multiblock_read_count).</p>
<p>How can one optimize %XYZ% queries? (for DBA)<br />
It is possible to improve %XYZ% queries by forcing the optimizer to scan all the entries from the index instead of the table.</p>
<p>This can be done by specifying hints. If the index is physically smaller than the table (which is usually the case) it will</p>
<p>take less time to scan the entire index than to scan the entire table.</p>
<p>What Enter package procedure does ?<br />
Enter Validate-data in the current validation unit.</p>
<p>Where can one find I/O statistics per table? (for DBA)<br />
The UTLESTAT report shows I/O per tablespace but one cannot see what tables in the tablespace has the most I/O. The</p>
<p>$ORACLE_HOME/rdbms/admin/catio.sql script creates a sample_io procedure and table to gather the required information. After</p>
<p>executing the procedure, one can do a simple SELECT * FROM io_per_object; to extract the required information. For more</p>
<p>details, look at the header comments in the $ORACLE_HOME/rdbms/admin/catio.sql script.</p>
<p>My query was fine last week and now it is slow. Why? (for DBA)<br />
The likely cause of this is because the execution plan has changed. Generate a current explain plan of the offending query</p>
<p>and compare it to a previous one that was taken when the query was performing well. Usually the previous plan is not</p>
<p>available.<br />
Some factors that can cause a plan to change are:<br />
. Which tables are currently analyzed? Were they previously analyzed? (ie. Was the query using RBO and now CBO?)<br />
. Has OPTIMIZER_MODE been changed in INIT.ORA?<br />
. Has the DEGREE of parallelism been defined/changed on any table?<br />
. Have the tables been re-analyzed? Were the tables analyzed using estimate or compute? If estimate, what percentage was</p>
<p>used?<br />
. Have the statistics changed?<br />
. Has the INIT.ORA parameter DB_FILE_MULTIBLOCK_READ_COUNT been changed?<br />
. Has the INIT.ORA parameter SORT_AREA_SIZE been changed?<br />
. Have any other INIT.ORA parameters been changed?<br />
. What do you think the plan should be? Run the query with hints to see if this produces the required performance.</p>
<p>What is a view?</p>
<p>Why is Oracle not using the damn index? (for DBA)<br />
This problem normally only arises when the query plan is being generated by the Cost Based Optimizer. The usual cause is</p>
<p>because the CBO calculates that executing a Full Table Scan would be faster than accessing the table via the index.<br />
Fundamental things that can be checked are:<br />
. USER_TAB_COLUMNS.NUM_DISTINCT – This column defines the number of distinct values the column holds.<br />
. USER_TABLES.NUM_ROWS – If NUM_DISTINCT = NUM_ROWS then using an index would be preferable to doing a FULL TABLE SCAN. As</p>
<p>the NUM_DISTINCT decreases, the cost of using an index increase thereby is making the index less desirable.<br />
. USER_INDEXES.CLUSTERING_FACTOR – This defines how ordered the rows are in the index. If CLUSTERING_FACTOR approaches the</p>
<p>number of blocks in the table, the rows are ordered. If it approaches the number of rows in the table, the rows are randomly</p>
<p>ordered. In such a case, it is unlikely that index entries in the same leaf block will point to rows in the same data blocks.<br />
. Decrease the INIT.ORA parameter DB_FILE_MULTIBLOCK_READ_COUNT – A higher value will make the cost of a FULL TABLE SCAN</p>
<p>cheaper.<br />
. Remember that you MUST supply the leading column of an index, for the index to be used (unless you use a FAST FULL SCAN or</p>
<p>SKIP SCANNING).<br />
. There are many other factors that affect the cost, but sometimes the above can help to show why an index is not being used</p>
<p>by the CBO. If from checking the above you still feel that the query should be using an index, try specifying an index hint.</p>
<p>Obtain an explain plan of the query either using TKPROF with TIMED_STATISTICS, so that one can see the CPU utilization, or</p>
<p>with AUTOTRACE to see the statistics. Compare this to the explain plan when not using an index.</p>
<p>When should one rebuild an index? (for DBA)<br />
You can run the ‘ANALYZE INDEX VALIDATE STRUCTURE’ command on the affected indexes – each invocation of this command creates</p>
<p>a single row in the INDEX_STATS view. This row is overwritten by the next ANALYZE INDEX command, so copy the contents of the</p>
<p>view into a local table after each ANALYZE. The ‘badness’ of the index can then be judged by the ratio of ‘DEL_LF_ROWS’ to</p>
<p>‘LF_ROWS’.</p>
<p>What are the unrestricted procedures used to change the popup screen position during run time ?<br />
Anchor-view<br />
Resize -View<br />
Move-View.</p>
<p>What is a type?</p>
<p>What is an Alert ?<br />
An alert is window that appears in the middle of the screen overlaying a portion of the current display.</p>
<p>Deleting a page removes information about all the fields in that page ?<br />
a. True. b. False<br />
a. True.</p>
<p>Two popup pages can appear on the screen at a time ?Two popup pages can appear on the screen at a time ?<br />
a. True. b. False?<br />
a. True.</p>
<p>Classify the restricted and unrestricted procedure from the following.<br />
a. Call<br />
b. User-Exit<br />
c. Call-Query<br />
d. Up<br />
e. Execute-Query<br />
f. Message<br />
g. Exit-From<br />
h. Post<br />
i. Break?</p>
<p>a. Call – unrestricted<br />
b. User Exit – Unrestricted<br />
c. Call_query – Unrestricted<br />
d. Up – Restricted<br />
e. Execute Query – Restricted<br />
f. Message – Restricted<br />
g. Exit_form – Restricted<br />
h. Post – Restricted<br />
i. Break – Unrestricted.</p>
<p>What is an User Exits ?<br />
A user exit is a subroutine which are written in programming languages using pro*C pro *Cobol , etc., that link into the SQL</p>
<p>* forms executable.</p>
<p>What is a Trigger ?<br />
A piece of logic that is executed at or triggered by a SQL *forms event.</p>
<p>What is a Package Procedure ?<br />
A Package procedure is built in PL/SQL procedure.</p>
<p>What is the maximum size of a form ?<br />
255 character width and 255 characters Length.</p>
<p>What is the difference between system.current_field and system.cursor_field ?<br />
1. System.current_field gives name of the field.<br />
2. System.cursor_field gives name of the field with block name.</p>
<p>List the system variables related in Block and Field?<br />
1. System.block_status<br />
2. System.current_block<br />
3. System.current_field<br />
4. System.current_value<br />
5. System.cursor_block<br />
6. System.cursor_field<br />
7. System.field_status.</p>
<p>What are the different types of Package Procedure ?<br />
1. Restricted package procedure.<br />
2. Unrestricted package procedure.</p>
<p>What are the types of TRIGGERS ?<br />
1. Navigational Triggers.<br />
2. Transaction Triggers.</p>
<p>Identify package function from the following ?<br />
1. Error-Code<br />
2. Break<br />
3. Call<br />
4. Error-text<br />
5. Form-failure<br />
6. Form-fatal<br />
7. Execute-query<br />
8. Anchor View<br />
9. Message_code?</p>
<p>1. Error_Code<br />
2. Error_Text<br />
3. Form_Failure<br />
4. Form_Fatal<br />
5. Message_Code</p>
<p>Can you attach an lov to a field at run-time? if yes, give the build-in name.?<br />
Yes. Set_item_proprety</p>
<p>Is it possible to attach same library to more than one form?<br />
Yes</p>
<p>Can you attach an lov to a field at design time?<br />
Yes</p>
<p>List the windows event triggers available in Forms 4.0?<br />
When-window-activated,<br />
when-window-closed,<br />
when-window-deactivated,<br />
when-window-resized</p>
<p>What are the triggers associated with the image item?<br />
When-Image-activated(Fires when the operator double clicks on an image Items)<br />
When-image-pressed(fires when the operator selects or deselects the image item)</p>
<p>What is a visual attribute?<br />
Visual Attributes are the font, color and pattern characteristics of objects that operators see and intract with in our</p>
<p>application.</p>
<p>How many maximum number of radio buttons can you assign to a radio group?<br />
Unlimited no of radio buttons can be assigned to a radio group</p>
<p>How do you pass the parameters from one form to another form?<br />
To pass one or more parameters to a called form, the calling form must perform the following steps in a trigger or user named</p>
<p>routine execute the create_parameter_list built-in function to programmatically. Create a parameter list to execute the add</p>
<p>parameter built-in procedure to add one or more parameters list. Execute the call_form, New_form or run_product built_in</p>
<p>procedure and include the name or id of the parameter list to be passed to the called form.</p>
<p>What is a Layout Editor?<br />
The Layout Editor is a graphical design facility for creating and arranging items and boilerplate text and graphics objects</p>
<p>in your application’s interface.</p>
<p>List the Types of Items?<br />
Text item.<br />
Chart item.<br />
Check box.<br />
Display item.<br />
Image item.<br />
List item.<br />
Radio Group.<br />
User Area item.</p>
<p>List system variables available in forms 4.0, and not available in forms 3.0?<br />
System.cordination_operation<br />
System Date_threshold<br />
System.effective_Date<br />
System.event_window<br />
System.suppress_working</p>
<p>What are the display styles of an alert?<br />
Stop, Caution, note</p>
<p>What built-in is used for showing the alert during run-time?<br />
Show_alert.</p>
<p>What built-in is used for changing the properties of the window dynamically?<br />
Set_window_property<br />
Canvas-View</p>
<p>What are the different types of windows?<br />
Root window, secondary window.</p>
<p>What is a predefined exception available in forms 4.0?<br />
Raise form_trigger_failure</p>
<p>What is a radio Group?<br />
Radio groups display a fixed no of options that are mutually Exclusive. User can select one out of n number of options.</p>
<p>What are the different type of a record group?<br />
Query record group<br />
Static record group<br />
Non query record group</p>
<p>What are the menu items that oracle forms 4.0 supports?<br />
Plain, Check,Radio, Separator, Magic</p>
<p>Give the equivalent term in forms 4.0 for the following. Page, Page 0?<br />
Page – Canvas-View<br />
Page 0 – Canvas-view null.</p>
<p>What triggers are associated with the radio group?<br />
Only when-radio-changed trigger associated with radio group<br />
Visual Attributes.</p>
<p>What are the triggers associated with a check box?<br />
Only When-checkbox-activated Trigger associated with a Check box.</p>
<p>Can you attach an alert to a field?<br />
No</p>
<p>Can a root window be made modal?<br />
No</p>
<p>What is a list item?<br />
It is a list of text elements.</p>
<p>List some built-in routines used to manipulate images in image_item?<br />
Image_add<br />
Image_and<br />
Image_subtract<br />
Image_xor<br />
Image_zoom</p>
<p>Can you change the alert messages at run-time?<br />
If yes, give the name of the built-in to change the alert messages at run-time. Yes. Set_alert_property.</p>
<p>What is the built-in used to get and set lov properties during run-time?<br />
Get_lov_property<br />
Set_lov_property<br />
Record Group</p>
<p>What is the built-in routine used to count the no of rows in a group?<br />
Get_group _row_count<br />
System Variables</p>
<p>Give the Types of modules in a form?<br />
Form<br />
Menu<br />
Library</p>
<p>Write the Abbreviation for the following File Extension 1. FMB 2. MMB 3. PLL?<br />
FMB —– Form Module Binary.<br />
MMB —– Menu Module Binary.<br />
PLL —— PL/SQL Library Module Binary.</p>
<p>List the built-in routine for controlling window during run-time?<br />
Find_window,<br />
get_window_property,<br />
hide_window,<br />
move_window,<br />
resize_window,<br />
set_window_property,<br />
show_View</p>
<p>List the built-in routine for controlling window during run-time?<br />
Find_canvas<br />
Get-Canvas_property<br />
Get_view_property<br />
Hide_View<br />
Replace_content_view<br />
Scroll_view<br />
Set_canvas_property<br />
Set_view_property<br />
Show_view<br />
Alert</p>
<p>What is the built-in function used for finding the alert?<br />
Find_alert<br />
Editors</p>
<p>List the editors availables in forms 4.0?<br />
Default editor<br />
User_defined editors<br />
system editors.</p>
<p>What buil-in routines are used to display editor dynamically?<br />
Edit_text item<br />
show_editor<br />
LOV</p>
<p>What is an Lov?<br />
A list of values is a single or multi column selection list displayed in a pop-up window</p>
<p>What is a record Group?<br />
A record group is an internal oracle forms data structure that has a similar column/row frame work to a database table</p>
<p>Give built-in routine related to a record groups?<br />
Create_group (Function)<br />
Create_group_from_query(Function)<br />
Delete_group(Procedure)<br />
Add_group_column(Function)<br />
Add_group_row(Procedure)<br />
Delete_group_row(Procedure)<br />
Populate_group(Function)<br />
Populate_group_with_query(Function)<br />
Set_group_Char_cell(procedure)</p>
<p>List the built-in routines for the controlling canvas views during run-time?<br />
Find_canvas<br />
Get-Canvas_property<br />
Get_view_property<br />
Hide_View<br />
Replace_content_view<br />
Scroll_view<br />
Set_canvas_property<br />
Set_view_property<br />
Show_view<br />
Alert</p>
<p>System.effective_date system variable is read only True/False?<br />
False</p>
<p>What are the built_in used to trapping errors in forms 4?<br />
Error_type return character<br />
Error_code return number<br />
Error_text return char<br />
Dbms_error_code return no.<br />
Dbms_error_text return char</p>
<p>What is Oracle Financials? (for DBA)<br />
Oracle Financials products provide organizations with solutions to a wide range of long- and short-term accounting system</p>
<p>issues. Regardless of the size of the business, Oracle Financials can meet accounting management demands with:<br />
Oracle Assets: Ensures that an organization’s property and equipment investment is accurate and that the correct asset tax</p>
<p>accounting strategies are chosen.<br />
Oracle General Ledger: Offers a complete solution to journal entry, budgeting, allocations, consolidation, and financial</p>
<p>reporting needs.<br />
Oracle Inventory: Helps an organization make better inventory decisions by minimizing stock and maximizing cash flow.<br />
Oracle Order Entry: Provides organizations with a sophisticated order entry system for managing customer commitments.<br />
Oracle Payables: Lets an organization process more invoices with fewer staff members and tighter controls. Helps save money</p>
<p>through maximum discounts, bank float, and prevention of duplicate payment.<br />
Oracle Personnel: Improves the management of employee- related issues by retaining and making available every form of</p>
<p>personnel data.<br />
Oracle Purchasing: Improves buying power, helps negotiate bigger discounts, eliminates paper flow, increases financial</p>
<p>controls, and increases productivity.<br />
Oracle Receivables:. Improves cash flow by letting an organization process more payments faster, without off-line research.</p>
<p>Helps correctly account for cash, reduce outstanding receivables, and improve collection effectiveness.<br />
Oracle Revenue Accounting Gives an organization timely and accurate revenue and flexible commissions reporting.<br />
Oracle Sales Analysis: Allows for better forecasting, planning. and reporting of sales information.</p>
<p>What are the design facilities available in forms 4.0?<br />
Default Block facility.<br />
Layout Editor.<br />
Menu Editor.<br />
Object Lists.<br />
Property Sheets.<br />
PL/SQL Editor.<br />
Tables Columns Browser.<br />
Built-ins Browser.</p>
<p>What is the most important module in Oracle Financials? (for DBA)<br />
The General Ledger (GL) module is the basis for all other Oracle Financial modules. All other modules provide information to</p>
<p>it. If you implement Oracle Financials, you should switch your current GL system first.GL is relatively easy to implement.</p>
<p>You should go live with it first to give your implementation team a chance to be familiar with Oracle Financials.</p>
<p>What are the types of canvas-views?<br />
Content View, Stacked View.</p>
<p>%type and %rowtype are attributes for…?</p>
<p>What is the MultiOrg and what is it used for? (for DBA)<br />
MultiOrg or Multiple Organizations Architecture allows multiple operating units and their relationships to be defined within</p>
<p>a single installation of Oracle Applications. This keeps each operating unit’s transaction data separate and secure.<br />
Use the following query to determine if MuliOrg is intalled:<br />
select multi_org_flag from fnd_product_groups;</p>
<p>What is the difference between Fields and FlexFields? (for DBA)<br />
A field is a position on a form that one uses to enter, view, update, or delete information. A field prompt describes each</p>
<p>field by telling what kind of information appears in the field, or alternatively, what kind of information should be entered</p>
<p>in the field.<br />
A flexfield is an Oracle Applications field made up of segments. Each segment has an assigned name and a set of valid values.</p>
<p>Oracle Applications uses flexfields to capture information about your organization. There are two types of flexfields: key</p>
<p>flexfields and descriptive flexfields.</p>
<p>Explain types of Block in forms4.0?<br />
Base table Blocks.<br />
Control Blocks.<br />
1. A base table block is one that is associated with a specific database table or view.<br />
2. A control block is a block that is not associated with a database table. ITEMS</p>
<p>What is an Alert?<br />
An alert is a modal window that displays a message notifies the operator of some application condition</p>
<p>What are the built-in routines is available in forms 4.0 to create and manipulate a parameter list?<br />
Add_parameter<br />
Create_Parameter_list<br />
Delete_parameter<br />
Destroy_parameter_list<br />
Get_parameter_attr<br />
Get_parameter_list<br />
set_parameter_attr</p>
<p>What is a record Group?<br />
A record group is an internal oracle forms data structure that has a similar column/row frame work to a database table</p>
<p>What is a Navigable item?<br />
A navigable item is one that operators can navigate to with the keyboard during default navigation, or that Oracle forms can</p>
<p>navigate to by executing a navigational built-in procedure.</p>
<p>What is a library in Forms 4.0?<br />
A library is a collection of Pl/SQL program units, including user named procedures, functions &amp; packages</p>
<p>How image_items can be populate to field in forms 4.0?<br />
A fetch from a long raw database column PL/Sql assignment to executing the read_image_file built_in procedure to get an image</p>
<p>from the file system.</p>
<p>What is the content view and stacked view?<br />
A content view is the “Base” view that occupies the entire content pane of the window in which it is displayed. A stacked</p>
<p>view differs from a content canvas view in that it is not the base view for the window to which it is assigned</p>
<p>What is a Check Box?<br />
A Check Box is a two state control that indicates whether a certain condition or value is on or off, true or false. The</p>
<p>display state of a check box is always either “checked” or “unchecked”.</p>
<p>What is a canvas-view?<br />
A canvas-view is the background object on which you layout the interface items (text-items, check boxes, radio groups, and so</p>
<p>on.) and boilerplate objects that operators see and interact with as they run your form. At run-time, operators can see only</p>
<p>those items that have been assigned to a specific canvas. Each canvas, in term, must be displayed in a specific window.</p>
<p>Explain the following file extension related to library?<br />
.pll,.lib,.pld<br />
The library pll files is a portable design file comparable to an fmb form file<br />
The library lib file is a plat form specific, generated library file comparable to a fmx form file<br />
The pld file is Txt format file and can be used for source controlling your library files Parameter</p>
<p>Explain the usage of WHERE CURRENT OF clause in cursors ?<br />
WHERE CURRENT OF clause in an UPDATE,DELETE statement refers to the latest row fetched from a cursor. Database Triggers</p>
<p>Name the tables where characteristics of Package, procedure and functions are stored ?<br />
User_objects, User_Source and User_error.</p>
<p>Explain the two type of Cursors ?<br />
There are two types of cursors, Implicit Cursor and Explicit Cursor. PL/SQL uses Implicit Cursors for queries. User defined</p>
<p>cursors are called Explicit Cursors. They can be declared and used.</p>
<p>What are two parts of package ?<br />
The two parts of package are PACKAGE SPECIFICATION &amp; PACKAGE BODY. Package Specification contains declarations that are</p>
<p>global to the packages and local to the schema. Package Body contains actual procedures and local declaration of the</p>
<p>procedures and cursor declarations.</p>
<p>What are two virtual tables available during database trigger execution ?<br />
The table columns are referred as OLD.column_name and NEW.column_name.<br />
For triggers related to INSERT only NEW.column_name values only available.<br />
For triggers related to UPDATE only OLD.column_name NEW.column_name values only available.<br />
For triggers related to DELETE only OLD.column_name values only available.</p>
<p>What is Fine Grained Auditing? (for DBA)<br />
Fine Grained Auditing (DBMS_FGA) allows auditing records to be generated when certain rows are selected from a table. A list</p>
<p>of defined policies can be obtained from DBA_AUDIT_POLICIES. Audit records are stored in DBA_FGA_AUDIT_TRAIL. Look at this</p>
<p>example:<br />
o Add policy on table with autiting condition…<br />
execute dbms_fga.add_policy(‘HR’, ‘EMP’, ‘policy1′, ‘deptno &gt; 10′);<br />
o Must ANALYZE, this feature works with CBO (Cost Based Optimizer)<br />
analyze table EMP compute statistics;<br />
select * from EMP where c1 = 11; — Will trigger auditing<br />
select * from EMP where c1 = 09; — No auditing<br />
o Now we can see the statments that triggered the auditing condition…<br />
select sqltext from sys.fga_log$;<br />
delete from sys.fga_log$;</p>
<p>What is a package ? What are the advantages of packages ? What is Pragma EXECPTION_INIT ? Explain the usage ?<br />
The PRAGMA EXECPTION_INIT tells the complier to associate an exception with an oracle error. To get an error message of a</p>
<p>specific oracle error. e.g. PRAGMA EXCEPTION_INIT (exception name, oracle error number)</p>
<p>What is a Virtual Private Database? (for DBA)<br />
Oracle 8i introduced the notion of a Virtual Private Database (VPD). A VPD offers Fine-Grained Access Control (FGAC) for</p>
<p>secure separation of data. This ensures that users only have access to data that pertains to them. Using this option, one</p>
<p>could even store multiple companies’ data within the same schema, without them knowing about it. VPD configuration is done</p>
<p>via the DBMS_RLS (Row Level Security) package. Select from SYS.V$VPD_POLICY to see existing VPD configuration.</p>
<p>What is Raise_application_error ?<br />
Raise_application_error is a procedure of package DBMS_STANDARD which allows to issue an user_defined error messages from</p>
<p>stored sub-program or database trigger.</p>
<p>What is Oracle Label Security? (for DBA)<br />
Oracle Label Security (formerly called Trusted Oracle MLS RDBMS) uses the VPD (Virtual Private Database) feature of Oracle8i</p>
<p>to implement row level security. Access to rows are restricted according to a user’s security sensitivity tag or label.</p>
<p>Oracle Label Security is configured, controlled and managed from the Policy Manager, an Enterprise Manager-based GUI utility.</p>
<p>Give the structure of the procedure ?<br />
PROCEDURE name (parameter list…..)<br />
is<br />
local variable declarations<br />
BEGIN<br />
Executable statements.<br />
Exception.<br />
exception handlers<br />
end;</p>
<p>What is OEM (Oracle Enterprise Manager)? (for DBA)<br />
OEM is a set of systems management tools provided by Oracle Corporation for managing the Oracle environment. It provides</p>
<p>tools to monitor the Oracle environment and automate tasks (both one-time and repetitive in nature) to take database</p>
<p>administration a step closer to “Lights Out” management.</p>
<p>Question What is PL/SQL ?<br />
PL/SQL is a procedural language that has both interactive SQL and procedural programming language constructs such as</p>
<p>iteration, conditional branching.</p>
<p>What are the components of OEM? (for DBA)<br />
Oracle Enterprise Manager (OEM) has the following components:<br />
. Management Server (OMS): Middle tier server that handles communication with the intelligent agents. The OEM Console</p>
<p>connects to the management server to monitor and configure the Oracle enterprise.<br />
. Console: This is a graphical interface from where one can schedule jobs, events, and monitor the database. The console can</p>
<p>be opened from a Windows workstation, Unix XTerm (oemapp command) or Web browser session (oem_webstage).<br />
. Intelligent Agent (OIA): The OIA runs on the target database and takes care of the execution of jobs and events scheduled</p>
<p>through the Console.</p>
<p>What happens if a procedure that updates a column of table X is called in a database trigger of the same table ?<br />
Mutation of table occurs.</p>
<p>Is it possible to use Transaction control Statements such a ROLLBACK or COMMIT in Database Trigger ? Why ?<br />
It is not possible. As triggers are defined for each table, if you use COMMIT of ROLLBACK in a trigger, it affects logical</p>
<p>transaction processing.</p>
<p>How many types of database triggers can be specified on a table ? What are they ?<br />
Insert Update Delete<br />
Before Row o.k. o.k. o.k.<br />
After Row o.k. o.k. o.k.<br />
Before Statement o.k. o.k. o.k.<br />
After Statement o.k. o.k. o.k.<br />
If FOR EACH ROW clause is specified, then the trigger for each Row affected by the statement.<br />
If WHEN clause is specified, the trigger fires according to the returned Boolean value.</p>
<p>What are the modes of parameters that can be passed to a procedure ?<br />
IN,OUT,IN-OUT parameters.</p>
<p>Where the Pre_defined_exceptions are stored ?<br />
In the standard package.<br />
Procedures, Functions &amp; Packages ;</p>
<p>Write the order of precedence for validation of a column in a table ?<br />
I. done using Database triggers.<br />
ii. done using Integarity Constraints.?</p>
<p>I &amp; ii.</p>
<p>Give the structure of the function ?<br />
FUNCTION name (argument list …..) Return datatype is<br />
local variable declarations<br />
Begin<br />
executable statements<br />
Exception<br />
execution handlers<br />
End;</p>
<p>Explain how procedures and functions are called in a PL/SQL block ?<br />
Function is called as part of an expression.<br />
sal := calculate_sal (‘a822′);<br />
procedure is called as a PL/SQL statement<br />
calculate_bonus (‘A822′);</p>
<p>What are advantages fo Stored Procedures?<br />
Extensibility,Modularity, Reusability, Maintainability and one time compilation.</p>
<p>What is an Exception ? What are types of Exception ?<br />
Exception is the error handling part of PL/SQL block. The types are Predefined and user defined. Some of Predefined</p>
<p>exceptions are.<br />
CURSOR_ALREADY_OPEN<br />
DUP_VAL_ON_INDEX<br />
NO_DATA_FOUND<br />
TOO_MANY_ROWS<br />
INVALID_CURSOR<br />
INVALID_NUMBER<br />
LOGON_DENIED<br />
NOT_LOGGED_ON<br />
PROGRAM-ERROR<br />
STORAGE_ERROR<br />
TIMEOUT_ON_RESOURCE<br />
VALUE_ERROR<br />
ZERO_DIVIDE<br />
OTHERS.</p>
<p>What are the PL/SQL Statements used in cursor processing ?<br />
DECLARE CURSOR name, OPEN cursor name, FETCH cursor name INTO or Record types, CLOSE cursor name.</p>
<p>What are the components of a PL/SQL Block ?<br />
Declarative part, Executable part and Exception part.<br />
Datatypes PL/SQL</p>
<p>What is a database trigger ? Name some usages of database trigger ?<br />
Database trigger is stored PL/SQL program unit associated with a specific database table. Usages are Audit data</p>
<p>modifications, Log events transparently, Enforce complex business rules Derive column values automatically, Implement complex</p>
<p>security authorizations. Maintain replicate tables.</p>
<p>What is a cursor ? Why Cursor is required ?<br />
Cursor is a named private SQL area from where information can be accessed. Cursors are required to process rows individually</p>
<p>for queries returning multiple rows.</p>
<p>What is a cursor for loop ?<br />
Cursor for loop implicitly declares %ROWTYPE as loop index, opens a cursor, fetches rows of values from active set into</p>
<p>fields in the record and closes when all the records have been processed.<br />
e.g.. FOR emp_rec IN C1 LOOP<br />
salary_total := salary_total +emp_rec sal;<br />
END LOOP;</p>
<p>What will happen after commit statement ?<br />
Cursor C1 is<br />
Select empno,<br />
ename from emp;<br />
Begin<br />
open C1; loop<br />
Fetch C1 into<br />
eno.ename;<br />
Exit When<br />
C1 %notfound;—–<br />
commit;<br />
end loop;<br />
end;<br />
The cursor having query as SELECT …. FOR UPDATE gets closed after COMMIT/ROLLBACK.<br />
The cursor having query as SELECT…. does not get closed even after COMMIT/ROLLBACK.</p>
<p>How packaged procedures and functions are called from the following?<br />
a. Stored procedure or anonymous block<br />
b. an application program such a PRC *C, PRO* COBOL<br />
c. SQL *PLUS??</p>
<p>a. PACKAGE NAME.PROCEDURE NAME (parameters);<br />
variable := PACKAGE NAME.FUNCTION NAME (arguments);<br />
EXEC SQL EXECUTE<br />
b.BEGIN<br />
PACKAGE NAME.PROCEDURE NAME (parameters)<br />
variable := PACKAGE NAME.FUNCTION NAME (arguments);<br />
END;<br />
END EXEC;<br />
c. EXECUTE PACKAGE NAME.PROCEDURE if the procedures does not have any out/in-out parameters. A function can not be called.</p>
<p>What is a stored procedure ?<br />
A stored procedure is a sequence of statements that perform specific function.</p>
<p>What are the components of a PL/SQL block ?<br />
A set of related declarations and procedural statements is called block.</p>
<p>What is difference between a PROCEDURE &amp; FUNCTION ?<br />
A FUNCTION is always returns a value using the return statement.<br />
A PROCEDURE may return one or more values through parameters or may not return at all.</p>
<p>What is difference between a Cursor declared in a procedure and Cursor declared in a package specification ?<br />
A cursor declared in a package specification is global and can be accessed by other procedures or procedures in a package.<br />
A cursor declared in a procedure is local to the procedure that can not be accessed by other procedures.</p>
<p>What are the cursor attributes used in PL/SQL ?<br />
%ISOPEN – to check whether cursor is open or not<br />
% ROWCOUNT – number of rows fetched/updated/deleted.<br />
% FOUND – to check whether cursor has fetched any row. True if rows are fetched.<br />
% NOT FOUND – to check whether cursor has fetched any row. True if no rows are featched.<br />
These attributes are proceeded with SQL for Implicit Cursors and with Cursor name for Explicit Cursors.</p>
<p>What are % TYPE and % ROWTYPE ? What are the advantages of using these over datatypes?<br />
% TYPE provides the data type of a variable or a database column to that variable.<br />
% ROWTYPE provides the record type that represents a entire row of a table or view or columns selected in the cursor.<br />
The advantages are :<br />
I. Need not know about variable’s data type<br />
ii. If the database definition of a column in a table changes, the data type of a variable changes accordingly.</p>
<p>What is difference between % ROWTYPE and TYPE RECORD ?<br />
% ROWTYPE is to be used whenever query returns a entire row of a table or view.<br />
TYPE rec RECORD is to be used whenever query returns columns of different table or views and variables.<br />
E.g. TYPE r_emp is RECORD (eno emp.empno% type,ename emp ename %type );<br />
e_rec emp% ROWTYPE<br />
cursor c1 is select empno,deptno from emp;<br />
e_rec c1 %ROWTYPE.</p>
<p>What are the different types of PL/SQL program units that can be defined and stored in ORACLE database ?<br />
Procedures and Functions,Packages and Database Triggers.</p>
<p>What are the advantages of having a Package ?<br />
Increased functionality (for example,global package variables can be declared and used by any proecdure in the package) and</p>
<p>performance (for example all objects of the package are parsed compiled, and loaded into memory once)</p>
<p>What are the uses of Database Trigger ?<br />
Database triggers can be used to automatic data generation, audit data modifications, enforce complex Integrity constraints,</p>
<p>and customize complex security authorizations.</p>
<p>What is a Procedure ?<br />
A Procedure consist of a set of SQL and PL/SQL statements that are grouped together as a unit to solve a specific problem or</p>
<p>perform a set of related tasks.</p>
<p>What is a Package ?<br />
A Package is a collection of related procedures, functions, variables and other package constructs together as a unit in the</p>
<p>database.</p>
<p>What is difference between Procedures and Functions ?<br />
A Function returns a value to the caller where as a Procedure does not.</p>
<p>What is Database Trigger ?<br />
A Database Trigger is procedure (set of SQL and PL/SQL statements) that is automatically executed as a result of an insert</p>
<p>in, update to, or delete from a table.</p>
<p>Can the default values be assigned to actual parameters?<br />
Yes</p>
<p>Can a primary key contain more than one columns?<br />
Yes</p>
<p>What is an UTL_FILE.What are different procedures and functions associated with it?<br />
UTL_FILE is a package that adds the ability to read and write to operating system files. Procedures associated with it are</p>
<p>FCLOSE, FCLOSE_ALL and 5 procedures to output data to a file PUT, PUT_LINE, NEW_LINE, PUTF, FFLUSH.PUT,</p>
<p>FFLUSH.PUT_LINE,FFLUSH.NEW_LINE. Functions associated with it are FOPEN, ISOPEN.</p>
<p>What are ORACLE PRECOMPILERS?<br />
Using ORACLE PRECOMPILERS, SQL statements and PL/SQL blocks can be contained inside 3GL programs written in</p>
<p>C,C++,COBOL,PASCAL, FORTRAN,PL/1 AND ADA. The Precompilers are known as Pro*C,Pro*Cobol,… This form of PL/SQL is known as</p>
<p>embedded pl/sql,the language in which pl/sql is embedded is known as the host language. The prcompiler translates the</p>
<p>embedded SQL and pl/sql statements into calls to the precompiler runtime library. The output must be compiled and linked with</p>
<p>this library to creator an executable.</p>
<p>Differentiate between TRUNCATE and DELETE?<br />
TRUNCATE deletes much faster than DELETE<br />
TRUNCATE<br />
DELETE<br />
It is a DDL statement<br />
It is a DML statement<br />
It is a one way trip, cannot ROLLBACK<br />
One can Rollback<br />
Doesn’t have selective features (where clause)<br />
Has<br />
Doesn’t fire database triggers<br />
Does<br />
It requires disabling of referential constraints.</p>
<p>What is difference between a formal and an actual parameter?<br />
The variables declared in the procedure and which are passed, as arguments are called actual, the parameters in the procedure</p>
<p>declaration. Actual parameters contain the values that are passed to a procedure and receive results. Formal parameters are</p>
<p>the placeholders for the values of actual parameters</p>
<p>What should be the return type for a cursor variable. Can we use a scalar data type as return type?<br />
The return type for a cursor must be a record type.It can be declared explicitly as a user-defined or %ROWTYPE can be used.</p>
<p>eg TYPE t_studentsref IS REF CURSOR RETURN students%ROWTYPE</p>
<p>What are different Oracle database objects?<br />
-TABLES<br />
-VIEWS<br />
-INDEXES<br />
-SYNONYMS<br />
-SEQUENCES<br />
-TABLESPACES etc</p>
<p>What is difference between SUBSTR and INSTR?<br />
SUBSTR returns a specified portion of a string eg SUBSTR(‘BCDEF’,4) output BCDE INSTR provides character position in which a</p>
<p>pattern is found in a string. eg INSTR(‘ABC-DC-F’,&#8217;-’,2) output 7 (2nd occurence of ‘-’)</p>
<p>Display the number value in Words?<br />
SQL&gt; select sal, (to_char(to_date(sal,’j&#8217;), ‘jsp’))<br />
from emp;<br />
the output like,<br />
SAL (TO_CHAR(TO_DATE(SAL,’J&#8217;),’JSP’))<br />
——— —————————————-<br />
800 eight hundred<br />
1600 one thousand six hundred<br />
1250 one thousand two hundred fifty<br />
If you want to add some text like, Rs. Three Thousand only.<br />
SQL&gt; select sal “Salary “,<br />
(‘ Rs. ‘|| (to_char(to_date(sal,’j&#8217;), ‘Jsp’))|| ‘ only.’))<br />
“Sal in Words” from emp<br />
/<br />
Salary Sal in Words<br />
——- ———————————————–<br />
800 Rs. Eight Hundred only.<br />
1600 Rs. One Thousand Six Hundred only.<br />
1250 Rs. One Thousand Two Hundred Fifty only.</p>
<p>What is difference between SQL and SQL*PLUS?<br />
SQL*PLUS is a command line tool where as SQL and PL/SQL language interface and reporting tool. Its a command line tool that</p>
<p>allows user to type SQL commands to be executed directly against an Oracle database. SQL is a language used to query the</p>
<p>relational database(DML,DCL,DDL). SQL*PLUS commands are used to format query result, Set options, Edit SQL commands and</p>
<p>PL/SQL.</p>
<p>What are various joins used while writing SUBQUERIES?<br />
Self join-Its a join foreign key of a table references the same table. Outer Join–Its a join condition used where One can</p>
<p>query all the rows of one of the tables in the join condition even though they don’t satisfy the join condition.<br />
Equi-join–Its a join condition that retrieves rows from one or more tables in which one or more columns in one table are</p>
<p>equal to one or more columns in the second table.</p>
<p>What a SELECT FOR UPDATE cursor represent.?<br />
SELECT……FROM……FOR……UPDATE[OF column-reference][NOWAIT]<br />
The processing done in a fetch loop modifies the rows that have been retrieved by the cursor. A convenient way of modifying</p>
<p>the rows is done by a method with two parts: the FOR UPDATE clause in the cursor declaration, WHERE CURRENT OF CLAUSE in an</p>
<p>UPDATE or declaration statement.</p>
<p>What are various privileges that a user can grant to another user?<br />
-SELECT<br />
-CONNECT<br />
-RESOURCES</p>
<p>Display the records between two range?<br />
select rownum, empno, ename from emp where rowid in (select rowid from emp where rownum &lt;=&amp;upto minus select rowid from emp</p>
<p>where rownum&lt;&amp;Start);</p>
<p>minvalue.sql Select the Nth lowest value from a table?<br />
select level, min(‘col_name’) from my_table where level = ‘&amp;n’ connect by prior (‘col_name’) &lt; ‘col_name’)<br />
group by level;<br />
Example:<br />
Given a table called emp with the following columns:<br />
– id number<br />
– name varchar2(20)<br />
– sal number<br />
–<br />
– For the second lowest salary:<br />
– select level, min(sal) from emp<br />
– where level=2<br />
– connect by prior sal &lt; sal<br />
– group by level</p>
<p>What is difference between Rename and Alias?<br />
Rename is a permanent name given to a table or column whereas Alias is a temporary name given to a table or column which do</p>
<p>not exist once the SQL statement is executed.</p>
<p>Difference between an implicit &amp; an explicit cursor.?<br />
only one row. However,queries that return more than one row you must declare an explicit cursor or use a cursor FOR loop.</p>
<p>Explicit cursor is a cursor in which the cursor name is explicitly assigned to a SELECT statement via the CURSOR…IS</p>
<p>statement. An implicit cursor is used for all SQL statements Declare, Open, Fetch, Close. An explicit cursors are used to</p>
<p>process multirow SELECT statements An implicit cursor is used to process INSERT, UPDATE, DELETE and single row SELECT. .INTO</p>
<p>statements.</p>
<p>What is a OUTER JOIN?<br />
Outer Join–Its a join condition used where you can query all the rows of one of the tables in the join condition even though</p>
<p>they don’t satisfy the join condition.</p>
<p>What is a cursor?<br />
Oracle uses work area to execute SQL statements and store processing information PL/SQL construct called a cursor lets you</p>
<p>name a work area and access its stored information A cursor is a mechanism used to fetch more than one row in a Pl/SQl block.</p>
<p>What is the purpose of a cluster?<br />
Oracle does not allow a user to specifically locate tables, since that is a part of the function of the RDBMS. However, for</p>
<p>the purpose of increasing performance, oracle allows a developer to create a CLUSTER. A CLUSTER provides a means for storing</p>
<p>data from different tables together for faster retrieval than if the table placement were left to the RDBMS.</p>
<p>What is OCI. What are its uses?<br />
Oracle Call Interface is a method of accesing database from a 3GL program. Uses–No precompiler is required,PL/SQL blocks are</p>
<p>executed like other DML statements.<br />
The OCI library provides<br />
–functions to parse SQL statemets<br />
–bind input variables<br />
–bind output variables<br />
–execute statements<br />
–fetch the results</p>
<p>How you open and close a cursor variable. Why it is required?<br />
OPEN cursor variable FOR SELECT…Statement<br />
CLOSE cursor variable In order to associate a cursor variable with a particular SELECT statement OPEN syntax is used. In</p>
<p>order to free the resources used for the query CLOSE statement is used.</p>
<p>Display Odd/ Even number of records?<br />
Odd number of records:<br />
select * from emp where (rowid,1) in (select rowid, mod(rownum,2) from emp);<br />
Output:-<br />
1<br />
3<br />
5<br />
Even number of records:<br />
select * from emp where (rowid,0) in (select rowid, mod(rownum,2) from emp)<br />
Output:-<br />
2<br />
4<br />
6</p>
<p>What are various constraints used in SQL?<br />
-NULL<br />
-NOT NULL<br />
-CHECK<br />
-DEFAULT</p>
<p>Can cursor variables be stored in PL/SQL tables. If yes how. If not why?<br />
No, a cursor variable points a row which cannot be stored in a two-dimensional PL/SQL table.</p>
<p>Difference between NO DATA FOUND and %NOTFOUND?<br />
NO DATA FOUND is an exception raised only for the SELECT….INTO statements when the where clause of the querydoes not match</p>
<p>any rows. When the where clause of the explicit cursor does not match any rows the %NOTFOUND attribute is set to TRUE</p>
<p>instead.</p>
<p>Can you use a commit statement within a database trigger?<br />
No</p>
<p>What WHERE CURRENT OF clause does in a cursor?<br />
LOOP<br />
SELECT num_credits INTO v_numcredits FROM classes<br />
WHERE dept=123 and course=101;<br />
UPDATE students<br />
FHKO;;;;;;;;;SET current_credits=current_credits+v_numcredits<br />
WHERE CURRENT OF X;</p>
<p>There is a string 120000 12 0 .125 , how you will find the position of the decimal place?<br />
INSTR(’120000 12 0 .125′,1,’.&#8217;)<br />
output 13</p>
<p>What are different modes of parameters used in functions and procedures?<br />
-IN -OUT -INOUT</p>
<p>How you were passing cursor variables in PL/SQL 2.2?<br />
In PL/SQL 2.2 cursor variables cannot be declared in a package.This is because the storage for a cursor variable has to be</p>
<p>allocated using Pro*C or OCI with version 2.2, the only means of passing a cursor variable to a PL/SQL block is via bind</p>
<p>variable or a procedure parameter.</p>
<p>When do you use WHERE clause and when do you use HAVING clause?<br />
HAVING clause is used when you want to specify a condition for a group function and it is written after GROUP BY clause. The</p>
<p>WHERE clause is used when you want to specify a condition for columns, single row functions except group functions and it is</p>
<p>written before GROUP BY clause if it is used.</p>
<p>Difference between procedure and function.?<br />
Functions are named PL/SQL blocks that return a value and can be called with arguments procedure a named block that can be</p>
<p>called with parameter. A procedure all is a PL/SQL statement by itself, while a Function call is called as part of an</p>
<p>expression.</p>
<p>Which is more faster – IN or EXISTS?<br />
EXISTS is more faster than IN because EXISTS returns a Boolean value whereas IN returns a value.</p>
<p>What is syntax for dropping a procedure and a function .Are these operations possible?<br />
Drop Procedure procedure_name<br />
Drop Function function_name</p>
<p>How will you delete duplicating rows from a base table?<br />
delete from table_name where rowid not in (select max(rowid) from table group by duplicate_values_field_name); or delete</p>
<p>duplicate_values_field_name dv from table_name ta where rowid &lt;(select min(rowid) from table_name tb where ta.dv=tb.dv);</p>
<p>Difference between database triggers and form triggers?<br />
-Data base trigger(DBT) fires when a DML operation is performed on a data base table. Form trigger(FT) Fires when user</p>
<p>presses a key or navigates between fields on the screen<br />
-Can be row level or statement level No distinction between row level and statement level.<br />
-Can manipulate data stored in Oracle tables via SQL Can manipulate data in Oracle tables as well as variables in forms.<br />
-Can be fired from any session executing the triggering DML statements. Can be fired only from the form that define the</p>
<p>trigger.<br />
-Can cause other database triggers to fire. Can cause other database triggers to fire, but not other form triggers.</p>
<p>What is a cursor for loop?<br />
Cursor For Loop is a loop where oracle implicitly declares a loop variable, the loop index that of the same record type as</p>
<p>the cursor’s record.</p>
<p>How you will avoid duplicating records in a query?<br />
By using DISTINCT</p>
<p>What is a view ?<br />
A view is stored procedure based on one or more tables, it’s a virtual table.</p>
<p>What is difference between UNIQUE and PRIMARY KEY constraints?<br />
A table can have only one PRIMARY KEY whereas there can be any number of UNIQUE keys. The columns that compose PK are</p>
<p>automatically define NOT NULL, whereas a column that compose a UNIQUE is not automatically defined to be mandatory must also</p>
<p>specify the column is NOT NULL.</p>
<p>What is use of a cursor variable? How it is defined?<br />
A cursor variable is associated with different statements at run time, which can hold different values at run time. Static</p>
<p>cursors can only be associated with one run time query. A cursor variable is reference type (like a pointer in C).<br />
Declaring a cursor variable:<br />
TYPE type_name IS REF CURSOR RETURN return_type type_name is the name of the reference type,return_type is a record type</p>
<p>indicating the types of the select list that will eventually be returned by the cursor variable.</p>
<p>How do you find the numbert of rows in a Table ?<br />
A bad answer is count them (SELECT COUNT(*) FROM table_name)<br />
A good answer is :-<br />
‘By generating SQL to ANALYZE TABLE table_name COUNT STATISTICS by querying Oracle System Catalogues (e.g. USER_TABLES or</p>
<p>ALL_TABLES).<br />
The best answer is to refer to the utility which Oracle released which makes it unnecessary to do ANALYZE TABLE for each</p>
<p>Table individually.</p>
<p>What is the maximum buffer size that can be specified using the DBMS_OUTPUT.ENABLE function?<br />
1,000,00</p>
<p>What are cursor attributes?<br />
-%ROWCOUNT<br />
-%NOTFOUND<br />
-%FOUND<br />
-%ISOPEN</p>
<p>There is a % sign in one field of a column. What will be the query to find it?<br />
” Should be used before ‘%’.</p>
<p>What is ON DELETE CASCADE ?<br />
When ON DELETE CASCADE is specified ORACLE maintains referential integrity by automatically removing dependent foreign key</p>
<p>values if a referenced primary or unique key value is removed.</p>
<p>What is the fastest way of accessing a row in a table ?<br />
Using ROWID.CONSTRAINTS</p>
<p>What is difference between TRUNCATE &amp; DELETE ?<br />
TRUNCATE commits after deleting entire table i.e., can not be rolled back. Database triggers do not fire on TRUNCATEDELETE</p>
<p>allows the filtered deletion. Deleted records can be rolled back or committed. Database triggers fire on DELETE.</p>
<p>What is a transaction ?<br />
Transaction is logical unit between two commits and commit and rollback.</p>
<p>What are the advantages of VIEW ?<br />
To protect some of the columns of a table from other users.To hide complexity of a query.To hide complexity of calculations.</p>
<p>How will you a activate/deactivate integrity constraints ?<br />
The integrity constraints can be enabled or disabled by ALTER TABLE ENABLE constraint/DISABLE constraint.</p>
<p>Where the integrity constraints are stored in Data Dictionary ?<br />
The integrity constraints are stored in USER_CONSTRAINTS.</p>
<p>What is the Subquery ?<br />
Sub query is a query whose return values are used in filtering conditions of the main query.</p>
<p>How to access the current value and next value from a sequence ? Is it possible to access the current value in a session</p>
<p>before accessing next value ?<br />
Sequence name CURRVAL, Sequence name NEXTVAL.It is not possible. Only if you access next value in the session, current value</p>
<p>can be accessed.</p>
<p>What are the usage of SAVEPOINTS ?value in a session before accessing next value ?<br />
SAVEPOINTS are used to subdivide a transaction into smaller parts. It enables rolling back part of a transaction. Maximum of</p>
<p>five save points are allowed.</p>
<p>What is ROWID ?in a session before accessing next value ?<br />
ROWID is a pseudo column attached to each row of a table. It is 18 character long, blockno, rownumber are the components of</p>
<p>ROWID.</p>
<p>Explain Connect by Prior ?in a session before accessing next value ?<br />
Retrieves rows in hierarchical order.e.g. select empno, ename from emp where.</p>
<p>How many LONG columns are allowed in a table ? Is it possible to use LONG columns in WHERE clause or ORDER BY ?<br />
Only one LONG columns is allowed. It is not possible to use LONG column in WHERE or ORDER BY clause.</p>
<p>What is Referential Integrity ?<br />
Maintaining data integrity through a set of rules that restrict the values of one or more columns of the tables based on the</p>
<p>values of primary key or unique key of the referenced table.</p>
<p>What is a join ? Explain the different types of joins ?<br />
Join is a query which retrieves related columns or rows from multiple tables.Self Join – Joining the table with itself.Equi</p>
<p>Join – Joining two tables by equating two common columns.Non-Equi Join – Joining two tables by equating two common</p>
<p>columns.Outer Join – Joining two tables in such a way that query can also retrieve rows that do not have corresponding join</p>
<p>value in the other table.</p>
<p>If an unique key constraint on DATE column is created, will it validate the rows that are inserted with SYSDATE ?<br />
It won’t, Because SYSDATE format contains time attached with it.</p>
<p>How does one stop and start the OMS? (for DBA)<br />
Use the following command sequence to stop and start the OMS (Oracle Management Server):<br />
oemctl start oms<br />
oemctl status oms sysman/oem_temp<br />
oemctl stop oms sysman/oem_temp<br />
Windows NT/2000 users can just stop and start the required services. The default OEM administrator is “sysman” with a</p>
<p>password of “oem_temp”.<br />
NOTE: Use command oemctrl instead of oemctl for Oracle 8i and below.</p>
<p>What is an Integrity Constraint ?<br />
Integrity constraint is a rule that restricts values to a column in a table.</p>
<p>How does one create a repository? (for DBA)<br />
For OEM v2 and above, start the Oracle Enterprise Manager Configuration Assistant (emca on Unix) to create and configure the</p>
<p>management server and repository. Remember to setup a backup for the repository database after creating it.</p>
<p>If a View on a single base table is manipulated will the changes be reflected on the base table ?<br />
If changes are made to the tables which are base tables of a view will the changes be reference on the view.</p>
<p>The following describes means to create a OEM V1.x (very old!!!) repository on WindowsNT:</p>
<p>. Create a tablespace that would hold the repository data. A size between 200- 250 MB would be ideal. Let us call it</p>
<p>Dummy_Space.<br />
. Create an Oracle user who would own this repository. Assign DBA, SNMPAgent, Exp_Full_database, Imp_Full_database roles to</p>
<p>this user. Lets call this user Dummy_user. Assign Dummy_Space as the default tablespace.<br />
. Create an operating system user with the same name as the Oracle username. I.e. Dummy_User. Add ‘Log on as a batch job’</p>
<p>under advanced rights in User manager.<br />
. Fire up Enterprise manager and log in as Dummy_User and enter the password. This would trigger the creation of the</p>
<p>repository. From now on, Enterprise manager is ready to accept jobs.</p>
<p>What is a database link ?<br />
Database Link is a named path through which a remote database can be accessed.</p>
<p>How does one list one’s databases in the OEM Console? (for DBA)<br />
Follow these steps to discover databases and other services from the OEM Console:<br />
1. Ensure the GLOBAL_DBNAME parameter is set for all databases in your LISTENER.ORA file (optional). These names will be</p>
<p>listed in the OEM Console. Please note that names entered are case sensitive. A portion of a listener.ora file:<br />
(SID_DESC =<br />
(GLOBAL_DBNAME = DB_name_for_OEM)<br />
(SID_NAME = …<br />
2. Start the Oracle Intelligent Agent on the machine you want to discover. See section “How does one start the Oracle</p>
<p>Intelligent Agent?”.<br />
3. Start the OEM Console, navigate to menu “Navigator/ Discover Nodes”. The OEM Discovery Wizard will guide you through the</p>
<p>process of discovering your databases and other services.</p>
<p>What is CYCLE/NO CYCLE in a Sequence ?<br />
CYCLE specifies that the sequence continues to generate values after reaching either maximum or minimum value. After pan</p>
<p>ascending sequence reaches its maximum value, it generates its minimum value. After a descending sequence reaches its</p>
<p>minimum, it generates its maximum.NO CYCLE specifies that the sequence cannot generate more values after reaching its maximum</p>
<p>or minimum value.</p>
<p>What is correlated sub-query ?<br />
Correlated sub query is a sub query which has reference to the main query.</p>
<p>What are the data types allowed in a table ?<br />
CHAR,VARCHAR2,NUMBER,DATE,RAW,LONG and LONG RAW.</p>
<p>What is difference between CHAR and VARCHAR2 ? What is the maximum SIZE allowed for each type ?<br />
CHAR pads blank spaces to the maximum length. VARCHAR2 does not pad blank spaces. For CHAR it is 255 and 2000 for VARCHAR2.</p>
<p>Can a view be updated/inserted/deleted? If Yes under what conditions ?<br />
A View can be updated/deleted/inserted if it has only one base table if the view is based on columns from one or more tables</p>
<p>then insert, update and delete is not possible.</p>
<p>What are the different types of Coordinations of the Master with the Detail block?<br />
POPULATE_GROUP(function)<br />
POPULATE_GROUP_WITH_QUERY(function)<br />
SET_GROUP_CHAR_CELL(procedure)<br />
SET_GROUPCELL(procedure)<br />
SET_GROUP_NUMBER_CELL(procedure)</p>
<p>Use the ADD_GROUP_COLUMN function to add a column to a record group that was created at design time?<br />
I) TRUE II) FALSE<br />
II) FALSE</p>
<p>Use the ADD_GROUP_ROW procedure to add a row to a static record group?<br />
I) TRUE II) FALSE<br />
I) FALSE</p>
<p>maxvalue.sql Select the Nth Highest value from a table?<br />
select level, max(‘col_name’) from my_table where level = ‘&amp;n’ connect by prior (‘col_name’) &gt; ‘col_name’)<br />
group by level;<br />
Example:<br />
Given a table called emp with the following columns:<br />
– id number<br />
– name varchar2(20)<br />
– sal number<br />
–<br />
– For the second highest salary:<br />
– select level, max(sal) from emp<br />
– where level=2<br />
– connect by prior sal &gt; sal<br />
– group by level</p>
<p>Find out nth highest salary from emp table?<br />
SELECT DISTINCT (a.sal) FROM EMP A WHERE &amp;N = (SELECT COUNT (DISTINCT (b.sal)) FROM EMP B WHERE a.sal&lt;=b.sal);<br />
For E.g.:-<br />
Enter value for n: 2<br />
SAL<br />
———<br />
3700</p>
<p>Suppose a customer table is having different columns like customer no, payments.What will be the query to select top three</p>
<p>max payments?<br />
SELECT customer_no, payments from customer C1<br />
WHERE 3&lt;=(SELECT COUNT(*) from customer C2<br />
WHERE C1.payment &lt;= C2.payment)</p>
<p>How you will avoid your query from using indexes?<br />
SELECT * FROM emp<br />
Where emp_no+’ ‘=12345;<br />
i.e you have to concatenate the column name with space within codes in the where condition.<br />
SELECT /*+ FULL(a) */ ename, emp_no from emp<br />
where emp_no=1234;<br />
i.e using HINTS</p>
<p>What utility is used to create a physical backup?<br />
Either rman or alter tablespace begin backup will do..</p>
<p>What are the Back ground processes in Oracle and what are they.<br />
This is one of the most frequently asked question.There are basically 9 Processes but in a general system we need to mention</p>
<p>the first five background processes.They do the house keeping activities for the Oracle and are common in any system.<br />
The various background processes in oracle are<br />
a) Data Base Writer(DBWR) :: Data Base Writer Writes Modified blocks from Database buffer cache to Data Files.This is</p>
<p>required since the data is not written whenever a transaction is committed.<br />
b)LogWriter(LGWR) :: LogWriter writes the redo log entries to disk. Redo Log data is generated in redo log buffer of SGA. As</p>
<p>transaction commits and log buffer fills, LGWR writes log entries into a online redo log file.<br />
c) System Monitor(SMON) :: The System Monitor performs instance recovery at instance startup. This is useful for recovery</p>
<p>from system failure<br />
d)Process Monitor(PMON) :: The Process Monitor performs process recovery when user Process fails. Pmon Clears and Frees</p>
<p>resources that process was using.<br />
e) CheckPoint(CKPT) :: At Specified times, all modified database buffers in SGA are written to data files by DBWR at</p>
<p>Checkpoints and Updating all data files and control files of database to indicate the most recent checkpoint<br />
f)Archieves(ARCH) :: The Archiver copies online redo log files to archival storal when they are busy.<br />
g) Recoveror(RECO) :: The Recoveror is used to resolve the distributed transaction in network<br />
h) Dispatcher (Dnnn) :: The Dispatcher is useful in Multi Threaded Architecture<br />
i) Lckn :: We can have upto 10 lock processes for inter instance locking in parallel sql.</p>
<p>How many types of Sql Statements are there in Oracle<br />
There are basically 6 types of sql statments.They are<br />
a) Data Definition Language(DDL) :: The DDL statements define and maintain objects and drop objects.<br />
b) Data Manipulation Language(DML) :: The DML statements manipulate database data.<br />
c) Transaction Control Statements :: Manage change by DML<br />
d) Session Control :: Used to control the properties of current session enabling and disabling roles and changing .e.g. ::</p>
<p>Alter Statements, Set Role<br />
e) System Control Statements :: Change Properties of Oracle Instance .e.g.:: Alter System<br />
f) Embedded Sql :: Incorporate DDL, DML and T.C.S in Programming Language.e.g:: Using the Sql Statements in languages such as</p>
<p>‘C’, Open, Fetch, execute and close</p>
<p>What is a Transaction in Oracle<br />
A transaction is a Logical unit of work that compromises one or more SQL Statements executed by a single User. According to</p>
<p>ANSI, a transaction begins with first executable statement and ends when it is explicitly committed or rolled back.</p>
<p>Key Words Used in Oracle<br />
The Key words that are used in Oracle are ::<br />
a) Committing :: A transaction is said to be committed when the transaction makes permanent changes resulting from the SQL</p>
<p>statements.<br />
b) Rollback :: A transaction that retracts any of the changes resulting from SQL statements in Transaction.<br />
c) SavePoint :: For long transactions that contain many SQL statements, intermediate markers or savepoints are declared.</p>
<p>Savepoints can be used to divide a transaction into smaller points.<br />
d) Rolling Forward :: Process of applying redo log during recovery is called rolling forward.<br />
e) Cursor :: A cursor is a handle ( name or a pointer) for the memory associated with a specific stamen. A cursor is</p>
<p>basically an area allocated by Oracle for executing the Sql Statement. Oracle uses an implicit cursor statement for Single</p>
<p>row query and Uses Explicit cursor for a multi row query.<br />
f) System Global Area(SGA) :: The SGA is a shared memory region allocated by the Oracle that contains Data and control</p>
<p>information for one Oracle Instance. It consists of Database Buffer Cache and Redo log Buffer.<br />
g) Program Global Area (PGA) :: The PGA is a memory buffer that contains data and control information for server process.<br />
g) Database Buffer Cache :: Database Buffer of SGA stores the most recently used blocks of database data. The set of database</p>
<p>buffers in an instance is called Database Buffer Cache.<br />
h) Redo log Buffer :: Redo log Buffer of SGA stores all the redo log entries.<br />
i) Redo Log Files :: Redo log files are set of files that protect altered database data in memory that has not been written</p>
<p>to Data Files. They are basically used for backup when a database crashes.<br />
j) Process :: A Process is a ‘thread of control’ or mechanism in Operating System that executes series of steps.</p>
<p>What are Procedure, functions and Packages ?<br />
Procedures and functions consist of set of PL/SQL statements that are grouped together as a unit to solve a specific problem</p>
<p>or perform set of related tasks.<br />
Procedures do not Return values while Functions return one One Value Packages :: Packages Provide a method of encapsulating</p>
<p>and storing related procedures, functions, variables and other Package Contents</p>
<p>What are Database Triggers and Stored Procedures<br />
Database Triggers :: Database Triggers are Procedures that are automatically executed as a result of insert in, update to, or</p>
<p>delete from table.<br />
Database triggers have the values old and new to denote the old value in the table before it is deleted and the new indicated</p>
<p>the new value that will be used. DT are useful for implementing complex business rules which cannot be enforced using the</p>
<p>integrity rules.We can have the trigger as Before trigger or After Trigger and at Statement or Row level. e.g:: operations</p>
<p>insert,update ,delete 3 before ,after 3*2 A total of 6 combinatons<br />
At statment level(once for the trigger) or row level( for every execution ) 6 * 2 A total of 12. Thus a total of 12</p>
<p>combinations are there and the restriction of usage of 12 triggers has been lifted from Oracle 7.3 Onwards.<br />
Stored Procedures :: Stored Procedures are Procedures that are stored in Compiled form in the database.The advantage of using</p>
<p>the stored procedures is that many users can use the same procedure in compiled and ready to use format.</p>
<p>How many Integrity Rules are there and what are they<br />
There are Three Integrity Rules. They are as follows ::<br />
a) Entity Integrity Rule :: The Entity Integrity Rule enforces that the Primary key cannot be Null<br />
b) Foreign Key Integrity Rule :: The FKIR denotes that the relationship between the foreign key and the primary key has to be</p>
<p>enforced.When there is data in Child Tables the Master tables cannot be deleted.<br />
c) Business Integrity Rules :: The Third Intigrity rule is about the complex business processes which cannot be implemented</p>
<p>by the above 2 rules.</p>
<p>What are the Various Master and Detail Relation ships.<br />
The various Master and Detail Relationship are<br />
a) NonIsolated :: The Master cannot be deleted when a child is exisiting<br />
b) Isolated :: The Master can be deleted when the child is exisiting<br />
c) Cascading :: The child gets deleted when the Master is deleted.</p>
<p>What are the Various Block Coordination Properties<br />
The various Block Coordination Properties are<br />
a) Immediate Default Setting. The Detail records are shown when the Master Record are shown.<br />
b) Deffered with Auto Query Oracle Forms defer fetching the detail records until the operator navigates to the detail block.<br />
c) Deffered with No Auto Query The operator must navigate to the detail block and explicitly execute a query</p>
<p>What are the Different Optimization Techniques<br />
The Various Optimisation techniques are<br />
a) Execute Plan :: we can see the plan of the query and change it accordingly based on the indexes<br />
b) Optimizer_hint ::<br />
set_item_property(‘DeptBlock’,OPTIMIZER_HINT,’FIRST_ROWS’);<br />
Select /*+ First_Rows */ Deptno,Dname,Loc,Rowid from dept<br />
where (Deptno &gt; 25)<br />
c) Optimize_Sql ::<br />
By setting the Optimize_Sql = No, Oracle Forms assigns a single cursor for all SQL statements.This slow downs the processing</p>
<p>because for evertime the SQL must be parsed whenver they are executed.<br />
f45run module = my_firstform userid = scott/tiger optimize_sql = No<br />
d) Optimize_Tp ::<br />
By setting the Optimize_Tp= No, Oracle Forms assigns seperate cursor only for each query SELECT statement. All other SQL</p>
<p>statements reuse the cursor.<br />
f45run module = my_firstform userid = scott/tiger optimize_Tp = No</p>
<p>How does one change an Oracle user’s password?(for DBA)<br />
Issue the following SQL command:<br />
ALTER USER IDENTIFIED BY ;<br />
From Oracle8 you can just type “password” from SQL*Plus, or if you need to change another user’s password, type “password</p>
<p>user_name”. Look at this example:<br />
SQL&gt; password<br />
Changing password for SCOTT<br />
Old password:<br />
New password:<br />
Retype new password:</p>
<p>How does one create and drop database users?<br />
Look at these examples:<br />
CREATE USER scott<br />
IDENTIFIED BY tiger — Assign password<br />
DEFAULT TABLESACE tools — Assign space for table and index segments<br />
TEMPORARY TABLESPACE temp; — Assign sort space<br />
DROP USER scott CASCADE; — Remove user<br />
After creating a new user, assign the required privileges:<br />
GRANT CONNECT, RESOURCE TO scott;<br />
GRANT DBA TO scott; — Make user a DB Administrator<br />
Remember to give the user some space quota on its tablespaces:<br />
ALTER USER scott QUOTA UNLIMITED ON tools;</p>
<p>Who created all these users in my database?/ Can I drop this user? (for DBA)<br />
Oracle creates a number of default database users or schemas when a new database is created. Below are a few of them:<br />
SYS/CHANGE_ON_INSTALL or INTERNAL<br />
Oracle Data Dictionary/ Catalog<br />
Created by: ?/rdbms/admin/sql.bsq and various cat*.sql scripts<br />
Can password be changed: Yes (Do so right after the database was created)<br />
Can user be dropped: NO<br />
SYSTEM/MANAGER<br />
The default DBA user name (please do not use SYS)<br />
Created by: ?/rdbms/admin/sql.bsq<br />
Can password be changed: Yes (Do so right after the database was created)<br />
Can user be dropped: NO<br />
OUTLN/OUTLN<br />
Stored outlines for optimizer plan stability<br />
Created by: ?/rdbms/admin/sql.bsq<br />
Can password be changed: Yes (Do so right after the database was created)<br />
Can user be dropped: NO<br />
SCOTT/TIGER, ADAMS/WOOD, JONES/STEEL, CLARK/CLOTH and BLAKE/PAPER.<br />
Training/ demonstration users containing the popular EMP and DEPT tables<br />
Created by: ?/rdbms/admin/utlsampl.sql<br />
Can password be changed: Yes<br />
Can user be dropped: YES – Drop users cascade from all production environments<br />
HR/HR (Human Resources), OE/OE (Order Entry), SH/SH (Sales History).<br />
Training/ demonstration users containing the popular EMPLOYEES and DEPARTMENTS tables<br />
Created by: ?/demo/schema/mksample.sql<br />
Can password be changed: Yes<br />
Can user be dropped: YES – Drop users cascade from all production environments<br />
CTXSYS/CTXSYS<br />
Oracle interMedia (ConText Cartridge) administrator user<br />
Created by: ?/ctx/admin/dr0csys.sql<br />
TRACESVR/TRACE<br />
Oracle Trace server<br />
Created by: ?/rdbms/admin/otrcsvr.sql<br />
DBSNMP/DBSNMP<br />
Oracle Intelligent agent<br />
Created by: ?/rdbms/admin/catsnmp.sql, called from catalog.sql<br />
Can password be changed: Yes – put the new password in snmp_rw.ora file<br />
Can user be dropped: YES – Only if you do not use the Intelligent Agents<br />
ORDPLUGINS/ORDPLUGINS<br />
Object Relational Data (ORD) User used by Time Series, etc.<br />
Created by: ?/ord/admin/ordinst.sql<br />
ORDSYS/ORDSYS<br />
Object Relational Data (ORD) User used by Time Series, etc<br />
Created by: ?/ord/admin/ordinst.sql<br />
DSSYS/DSSYS<br />
Oracle Dynamic Services and Syndication Server<br />
Created by: ?/ds/sql/dssys_init.sql<br />
MDSYS/MDSYS<br />
Oracle Spatial administrator user<br />
Created by: ?/ord/admin/ordinst.sql<br />
AURORA$ORB$UNAUTHENTICATED/INVALID<br />
Used for users who do not authenticate in Aurora/ORB<br />
Created by: ?/javavm/install/init_orb.sql called from ?/javavm/install/initjvm.sql<br />
PERFSTAT/PERFSTAT<br />
Oracle Statistics Package (STATSPACK) that supersedes UTLBSTAT/UTLESTAT<br />
Created by: ?/rdbms/admin/statscre.sql<br />
Remember to change the passwords for the SYS and SYSTEM users immediately after installation!<br />
Except for the user SYS, there should be no problem altering these users to use a different default and temporary tablespace.</p>
<p>How does one enforce strict password control? (for DBA)<br />
By default Oracle’s security is not extremely good. For example, Oracle will allow users to choose single character passwords</p>
<p>and passwords that match their names and userids. Also, passwords don’t ever expire. This means that one can hack an account</p>
<p>for years without ever locking the user.<br />
From Oracle8 one can manage passwords through profiles. Some of the things that one can restrict:<br />
. FAILED_LOGIN_ATTEMPTS – failed login attempts before the account is locked<br />
. PASSWORD_LIFE_TIME – limits the number of days the same password can be used for authentication<br />
. PASSWORD_REUSE_TIME – number of days before a password can be reused<br />
. PASSWORD_REUSE_MAX – number of password changes required before the current password can be reused<br />
. PASSWORD_LOCK_TIME – number of days an account will be locked after maximum failed login attempts<br />
. PASSWORD_GRACE_TIME – number of days after the grace period begins during which a warning is issued and login is allowed<br />
. PASSWORD_VERIFY_FUNCTION – password complexity verification script<br />
Look at this simple example:<br />
CREATE PROFILE my_profile LIMIT<br />
PASSWORD_LIFE_TIME 30;<br />
ALTER USER scott PROFILE my_profile;</p>
<p>How does one switch to another user in Oracle? (for DBA)<br />
Users normally use the “connect” statement to connect from one database user to another. However, DBAs can switch from one</p>
<p>user to another without a password. Of course it is not advisable to bridge Oracle’s security, but look at this example: SQL&gt;</p>
<p>select password from dba_users where username=’SCOTT’;<br />
PASSWORD<br />
F894844C34402B67<br />
SQL&gt; alter user scott identified by lion;<br />
User altered.</p>
<p>SQL&gt; connect scott/lion<br />
Connected.</p>
<p>REM Do whatever you like…<br />
SQL&gt; connect system/manager<br />
Connected.</p>
<p>SQL&gt; alter user scott identified by values ‘F894844C34402B67′;<br />
User altered.<br />
SQL&gt; connect scott/tiger<br />
Connected.<br />
Note: Also see the su.sql script in the Useful Scripts and Sample Programs Page.</p>
<p>What are snap shots and views<br />
Snapshots are mirror or replicas of tables. Views are built using the columns from one or more tables. The Single Table View</p>
<p>can be updated but the view with multi table cannot be updated</p>
<p>What are the OOPS concepts in Oracle.<br />
Oracle does implement the OOPS concepts. The best example is the Property Classes. We can categorize the properties by</p>
<p>setting the visual attributes and then attach the property classes for the objects. OOPS supports the concepts of objects and</p>
<p>classes and we can consider the property classes as classes and the items as objects</p>
<p>What is the difference between candidate key, unique key and primary key<br />
Candidate keys are the columns in the table that could be the primary keys and the primary key is the key that has been</p>
<p>selected to identify the rows. Unique key is also useful for identifying the distinct rows in the table.)</p>
<p>What is concurrency<br />
Concurrency is allowing simultaneous access of same data by different users. Locks useful for accesing the database are<br />
a) Exclusive<br />
The exclusive lock is useful for locking the row when an insert,update or delete is being done.This lock should not be</p>
<p>applied when we do only select from the row.<br />
b) Share lock<br />
We can do the table as Share_Lock as many share_locks can be put on the same resource.</p>
<p>Previleges and Grants<br />
Previleges are the right to execute a particulare type of SQL statements. e.g :: Right to Connect, Right to create, Right to</p>
<p>resource Grants are given to the objects so that the object might be accessed accordingly.The grant has to be given by the</p>
<p>owner of the object</p>
<p>Table Space,Data Files,Parameter File, Control Files<br />
Table Space :: The table space is useful for storing the data in the database.When a database is created two table spaces are</p>
<p>created.<br />
a) System Table space :: This data file stores all the tables related to the system and dba tables<br />
b) User Table space :: This data file stores all the user related tables<br />
We should have seperate table spaces for storing the tables and indexes so that the access is fast.<br />
Data Files :: Every Oracle Data Base has one or more physical data files.They store the data for the database.Every datafile</p>
<p>is associated with only one database.Once the Data file is created the size cannot change.To increase the size of the</p>
<p>database to store more data we have to add data file.<br />
Parameter Files :: Parameter file is needed to start an instance.A parameter file contains the list of instance configuration</p>
<p>parameters e.g.::<br />
db_block_buffers = 500<br />
db_name = ORA7<br />
db_domain = u.s.acme lang<br />
Control Files :: Control files record the physical structure of the data files and redo log files<br />
They contain the Db name, name and location of dbs, data files ,redo log files and time stamp.</p>
<p>Physical Storage of the Data<br />
The finest level of granularity of the data base are the data blocks.<br />
Data Block :: One Data Block correspond to specific number of physical database space<br />
Extent :: Extent is the number of specific number of contigious data blocks.<br />
Segments :: Set of Extents allocated for Extents. There are three types of Segments<br />
a) Data Segment :: Non Clustered Table has data segment data of every table is stored in cluster data segment<br />
b) Index Segment :: Each Index has index segment that stores data<br />
c) Roll Back Segment :: Temporarily store ‘undo’ information</p>
<p>What are the Pct Free and Pct Used<br />
Pct Free is used to denote the percentage of the free space that is to be left when creating a table. Similarly Pct Used is</p>
<p>used to denote the percentage of the used space that is to be used when creating a table<br />
eg.:: Pctfree 20, Pctused 40</p>
<p>What is Row Chaining<br />
The data of a row in a table may not be able to fit the same data block.Data for row is stored in a chain of data blocks .</p>
<p>What is a 2 Phase Commit<br />
Two Phase commit is used in distributed data base systems. This is useful to maintain the integrity of the database so that</p>
<p>all the users see the same values. It contains DML statements or Remote Procedural calls that reference a remote object.</p>
<p>There are basically 2 phases in a 2 phase commit.<br />
a) Prepare Phase :: Global coordinator asks participants to prepare<br />
b) Commit Phase :: Commit all participants to coordinator to Prepared, Read only or abort Reply</p>
<p>What is the difference between deleting and truncating of tables<br />
Deleting a table will not remove the rows from the table but entry is there in the database dictionary and it can be</p>
<p>retrieved But truncating a table deletes it completely and it cannot be retrieved.</p>
<p>What are mutating tables<br />
When a table is in state of transition it is said to be mutating. eg :: If a row has been deleted then the table is said to</p>
<p>be mutating and no operations can be done on the table except select.</p>
<p>What are Codd Rules<br />
Codd Rules describe the ideal nature of a RDBMS. No RDBMS satisfies all the 12 codd rules and Oracle Satisfies 11 of the 12</p>
<p>rules and is the only Rdbms to satisfy the maximum number of rules.</p>
<p>What is Normalisation<br />
Normalisation is the process of organising the tables to remove the redundancy.There are mainly 5 Normalisation rules.<br />
a) 1 Normal Form :: A table is said to be in 1st Normal Form when the attributes are atomic<br />
b) 2 Normal Form :: A table is said to be in 2nd Normal Form when all the candidate keys are dependant on the primary key<br />
c) 3rd Normal Form :: A table is said to be third Normal form when it is not dependant transitively</p>
<p>What is the Difference between a post query and a pre query<br />
A post query will fire for every row that is fetched but the pre query will fire only once.</p>
<p>Deleting the Duplicate rows in the table<br />
We can delete the duplicate rows in the table by using the Rowid</p>
<p>Can U disable database trigger? How?<br />
Yes. With respect to table<br />
ALTER TABLE TABLE<br />
[[ DISABLE all_trigger ]]</p>
<p>What is pseudo columns ? Name them?<br />
A pseudocolumn behaves like a table column, but is not actually stored in the table. You can select from pseudocolumns, but</p>
<p>you cannot insert, update, or delete their values. This section describes these pseudocolumns:<br />
* CURRVAL<br />
* NEXTVAL<br />
* LEVEL<br />
* ROWID<br />
* ROWNUM</p>
<p>How many columns can table have?<br />
The number of columns in a table can range from 1 to 254.</p>
<p>Is space acquired in blocks or extents ?<br />
In extents .</p>
<p>What is clustered index?<br />
In an indexed cluster, rows are stored together based on their cluster key values . Can not applied for HASH.</p>
<p>What are the datatypes supported By oracle (INTERNAL)?<br />
Varchar2, Number,Char , MLSLABEL.</p>
<p>What are attributes of cursor?<br />
%FOUND , %NOTFOUND , %ISOPEN,%ROWCOUNT</p>
<p>Can you use select in FROM clause of SQL select ?<br />
Yes.</p>
<p>Which trigger are created when master -detail relay?<br />
master delete property<br />
* NON-ISOLATED (default)<br />
a) on check delete master<br />
b) on clear details<br />
c) on populate details<br />
* ISOLATED<br />
a) on clear details<br />
b) on populate details<br />
* CASCADE<br />
a) per-delete<br />
b) on clear details<br />
c) on populate details</p>
<p>which system variables can be set by users?<br />
SYSTEM.MESSAGE_LEVEL<br />
SYSTEM.DATE_THRESHOLD<br />
SYSTEM.EFFECTIVE_DATE<br />
SYSTEM.SUPPRESS_WORKING</p>
<p>What are object group?<br />
An object group is a container for a group of objects. You define an object group when you want to package related objects so</p>
<p>you can copy or reference them in another module.</p>
<p>What are referenced objects?<br />
Referencing allows you to create objects that inherit their functionality and appearance from other objects. Referencing an</p>
<p>object is similar to copying an object, except that the resulting reference object maintains a link to its source object. A</p>
<p>reference object automatically inherits any changes that have been made to the source object when you open or regenerate the</p>
<p>module that contains the reference object.</p>
<p>Can you store objects in library?<br />
Referencing allows you to create objects that inherit their functionality and appearance from other objects. Referencing an</p>
<p>object is similar to copying an object, except that the resulting reference object maintains a link to its source object. A</p>
<p>reference object automatically inherits any changes that have been made to the source object when you open or regenerate the</p>
<p>module that contains the reference object.</p>
<p>Is forms 4.5 object oriented tool ? why?<br />
yes , partially. 1) PROPERTY CLASS – inheritance property 2) OVERLOADING : procedures and functions.</p>
<p>Can you issue DDL in forms?<br />
yes, but you have to use FORMS_DDL.<br />
Referencing allows you to create objects that inherit their functionality and appearance from other objects. Referencing an</p>
<p>object is similar to copying an object, except that the resulting reference object maintains a link to its source object. A</p>
<p>reference object automatically inherits any changes that have been made to the source object when you open or regenerate the</p>
<p>module that contains the reference object. Any string expression up to 32K:<br />
- a literal<br />
- an expression or a variable representing the text of a block of dynamically created PL/SQL code<br />
- a DML statement or<br />
- a DDL statement<br />
Restrictions:<br />
The statement you pass to FORMS_DDL may not contain bind variable references in the string, but the values of bind variables</p>
<p>can be concatenated into the string before passing the result to FORMS_DDL.</p>
<p>What is SECURE property?<br />
- Hides characters that the operator types into the text item. This setting is typically used for password protection.</p>
<p>What are the types of triggers and how the sequence of firing in text item<br />
Triggers can be classified as Key Triggers, Mouse Triggers ,Navigational Triggers.<br />
Key Triggers :: Key Triggers are fired as a result of Key action.e.g :: Key-next-field, Key-up,Key-Down<br />
Mouse Triggers :: Mouse Triggers are fired as a result of the mouse navigation.e.g.</p>
<p>When-mouse-button-presed,when-mouse-doubleclicked,etc<br />
Navigational Triggers :: These Triggers are fired as a result of Navigation. E.g. : Post-Text-item,Pre-text-item.<br />
We also have event triggers like when ?new-form-instance and when-new-block-instance.<br />
We cannot call restricted procedures like go_to(?my_block.first_item?) in the Navigational triggers<br />
But can use them in the Key-next-item.<br />
The Difference between Key-next and Post-Text is an very important question. The key-next is fired as a result of the key</p>
<p>action while the post text is fired as a result of the mouse movement. Key next will not fire unless there is a key event.</p>
<p>The sequence of firing in a text item are as follows ::<br />
a) pre – text<br />
b) when new item<br />
c) key-next<br />
d) when validate<br />
e) post text</p>
<p>Can you store pictures in database? How?<br />
Yes , in long Raw datatype.</p>
<p>What are property classes ? Can property classes have trigger?<br />
Property class inheritance is a powerful feature that allows you to quickly define objects that conform to your own interface</p>
<p>and functionality standards. Property classes also allow you to make global changes to applications quickly. By simply</p>
<p>changing the definition of a property class, you can change the definition of all objects that inherit properties from that</p>
<p>class.<br />
Yes . All type of triggers .</p>
<p>If you have property class attached to an item and you have same trigger written for the item . Which will fire first?<br />
Item level trigger fires , If item level trigger fires, property level trigger won’t fire. Triggers at the lowest level are</p>
<p>always given the first preference. The item level trigger fires first and then the block and then the Form level trigger.</p>
<p>What are record groups ? * Can record groups created at run-time?<br />
A record group is an internal Oracle Forms data structure that has a column/row framework similar to a database table.</p>
<p>However, unlike database tables, record groups are separate objects that belong to the form module in which they are defined.</p>
<p>A record group can have an unlimited number of columns of type CHAR, LONG, NUMBER, or DATE provided that the total number of</p>
<p>columns does not exceed 64K. Record group column names cannot exceed 30 characters.<br />
Programmatically, record groups can be used whenever the functionality offered by a two-dimensional array of multiple data</p>
<p>types is desirable.<br />
TYPES OF RECORD GROUP:<br />
Query Record Group A query record group is a record group that has an associated SELECT statement. The columns in a query</p>
<p>record group derive their default names, data types, and lengths from the database columns referenced in the SELECT</p>
<p>statement. The records in a query record group are the rows retrieved by the query associated with that record group.<br />
Non-query Record Group A non-query record group is a group that does not have an associated query, but whose structure and</p>
<p>values can be modified programmatically at runtime.<br />
Static Record Group A static record group is not associated with a query; rather, you define its structure and row values at</p>
<p>design time, and they remain fixed at runtime.</p>
<p>What are ALERT?<br />
An ALERT is a modal window that displays a message notifying operator of some application condition.</p>
<p>Can a button have icon and label at the same time ?<br />
-NO</p>
<p>What is mouse navigate property of button?<br />
When Mouse Navigate is True (the default), Oracle Forms performs standard navigation to move the focus to the item when the</p>
<p>operator activates the item with the mouse.<br />
When Mouse Navigate is set to False, Oracle Forms does not perform navigation (and the resulting validation) to move to the</p>
<p>item when an operator activates the item with the mouse.</p>
<p>What is FORMS_MDI_WINDOW?<br />
forms run inside the MDI application window. This property is useful for calling a form from another one.</p>
<p>What are timers ? when when-timer-expired does not fire?<br />
The When-Timer-Expired trigger can not fire during trigger, navigation, or transaction processing.</p>
<p>Can object group have a block?<br />
Yes , object group can have block as well as program units.</p>
<p>How many types of canvases are there.<br />
There are 2 types of canvases called as Content and Stack Canvas. Content canvas is the default and the one that is used</p>
<p>mostly for giving the base effect. Its like a plate on which we add items and stacked canvas is used for giving 3 dimensional</p>
<p>effect.</p>
<p>What are user-exits?<br />
It invokes 3GL programs.</p>
<p>Can you pass values to-and-fro from foreign function ? how ?<br />
Yes . You obtain a return value from a foreign function by assigning the return value to an Oracle Forms variable or item.</p>
<p>Make sure that the Oracle Forms variable or item is the same data type as the return value from the foreign function.<br />
After assigning an Oracle Forms variable or item value to a PL/SQL variable, pass the PL/SQL variable as a parameter value in</p>
<p>the PL/SQL interface of the foreign function. The PL/SQL variable that is passed as a parameter must be a valid PL/SQL data</p>
<p>type; it must also be the appropriate parameter type as defined in the PL/SQL interface.</p>
<p>What is IAPXTB structure ?<br />
The entries of Pro * C and user exits and the form which simulate the proc or user_exit are stored in IAPXTB table in d/b.</p>
<p>Can you call WIN-SDK thru user exits?<br />
YES.</p>
<p>Does user exits supports DLL on MSWINDOWS ?<br />
YES .</p>
<p>What is path setting for DLL?<br />
Make sure you include the name of the DLL in the FORMS45_USEREXIT variable of the ORACLE.INI file, or rename the DLL to</p>
<p>F45XTB.DLL. If you rename the DLL to F45XTB.DLL, replace the existing F45XTB.DLL in the ORAWINBIN directory with the new</p>
<p>F45XTB.DLL.</p>
<p>How is mapping of name of DLL and function done?<br />
The dll can be created using the Visual C++ / Visual Basic Tools and then the dll is put in the path that is defined the</p>
<p>registry.</p>
<p>What is precompiler?<br />
It is similar to C precompiler directives.</p>
<p>Can you connect to non – oracle datasource ?<br />
Yes .</p>
<p>What are key-mode and locking mode properties? level ?<br />
Key Mode : Specifies how oracle forms uniquely identifies rows in the database.This is property includes for application that</p>
<p>will run against NON-ORACLE datasources .<br />
Key setting unique (default.)<br />
dateable<br />
n-updateable.</p>
<p>Locking mode :<br />
Specifies when Oracle Forms should attempt to obtain database locks on rows that correspond to queried records in the form.</p>
<p>a) immediate b) delayed</p>
<p>What are savepoint mode and cursor mode properties ? level?<br />
Specifies whether Oracle Forms should issue savepoints during a session. This property is included primarily for applications</p>
<p>that will run against non-ORACLE data sources. For applications that will run against ORACLE, use the default setting.<br />
Cursor mode – define cursor state across transaction Open/close.</p>
<p>What is transactional trigger property?<br />
Identifies a block as transactional control block. i.e. non – database block that oracle forms should manage as transactional</p>
<p>block.(NON-ORACLE datasource) default – FALSE.</p>
<p>What is OLE automation ?<br />
OLE automation allows an OLE server application to expose a set of commands and functions that can be invoked from an OLE</p>
<p>container application. OLE automation provides a way for an OLE container application to use the features of an OLE server</p>
<p>application to manipulate an OLE object from the OLE container environment. (FORMS_OLE)</p>
<p>What does invoke built-in do?<br />
This procedure invokes a method.<br />
Syntax:<br />
PROCEDURE OLE2.INVOKE<br />
(object obj_type,<br />
method VARCHAR2,<br />
list list_type := 0);<br />
Parameters:<br />
object Is an OLE2 Automation Object.<br />
method Is a method (procedure) of the OLE2 object.<br />
list Is the name of an argument list assigned to the OLE2.CREATE_ARGLIST function.</p>
<p>What are OPEN_FORM,CALL_FORM,NEW_FORM? diff?<br />
CALL_FORM : It calls the other form. but parent remains active, when called form completes the operation , it releases lock</p>
<p>and control goes back to the calling form.<br />
When you call a form, Oracle Forms issues a savepoint for the called form. If the CLEAR_FORM function causes a rollback when</p>
<p>the called form is current, Oracle Forms rolls back uncommitted changes to this savepoint.<br />
OPEN_FORM : When you call a form, Oracle Forms issues a savepoint for the called form. If the CLEAR_FORM function causes a</p>
<p>rollback when the called form is current, Oracle Forms rolls back uncommitted changes to this savepoint.<br />
NEW_FORM : Exits the current form and enters the indicated form. The calling form is terminated as the parent form. If the</p>
<p>calling form had been called by a higher form, Oracle Forms keeps the higher call active and treats it as a call to the new</p>
<p>form. Oracle Forms releases memory (such as database cursors) that the terminated form was using.<br />
Oracle Forms runs the new form with the same Runform options as the parent form. If the parent form was a called form, Oracle</p>
<p>Forms runs the new form with the same options as the parent form.</p>
<p>What is call form stack?<br />
When successive forms are loaded via the CALL_FORM procedure, the resulting module hierarchy is known as the call form stack.</p>
<p>Can u port applictions across the platforms? how?<br />
Yes we can port applications across platforms.Consider the form developed in a windows system.The form would be generated in</p>
<p>unix system by using f45gen my_form.fmb scott/tiger</p>
<p>What is a visual attribute?<br />
Visual attributes are the font, color, and pattern properties that you set for form and menu objects that appear in your</p>
<p>application’s interface.</p>
<p>Diff. between VAT and Property Class?<br />
Named visual attributes define only font, color, and pattern attributes; property classes can contain these and any other</p>
<p>properties.<br />
You can change the appearance of objects at runtime by changing the named visual attribute programmatically; property class</p>
<p>assignment cannot be changed programmatically. When an object is inheriting from both a property class and a named visual</p>
<p>attribute, the named visual attribute settings take precedence, and any visual attribute properties in the class are ignored.</p>
<p>Which trigger related to mouse?<br />
When-Mouse-Click<br />
When-Mouse-DoubleClick<br />
When-Mouse-Down<br />
When-Mouse-Enter<br />
When-Mouse-Leave<br />
When-Mouse-Move<br />
When-Mouse-Up</p>
<p>What is Current record attribute property?<br />
Specifies the named visual attribute used when an item is part of the current record. Current Record Attribute is frequently</p>
<p>used at the block level to display the current row in a multi-record If you define an item-level Current Record Attribute,</p>
<p>you can display a pre-determined item in a special color when it is part of the current record, but you cannot dynamically</p>
<p>highlight the current item, as the input focus changes.</p>
<p>Can u change VAT at run time?<br />
Yes. You can programmatically change an object’s named visual attribute setting to change the font, color, and pattern of the</p>
<p>object at runtime.</p>
<p>Can u set default font in forms?<br />
Yes. Change windows registry(regedit). Set form45_font to the desired font.<br />
_break</p>
<p>What is Log Switch ?<br />
The point at which ORACLE ends writing to one online redo log file and begins writing to another is called a log switch.</p>
<p>What is On-line Redo Log?<br />
The On-line Redo Log is a set of tow or more on-line redo files that record all committed changes made to the database.</p>
<p>Whenever a transaction is committed, the corresponding redo entries temporarily stores in redo log buffers of the SGA are</p>
<p>written to an on-line redo log file by the background process LGWR. The on-line redo log files are used in cyclical fashion.</p>
<p>Which parameter specified in the DEFAULT STORAGE clause of CREATE TABLESPACE cannot be altered after creating the tablespace?<br />
All the default storage parameters defined for the tablespace can be changed using the ALTER TABLESPACE command. When objects</p>
<p>are created their INITIAL and MINEXTENS values cannot be changed.</p>
<p>What are the steps involved in Database Startup ?<br />
Start an instance, Mount the Database and Open the Database.<br />
Rolling forward to recover data that has not been recorded in data files, yet has been recorded in the on-line redo log,</p>
<p>including the contents of rollback segments. Rolling back transactions that have been explicitly rolled back or have not been</p>
<p>committed as indicated by the rollback segments regenerated in step a. Releasing any resources (locks) held by transactions</p>
<p>in process at the time of the failure. Resolving any pending distributed transactions undergoing a two-phase commit at the</p>
<p>time of the instance failure.</p>
<p>Can Full Backup be performed when the database is open ?<br />
No.</p>
<p>What are the different modes of mounting a Database with the Parallel Server ?<br />
Exclusive Mode If the first instance that mounts a database does so in exclusive mode, only that Instance can mount the</p>
<p>database.<br />
Parallel Mode If the first instance that mounts a database is started in parallel mode, other instances that are started in</p>
<p>parallel mode can also mount the database.</p>
<p>What are the advantages of operating a database in ARCHIVELOG mode over operating it in NO ARCHIVELOG mode ?<br />
Complete database recovery from disk failure is possible only in ARCHIVELOG mode. Online database backup is possible only in</p>
<p>ARCHIVELOG mode.</p>
<p>What are the steps involved in Database Shutdown ?<br />
Close the Database, Dismount the Database and Shutdown the Instance.</p>
<p>What is Archived Redo Log ?<br />
Archived Redo Log consists of Redo Log files that have archived before being reused.</p>
<p>What is Restricted Mode of Instance Startup ?<br />
An instance can be started in (or later altered to be in) restricted mode so that when the database is open connections are</p>
<p>limited only to those whose user accounts have been granted the RESTRICTED SESSION system privilege.</p>
<p>Can u have OLE objects in forms?<br />
Yes.</p>
<p>Can u have VBX and OCX controls in forms ?<br />
Yes.</p>
<p>What r the types of windows (Window style)?<br />
Specifies whether the window is a Document window or a Dialog window.</p>
<p>What is OLE Activation style property?<br />
Specifies the event that will activate the OLE containing item.</p>
<p>Can u change the mouse pointer ? How?<br />
Yes. Specifies the mouse cursor style. Use this property to dynamically change the shape of the cursor.</p>
<p>How many types of columns are there and what are they<br />
Formula columns :: For doing mathematical calculations and returning one value Summary Columns :: For doing summary</p>
<p>calculations such as summations etc. Place holder Columns :: These columns are useful for storing the value in a variable</p>
<p>Can u have more than one layout in report<br />
It is possible to have more than one layout in a report by using the additional layout option in the layout editor.</p>
<p>Can u run the report with out a parameter form<br />
Yes it is possible to run the report without parameter form by setting the PARAM value to Null</p>
<p>What is the lock option in reports layout<br />
By using the lock option we cannot move the fields in the layout editor outside the frame. This is useful for maintaining the</p>
<p>fields .</p>
<p>What is Flex<br />
Flex is the property of moving the related fields together by setting the flex property on</p>
<p>What are the minimum number of groups required for a matrix report<br />
The minimum of groups required for a matrix report are 4 e —–</p>
<p>What is a Synonym ?<br />
A synonym is an alias for a table, view, sequence or program unit.</p>
<p>What is a Sequence ?<br />
A sequence generates a serial list of unique numbers for numerical columns of a database’s tables.</p>
<p>What is a Segment ?<br />
A segment is a set of extents allocated for a certain logical structure.</p>
<p>What is schema?<br />
A schema is collection of database objects of a User.</p>
<p>Describe Referential Integrity ?<br />
A rule defined on a column (or set of columns) in one table that allows the insert or update of a row only if the value for</p>
<p>the column or set of columns (the dependent value) matches a value in a column of a related table (the referenced value). It</p>
<p>also specifies the type of data manipulation allowed on referenced data and the action to be performed on dependent data as a</p>
<p>result of any action on referenced data.</p>
<p>What is Hash Cluster ?<br />
A row is stored in a hash cluster based on the result of applying a hash function to the row’s cluster key value. All rows</p>
<p>with the same hash key value are stores together on disk.</p>
<p>What is a Private Synonyms ?<br />
A Private Synonyms can be accessed only by the owner.</p>
<p>What is Database Link ?<br />
A database link is a named object that describes a “path” from one database to another.</p>
<p>What is index cluster?<br />
A cluster with an index on the cluster key.</p>
<p>What is hash cluster?<br />
A row is stored in a hash cluster based on the result of applying a hash function to the row’s cluster key value. All rows</p>
<p>with the same hash key value are stores together on disk.</p>
<p>When can hash cluster used?<br />
Hash clusters are better choice when a table is often queried with equality queries. For such queries the specified cluster</p>
<p>key value is hashed. The resulting hash key value points directly to the area on disk that stores the specified rows.</p>
<p>When can hash cluster used?<br />
Hash clusters are better choice when a table is often queried with equality queries. For such queries the specified cluster</p>
<p>key value is hashed. The resulting hash key value points directly to the area on disk that stores the specified rows.</p>
<p>What are the types of database links?<br />
Private database link, public database link &amp; network database link.</p>
<p>What is private database link?<br />
Private database link is created on behalf of a specific user. A private database link can be used only when the owner of the</p>
<p>link specifies a global object name in a SQL statement or in the definition of the owner’s views or procedures.</p>
<p>What is public database link?<br />
Public database link is created for the special user group PUBLIC. A public database link can be used when any user in the</p>
<p>associated database specifies a global object name in a SQL statement or object definition.</p>
<p>What is network database link?<br />
Network database link is created and managed by a network domain service. A network database link can be used when any user</p>
<p>of any database in the network specifies a global object name in a SQL statement or object definition.</p>
<p>What is data block?<br />
Oracle database’s data is stored in data blocks. One data block corresponds to a specific number of bytes of physical</p>
<p>database space on disk.</p>
<p>How to define data block size?<br />
A data block size is specified for each Oracle database when the database is created. A database users and allocated free</p>
<p>database space in Oracle data blocks. Block size is specified in init.ora file and cannot be changed latter.</p>
<p>What is row chaining?<br />
In circumstances, all of the data for a row in a table may not be able to fit in the same data block. When this occurs, the</p>
<p>data for the row is stored in a chain of data block (one or more) reserved for that segment.</p>
<p>What is an extent?<br />
An extent is a specific number of contiguous data blocks, obtained in a single allocation and used to store a specific type</p>
<p>of information.</p>
<p>What are the different types of segments?<br />
Data segment, index segment, rollback segment and temporary segment.</p>
<p>What is a data segment?<br />
Each non-clustered table has a data segment. All of the table’s data is stored in the extents of its data segment. Each</p>
<p>cluster has a data segment. The data of every table in the cluster is stored in the cluster’s data segment.</p>
<p>What is an index segment?<br />
Each index has an index segment that stores all of its data.</p>
<p>What is rollback segment?<br />
A database contains one or more rollback segments to temporarily store “undo” information.</p>
<p>What are the uses of rollback segment?<br />
To generate read-consistent database information during database recovery and to rollback uncommitted transactions by the</p>
<p>users.</p>
<p>What is a temporary segment?<br />
Temporary segments are created by Oracle when a SQL statement needs a temporary work area to complete execution. When the</p>
<p>statement finishes execution, the temporary segment extents are released to the system for future use.</p>
<p>What is a datafile?<br />
Every Oracle database has one or more physical data files. A database’s data files contain all the database data. The data of</p>
<p>logical database structures such as tables and indexes is physically stored in the data files allocated for a database.</p>
<p>What are the characteristics of data files?<br />
A data file can be associated with only one database. Once created a data file can’t change size. One or more data files form</p>
<p>a logical unit of database storage called a tablespace.</p>
<p>What is a redo log?<br />
The set of redo log files for a database is collectively known as the database redo log.</p>
<p>What is the function of redo log?<br />
The primary function of the redo log is to record all changes made to data.</p>
<p>What is the use of redo log information?<br />
The information in a redo log file is used only to recover the database from a system or media failure prevents database data</p>
<p>from being written to a database’s data files.</p>
<p>What does a control file contains?<br />
- Database name<br />
- Names and locations of a database’s files and redolog files.<br />
- Time stamp of database creation.</p>
<p>What is the use of control file?<br />
When an instance of an Oracle database is started, its control file is used to identify the database and redo log files that</p>
<p>must be opened for database operation to proceed. It is also used in database recovery.</p>
<p>Is it possible to split the print reviewer into more than one region?<br />
Yes</p>
<p>Is it possible to center an object horizontally in a repeating frame that has a variable horizontal size?<br />
Yes</p>
<p>For a field in a repeating frame, can the source come from the column which does not exist in the data group which forms the</p>
<p>base for the frame?<br />
Yes</p>
<p>Can a field be used in a report without it appearing in any data group?<br />
Yes</p>
<p>The join defined by the default data link is an outer join yes or no?<br />
Yes</p>
<p>Can a formula column referred to columns in higher group?<br />
Yes</p>
<p>Can a formula column be obtained through a select statement?<br />
Yes</p>
<p>Is it possible to insert comments into sql statements return in the data model editor?<br />
Yes</p>
<p>Is it possible to disable the parameter from while running the report?<br />
Yes</p>
<p>When a form is invoked with call_form, Does oracle forms issues a save point?<br />
Yes</p>
<p>Explain the difference between a hot backup and a cold backup and the benefits associated with each.<br />
A hot backup is basically taking a backup of the database while it is still up and running and it must be in archive log</p>
<p>mode. A cold backup is taking a backup of the database while it is shut down and does not require being in archive log mode.</p>
<p>The benefit of taking a hot backup is that the database is still available for use while the backup is occurring and you can</p>
<p>recover the database to any point in time. The benefit of taking a cold backup is that it is typically easier to administer</p>
<p>the backup and recovery process. In addition, since you are taking cold backups the database does not require being in</p>
<p>archive log mode and thus there will be a slight performance gain as the database is not cutting archive logs to disk.</p>
<p>You have just had to restore from backup and do not have any control files. How would you go about bringing up this database?<br />
I would create a text based backup control file, stipulating where on disk all the data files where and then issue the</p>
<p>recover command with the using backup control file clause.</p>
<p>How do you switch from an init.ora file to a spfile?<br />
Issue the create spfile from pfile command.</p>
<p>Explain the difference between a data block, an extent and a segment.<br />
A data block is the smallest unit of logical storage for a database object. As objects grow they take chunks of additional</p>
<p>storage that are composed of contiguous data blocks. These groupings of contiguous data blocks are called extents. All the</p>
<p>extents that an object takes when grouped together are considered the segment of the database object.</p>
<p>Give two examples of how you might determine the structure of the table DEPT.<br />
Use the describe command or use the dbms_metadata.get_ddl package.</p>
<p>Where would you look for errors from the database engine?<br />
In the alert log.</p>
<p>Compare and contrast TRUNCATE and DELETE for a table.<br />
Both the truncate and delete command have the desired outcome of getting rid of all the rows in a table. The difference</p>
<p>between the two is that the truncate command is a DDL operation and just moves the high water mark and produces a now</p>
<p>rollback. The delete command, on the other hand, is a DML operation, which will produce a rollback and thus take longer to</p>
<p>complete.</p>
<p>Give the reasoning behind using an index.<br />
Faster access to data blocks in a table.</p>
<p>Give the two types of tables involved in producing a star schema and the type of data they hold.<br />
Fact tables and dimension tables. A fact table contains measurements while dimension tables will contain data that will help</p>
<p>describe the fact tables.</p>
<p>What type of index should you use on a fact table?<br />
A Bitmap index.</p>
<p>Give two examples of referential integrity constraints.<br />
A primary key and a foreign key.</p>
<p>A table is classified as a parent table and you want to drop and re-create it. How would you do this without affecting the</p>
<p>children tables?<br />
Disable the foreign key constraint to the parent, drop the table, re-create the table, enable the foreign key constraint.</p>
<p>Explain the difference between ARCHIVELOG mode and NOARCHIVELOG mode and the benefits and disadvantages to each.<br />
ARCHIVELOG mode is a mode that you can put the database in for creating a backup of all transactions that have occurred in</p>
<p>the database so that you can recover to any point in time. NOARCHIVELOG mode is basically the absence of ARCHIVELOG mode and</p>
<p>has the disadvantage of not being able to recover to any point in time. NOARCHIVELOG mode does have the advantage of not</p>
<p>having to write transactions to an archive log and thus increases the performance of the database slightly.</p>
<p>What command would you use to create a backup control file?<br />
Alter database backup control file to trace.</p>
<p>Give the stages of instance startup to a usable state where normal users may access it.<br />
STARTUP NOMOUNT – Instance startup<br />
STARTUP MOUNT – The database is mounted<br />
STARTUP OPEN – The database is opened</p>
<p>What column differentiates the V$ views to the GV$ views and how?<br />
The INST_ID column which indicates the instance in a RAC environment the information came from.</p>
<p>How would you go about generating an EXPLAIN plan?<br />
Create a plan table with utlxplan.sql.<br />
Use the explain plan set statement_id = ‘tst1′ into plan_table for a SQL statement<br />
Look at the explain plan with utlxplp.sql or utlxpls.sql</p>
<p>How would you go about increasing the buffer cache hit ratio?<br />
Use the buffer cache advisory over a given workload and then query the v$db_cache_advice table. If a change was necessary</p>
<p>then I would use the alter system set db_cache_size command.</p>
<p>Explain an ORA-01555<br />
You get this error when you get a snapshot too old within rollback. It can usually be solved by increasing the undo retention</p>
<p>or increasing the size of rollbacks. You should also look at the logic involved in the application getting the error message.</p>
<p>Explain the difference between $ORACLE_HOME and $ORACLE_BASE.<br />
ORACLE_BASE is the root directory for oracle. ORACLE_HOME located beneath ORACLE_BASE is where the oracle products reside.</p>
<p>How would you determine the time zone under which a database was operating?<br />
select DBTIMEZONE from dual;</p>
<p>Explain the use of setting GLOBAL_NAMES equal to TRUE.<br />
Setting GLOBAL_NAMES dictates how you might connect to a database. This variable is either TRUE or FALSE and if it is set to</p>
<p>TRUE it enforces database links to have the same name as the remote database to which they are linking.</p>
<p>What command would you use to encrypt a PL/SQL application?<br />
WRAP</p>
<p>Explain the difference between a FUNCTION, PROCEDURE and PACKAGE.<br />
A function and procedure are the same in that they are intended to be a collection of PL/SQL code that carries a single task.</p>
<p>While a procedure does not have to return any values to the calling application, a function will return a single value. A</p>
<p>package on the other hand is a collection of functions and procedures that are grouped together based on their commonality to</p>
<p>a business function or application.</p>
<p>Explain the use of table functions.<br />
Table functions are designed to return a set of rows through PL/SQL logic but are intended to be used as a normal table or</p>
<p>view in a SQL statement. They are also used to pipeline information in an ETL process.</p>
<p>Name three advisory statistics you can collect.<br />
Buffer Cache Advice, Segment Level Statistics, &amp; Timed Statistics</p>
<p>Where in the Oracle directory tree structure are audit traces placed?<br />
In unix $ORACLE_HOME/rdbms/audit, in Windows the event viewer</p>
<p>Explain materialized views and how they are used.<br />
Materialized views are objects that are reduced sets of information that have been summarized, grouped, or aggregated from</p>
<p>base tables. They are typically used in data warehouse or decision support systems.</p>
<p>When a user process fails, what background process cleans up after it?<br />
PMON</p>
<p>What background process refreshes materialized views?<br />
The Job Queue Processes.</p>
<p>How would you determine what sessions are connected and what resources they are waiting for?<br />
Use of V$SESSION and V$SESSION_WAIT</p>
<p>Describe what redo logs are.<br />
Redo logs are logical and physical structures that are designed to hold all the changes made to a database and are intended</p>
<p>to aid in the recovery of a database.</p>
<p>How would you force a log switch?<br />
ALTER SYSTEM SWITCH LOGFILE;</p>
<p>Give two methods you could use to determine what DDL changes have been made.<br />
You could use Logminer or Streams</p>
<p>What does coalescing a tablespace do?<br />
Coalescing is only valid for dictionary-managed tablespaces and de-fragments space by combining neighboring free extents into</p>
<p>large single extents.</p>
<p>What is the difference between a TEMPORARY tablespace and a PERMANENT tablespace?<br />
A temporary tablespace is used for temporary objects such as sort structures while permanent tablespaces are used to store</p>
<p>those objects meant to be used as the true objects of the database.</p>
<p>Name a tablespace automatically created when you create a database.<br />
The SYSTEM tablespace.</p>
<p>When creating a user, what permissions must you grant to allow them to connect to the database?<br />
Grant the CONNECT to the user.</p>
<p>How do you add a data file to a tablespace<br />
ALTER TABLESPACE<br />
ADD DATAFILE SIZE</p>
<p>How do you resize a data file?<br />
ALTER DATABASE DATAFILE RESIZE ;</p>
<p>What view would you use to look at the size of a data file?<br />
DBA_DATA_FILES</p>
<p>What view would you use to determine free space in a tablespace?<br />
DBA_FREE_SPACE</p>
<p>How would you determine who has added a row to a table?<br />
Turn on fine grain auditing for the table.</p>
<p>How can you rebuild an index?<br />
ALTER INDEX REBUILD;</p>
<p>Explain what partitioning is and what its benefit is.<br />
Partitioning is a method of taking large tables and indexes and splitting them into smaller, more manageable pieces.</p>
<p>You have just compiled a PL/SQL package but got errors, how would you view the errors?<br />
SHOW ERRORS</p>
<p>How can you gather statistics on a table?<br />
The ANALYZE command.</p>
<p>How can you enable a trace for a session?<br />
Use the DBMS_SESSION.SET_SQL_TRACE or<br />
Use ALTER SESSION SET SQL_TRACE = TRUE;</p>
<p>What is the difference between the SQL*Loader and IMPORT utilities?<br />
These two Oracle utilities are used for loading data into the database. The difference is that the import utility relies on</p>
<p>the data being produced by another Oracle utility EXPORT while the SQL*Loader utility allows data to be loaded that has been</p>
<p>produced by other utilities from different data sources just so long as it conforms to ASCII formatted or delimited files.</p>
<p>Name two files used for network connection to a database.<br />
TNSNAMES.ORA and SQLNET.ORA</p>
<p>What is the function of Optimizer ?<br />
The goal of the optimizer is to choose the most efficient way to execute a SQL statement.</p>
<p>What is Execution Plan ?<br />
The combinations of the steps the optimizer chooses to execute a statement is called an execution plan.</p>
<p>Can one resize tablespaces and data files? (for DBA)<br />
One can manually increase or decrease the size of a datafile from Oracle 7.2 using the command.<br />
ALTER DATABASE DATAFILE ‘filename2′ RESIZE 100M;<br />
Because you can change the sizes of datafiles, you can add more space to your database without adding more datafiles. This is</p>
<p>beneficial if you are concerned about reaching the maximum number of datafiles allowed in your database.<br />
Manually reducing the sizes of datafiles allows you to reclaim unused space in the database. This is useful for correcting</p>
<p>errors in estimations of space requirements.<br />
Also, datafiles can be allowed to automatically extend if more space is required. Look at the following command:<br />
CREATE TABLESPACE pcs_data_ts<br />
DATAFILE ‘c:\ora_apps\pcs\pcsdata1.dbf’ SIZE 3M<br />
AUTOEXTEND ON NEXT 1M MAXSIZE UNLIMITED<br />
DEFAULT STORAGE (INITIAL 10240<br />
NEXT 10240<br />
MINEXTENTS 1<br />
MAXEXTENTS UNLIMITED<br />
PCTINCREASE 0)<br />
ONLINE<br />
PERMANENT;</p>
<p>What is SAVE POINT ?<br />
For long transactions that contain many SQL statements, intermediate markers or savepoints can be declared which can be used</p>
<p>to divide a transaction into smaller parts. This allows the option of later rolling back all work performed from the current</p>
<p>point in the transaction to a declared savepoint within the transaction.</p>
<p>What are the values that can be specified for OPTIMIZER MODE Parameter ?<br />
COST and RULE.</p>
<p>Can one rename a tablespace? (for DBA)<br />
No, this is listed as Enhancement Request 148742. Workaround:<br />
Export all of the objects from the tablespace<br />
Drop the tablespace including contents<br />
Recreate the tablespace<br />
Import the objects</p>
<p>What is RULE-based approach to optimization ?<br />
Choosing an executing planbased on the access paths available and the ranks of these access paths.</p>
<p>What are the values that can be specified for OPTIMIZER_GOAL parameter of the ALTER SESSION Command ?<br />
CHOOSE,ALL_ROWS,FIRST_ROWS and RULE.</p>
<p>How does one create a standby database? (for DBA)<br />
While your production database is running, take an (image copy) backup and restore it on duplicate hardware. Note that an</p>
<p>export will not work!!!<br />
On your standby database, issue the following commands:<br />
ALTER DATABASE CREATE STANDBY CONTROLFILE AS ‘filename’;<br />
ALTER DATABASE MOUNT STANDBY DATABASE;<br />
RECOVER STANDBY DATABASE;<br />
On systems prior to Oracle 8i, write a job to copy archived redo log files from the primary database to the standby system,</p>
<p>and apply the redo log files to the standby database (pipe it). Remember the database is recovering and will prompt you for</p>
<p>the next log file to apply.<br />
Oracle 8i onwards provide an “Automated Standby Database” feature, which will send archived, log files to the remote site via</p>
<p>NET8, and apply then to the standby database.<br />
When one needs to activate the standby database, stop the recovery process and activate it:<br />
ALTER DATABASE ACTIVATE STANDBY DATABASE;</p>
<p>How does one give developers access to trace files (required as input to tkprof)? (for DBA)<br />
The “alter session set sql_trace=true” command generates trace files in USER_DUMP_DEST that can be used by developers as</p>
<p>input to tkprof. On Unix the default file mask for these files are “rwx r– —”.<br />
There is an undocumented INIT.ORA parameter that will allow everyone to read (rwx r-r–) these trace files:<br />
_trace_files_public = true<br />
Include this in your INIT.ORA file and bounce your database for it to take effect.</p>
<p>What are the responsibilities of a Database Administrator ?<br />
Installing and upgrading the Oracle Server and application tools. Allocating system storage and planning future storage</p>
<p>requirements for the database system. Managing primary database structures (tablespaces) Managing primary objects</p>
<p>(table,views,indexes) Enrolling users and maintaining system security. Ensuring compliance with Oralce license agreement</p>
<p>Controlling and monitoring user access to the database. Monitoring and optimizing the performance of the database. Planning</p>
<p>for backup and recovery of database information. Maintain archived data on tape Backing up and restoring the database.</p>
<p>Contacting Oracle Corporation for technical support.</p>
<p>What is a trace file and how is it created ?<br />
Each server and background process can write an associated trace file. When an internal error is detected by a process or</p>
<p>user process, it dumps information about the error to its trace. This can be used for tuning the database.</p>
<p>What are the roles and user accounts created automatically with the database?<br />
DBA – role Contains all database system privileges.<br />
SYS user account – The DBA role will be assigned to this account. All of the base tables and views for the database’s</p>
<p>dictionary are store in this schema and are manipulated only by ORACLE. SYSTEM user account – It has all the system</p>
<p>privileges for the database and additional tables and views that display administrative information and internal tables and</p>
<p>views used by oracle tools are created using this username.</p>
<p>What are the minimum parameters should exist in the parameter file (init.ora) ?<br />
DB NAME – Must set to a text string of no more than 8 characters and it will be stored inside the datafiles, redo log files</p>
<p>and control files and control file while database creation.<br />
DB_DOMAIN – It is string that specifies the network domain where the database is created. The global database name is</p>
<p>identified by setting these parameters<br />
(DB_NAME &amp; DB_DOMAIN) CONTORL FILES – List of control filenames of the database. If name is not mentioned then default name</p>
<p>will be used.<br />
DB_BLOCK_BUFFERS – To determine the no of buffers in the buffer cache in SGA.<br />
PROCESSES – To determine number of operating system processes that can be connected to ORACLE concurrently. The value should</p>
<p>be 5 (background process) and additional 1 for each user.<br />
ROLLBACK_SEGMENTS – List of rollback segments an ORACLE instance acquires at database startup. Also optionally</p>
<p>LICENSE_MAX_SESSIONS,LICENSE_SESSION_WARNING and LICENSE_MAX_USERS.</p>
<p>Why and when should I backup my database? (for DBA)<br />
Backup and recovery is one of the most important aspects of a DBAs job. If you lose your company’s data, you could very well</p>
<p>lose your job. Hardware and software can always be replaced, but your data may be irreplaceable!<br />
Normally one would schedule a hierarchy of daily, weekly and monthly backups, however consult with your users before deciding</p>
<p>on a backup schedule. Backup frequency normally depends on the following factors:<br />
. Rate of data change/ transaction rate<br />
. Database availability/ Can you shutdown for cold backups?<br />
. Criticality of the data/ Value of the data to the company<br />
. Read-only tablespace needs backing up just once right after you make it read-only<br />
. If you are running in archivelog mode you can backup parts of a database over an extended cycle of days<br />
. If archive logging is enabled one needs to backup archived log files timeously to prevent database freezes<br />
. Etc.<br />
Carefully plan backup retention periods. Ensure enough backup media (tapes) are available and that old backups are expired</p>
<p>in-time to make media available for new backups. Off-site vaulting is also highly recommended.<br />
Frequently test your ability to recover and document all possible scenarios. Remember, it’s the little things that will get</p>
<p>you. Most failed recoveries are a result of organizational errors and miscommunications.</p>
<p>What strategies are available for backing-up an Oracle database? (for DBA)<br />
The following methods are valid for backing-up an Oracle database:<br />
Export/Import – Exports are “logical” database backups in that they extract logical definitions and data from the database to</p>
<p>a file.<br />
Cold or Off-line Backups – Shut the database down and backup up ALL data, log, and control files.<br />
Hot or On-line Backups – If the databases are available and in ARCHIVELOG mode, set the tablespaces into backup mode and</p>
<p>backup their files. Also remember to backup the control files and archived redo log files.<br />
RMAN Backups – While the database is off-line or on-line, use the “rman” utility to backup the database.<br />
It is advisable to use more than one of these methods to backup your database. For example, if you choose to do on-line</p>
<p>database backups, also cover yourself by doing database exports. Also test ALL backup and recovery scenarios carefully. It is</p>
<p>better to be save than sorry.<br />
Regardless of your strategy, also remember to backup all required software libraries, parameter files, password files, etc.</p>
<p>If your database is in ARCGIVELOG mode, you also need to backup archived log files.</p>
<p>What is the difference between online and offline backups? (for DBA)<br />
A hot backup is a backup performed while the database is online and available for read/write. Except for Oracle exports, one</p>
<p>can only do on-line backups when running in ARCHIVELOG mode.<br />
A cold backup is a backup performed while the database is off-line and unavailable to its users.</p>
<p>What is the difference between restoring and recovering? (for DBA)<br />
Restoring involves copying backup files from secondary storage (backup media) to disk. This can be done to replace damaged</p>
<p>files or to copy/move a database to a new location.<br />
Recovery is the process of applying redo logs to the database to roll it forward. One can roll-forward until a specific</p>
<p>point-in-time (before the disaster occurred), or roll-forward until the last transaction recorded in the log files. Sql&gt;</p>
<p>connect SYS as SYSDBA<br />
Sql&gt; RECOVER DATABASE UNTIL TIME ’2001-03-06:16:00:00′ USING BACKUP CONTROLFILE;</p>
<p>How does one backup a database using the export utility? (for DBA)<br />
Oracle exports are “logical” database backups (not physical) as they extract data and logical definitions from the database</p>
<p>into a file. Other backup strategies normally back-up the physical data files.<br />
One of the advantages of exports is that one can selectively re-import tables, however one cannot roll-forward from an</p>
<p>restored export file. To completely restore a database from an export file one practically needs to recreate the entire</p>
<p>database.<br />
Always do full system level exports (FULL=YES). Full exports include more information about the database in the export file</p>
<p>than user level exports.</p>
<p>What are the built_ins used the display the LOV?<br />
Show_lov<br />
List_values</p>
<p>How do you call other Oracle Products from Oracle Forms?<br />
Run_product is a built-in, Used to invoke one of the supported oracle tools products and specifies the name of the document</p>
<p>or module to be run. If the called product is unavailable at the time of the call, Oracle Forms returns a message to the</p>
<p>operator.</p>
<p>What is the main diff. bet. Reports 2.0 &amp; Reports 2.5?<br />
Report 2.5 is object oriented.</p>
<p>What are the Built-ins to display the user-named editor?<br />
A user named editor can be displayed programmatically with the built in procedure SHOW-EDITOR, EDIT_TETITEM independent of</p>
<p>any particular text item.</p>
<p>How many number of columns a record group can have?<br />
A record group can have an unlimited number of columns of type CHAR, LONG, NUMBER, or DATE provided that the total number of</p>
<p>column does not exceed 64K.</p>
<p>What is a Query Record Group?<br />
A query record group is a record group that has an associated SELECT statement. The columns in a query record group derive</p>
<p>their default names, data types, had lengths from the database columns referenced in the SELECT statement. The records in</p>
<p>query record group are the rows retrieved by the query associated with that record group.</p>
<p>What does the term panel refer to with regard to pages?<br />
A panel is the no. of physical pages needed to print one logical page.</p>
<p>What is a master detail relationship?<br />
A master detail relationship is an association between two base table blocks- a master block and a detail block. The</p>
<p>relationship between the blocks reflects a primary key to foreign key relationship between the tables on which the blocks are</p>
<p>based.</p>
<p>What is a library?<br />
A library is a collection of subprograms including user named procedures, functions and packages.</p>
<p>What is an anchoring object &amp; what is its use? What are the various sub events a mouse double click event involves?<br />
An anchoring object is a print condition object which used to explicitly or implicitly anchor other objects to itself.</p>
<p>Use the add_group_column function to add a column to record group that was created at a design time?<br />
False</p>
<p>What are the various sub events a mouse double click event involves? What are the various sub events a mouse double click</p>
<p>event involves?<br />
Double clicking the mouse consists of the mouse down, mouse up, mouse click, mouse down &amp; mouse up events.</p>
<p>What is the use of break group? What are the various sub events a mouse double click event involves?<br />
A break group is used to display one record for one group ones. While multiple related records in other group can be</p>
<p>displayed.</p>
<p>What tuning indicators can one use? (for DBA)<br />
The following high-level tuning indicators can be used to establish if a database is performing optimally or not:<br />
. Buffer Cache Hit Ratio<br />
Formula: Hit Ratio = (Logical Reads – Physical Reads) / Logical Reads<br />
Action: Increase DB_CACHE_SIZE (DB_BLOCK_BUFFERS prior to 9i) to increase hit ratio<br />
. Library Cache Hit Ratio<br />
Action: Increase the SHARED_POOL_SIZE to increase hit ratio</p>
<p>What tools/utilities does Oracle provide to assist with performance tuning? (for DBA)<br />
Oracle provide the following tools/ utilities to assist with performance monitoring and tuning:<br />
. TKProf<br />
. UTLBSTAT.SQL and UTLESTAT.SQL – Begin and end stats monitoring<br />
. Statspack<br />
. Oracle Enterprise Manager – Tuning Pack</p>
<p>What is STATSPACK and how does one use it? (for DBA)<br />
Statspack is a set of performance monitoring and reporting utilities provided by Oracle from Oracle8i and above. Statspack</p>
<p>provides improved BSTAT/ESTAT functionality, though the old BSTAT/ESTAT scripts are still available. For more information</p>
<p>about STATSPACK, read the documentation in file $ORACLE_HOME/rdbms/admin/spdoc.txt.<br />
Install Statspack:<br />
cd $ORACLE_HOME/rdbms/admin<br />
sqlplus “/ as sysdba” @spdrop.sql — Install Statspack -<br />
sqlplus “/ as sysdba” @spcreate.sql– Enter tablespace names when prompted<br />
Use Statspack:<br />
sqlplus perfstat/perfstat<br />
exec statspack.snap; — Take a performance snapshots<br />
exec statspack.snap;<br />
o Get a list of snapshots<br />
select SNAP_ID, SNAP_TIME from STATS$SNAPSHOT;<br />
@spreport.sql — Enter two snapshot id’s for difference report<br />
Other Statspack Scripts:<br />
. sppurge.sql – Purge a range of Snapshot Id’s between the specified begin and end Snap Id’s<br />
. spauto.sql – Schedule a dbms_job to automate the collection of STATPACK statistics<br />
. spcreate.sql – Installs the STATSPACK user, tables and package on a database (Run as SYS).<br />
. spdrop.sql – Deinstall STATSPACK from database (Run as SYS)<br />
. sppurge.sql – Delete a range of Snapshot Id’s from the database<br />
. spreport.sql – Report on differences between values recorded in two snapshots<br />
. sptrunc.sql – Truncates all data in Statspack tables</p>
<p>What are the common RMAN errors (with solutions)? (for DBA)<br />
Some of the common RMAN errors are:<br />
RMAN-20242: Specification does not match any archivelog in the recovery catalog.<br />
Add to RMAN script: sql ‘alter system archive log current’;<br />
RMAN-06089: archived log xyz not found or out of sync with catalog<br />
Execute from RMAN: change archivelog all validate;</p>
<p>How can you execute the user defined triggers in forms 3.0 ?<br />
Execute Trigger (trigger-name)</p>
<p>What ERASE package procedure does ?<br />
Erase removes an indicated global variable.</p>
<p>What is the difference between NAME_IN and COPY ?<br />
Copy is package procedure and writes values into a field.<br />
Name in is a package function and returns the contents of the variable to which you apply.</p>
<p>What package procedure is used for calling another form ?<br />
Call (E.g. Call(formname)</p>
<p>When the form is running in DEBUG mode, If you want to examine the values of global variables and other form variables, What</p>
<p>package procedure command you would use in your trigger text ?<br />
Break.<br />
SYSTEM VARIABLES</p>
<p>The value recorded in system.last_record variable is of type<br />
a. Number<br />
b. Boolean<br />
c. Character. ?<br />
b. Boolean.</p>
<p>What is mean by Program Global Area (PGA) ?<br />
It is area in memory that is used by a Single Oracle User Process.</p>
<p>What is hit ratio ?<br />
It is a measure of well the data cache buffer is handling requests for data. Hit Ratio = (Logical Reads – Physical Reads -</p>
<p>Hits Misses)/ Logical Reads.</p>
<p>How do u implement the If statement in the Select Statement<br />
We can implement the if statement in the select statement by using the Decode statement. e.g. select DECODE</p>
<p>(EMP_CAT,’1′,’First’,’2′,’Second’Null); Here the Null is the else statement where null is done .</p>
<p>How many types of Exceptions are there<br />
There are 2 types of exceptions. They are<br />
a) System Exceptions<br />
e.g. When no_data_found, When too_many_rows<br />
b) User Defined Exceptions<br />
e.g. My_exception exception<br />
When My_exception then</p>
<p>What are the inline and the precompiler directives<br />
The inline and precompiler directives detect the values directly</p>
<p>How do you use the same lov for 2 columns<br />
We can use the same lov for 2 columns by passing the return values in global values and using the global values in the code</p>
<p>How many minimum groups are required for a matrix report<br />
The minimum number of groups in matrix report are 4</p>
<p>What is the difference between static and dynamic lov<br />
The static lov contains the predetermined values while the dynamic lov contains values that come at run time</p>
<p>How does one manage Oracle database users? (for DBA)<br />
Oracle user accounts can be locked, unlocked, forced to choose new passwords, etc. For example, all accounts except SYS and</p>
<p>SYSTEM will be locked after creating an Oracle9iDB database using the DB Configuration Assistant (dbca). DBA’s must unlock</p>
<p>these accounts to make them available to users.<br />
Look at these examples:<br />
ALTER USER scott ACCOUNT LOCK — lock a user account<br />
ALTER USER scott ACCOUNT UNLOCK; — unlocks a locked users account<br />
ALTER USER scott PASSWORD EXPIRE; — Force user to choose a new password</p>
<p>What is the difference between DBFile Sequential and Scattered Reads?(for DBA)<br />
Both “db file sequential read” and “db file scattered read” events signify time waited for I/O read requests to complete.</p>
<p>Time is reported in 100′s of a second for Oracle 8i releases and below, and 1000′s of a second for Oracle 9i and above. Most</p>
<p>people confuse these events with each other as they think of how data is read from disk. Instead they should think of how</p>
<p>data is read into the SGA buffer cache.<br />
db file sequential read:<br />
A sequential read operation reads data into contiguous memory (usually a single-block read with p3=1, but can be multiple</p>
<p>blocks). Single block I/Os are usually the result of using indexes. This event is also used for rebuilding the control file</p>
<p>and reading data file headers (P2=1). In general, this event is indicative of disk contention on index reads.<br />
db file scattered read:<br />
Similar to db file sequential reads, except that the session is reading multiple data blocks and scatters them into different</p>
<p>discontinuous buffers in the SGA. This statistic is NORMALLY indicating disk contention on full table scans. Rarely, data</p>
<p>from full table scans could be fitted into a contiguous buffer area, these waits would then show up as sequential reads</p>
<p>instead of scattered reads.<br />
The following query shows average wait time for sequential versus scattered reads:<br />
prompt “AVERAGE WAIT TIME FOR READ REQUESTS”<br />
select a.average_wait “SEQ READ”, b.average_wait “SCAT READ”<br />
from sys.v_$system_event a, sys.v_$system_event b<br />
where a.event = ‘db file sequential read’<br />
and b.event = ‘db file scattered read’;</p>
<p>What is the use of PARFILE option in EXP command ?<br />
Name of the parameter file to be passed for export.</p>
<p>What is the use of TABLES option in EXP command ?<br />
List of tables should be exported.ze)</p>
<p>What is the OPTIMAL parameter?<br />
It is used to set the optimal length of a rollback segment.</p>
<p>How does one use ORADEBUG from Server Manager/ SQL*Plus? (for DBA)<br />
Execute the “ORADEBUG HELP” command from svrmgrl or sqlplus to obtain a list of valid ORADEBUG commands. Look at these</p>
<p>examples:<br />
SQLPLUS&gt; REM Trace SQL statements with bind variables<br />
SQLPLUS&gt; oradebug setospid 10121<br />
Oracle pid: 91, Unix process pid: 10121, image: oracleorcl<br />
SQLPLUS&gt; oradebug EVENT 10046 trace name context forever, level 12<br />
Statement processed.<br />
SQLPLUS&gt; ! vi /app/oracle/admin/orcl/bdump/ora_10121.trc<br />
SQLPLUS&gt; REM Trace Process Statistics<br />
SQLPLUS&gt; oradebug setorapid 2<br />
Unix process pid: 1436, image: ora_pmon_orcl<br />
SQLPLUS&gt; oradebug procstat<br />
Statement processed.<br />
SQLPLUS&gt;&gt; oradebug TRACEFILE_NAME<br />
/app/oracle/admin/orcl/bdump/pmon_1436.trc<br />
SQLPLUS&gt; REM List semaphores and shared memory segments in use<br />
SQLPLUS&gt; oradebug ipc<br />
SQLPLUS&gt; REM Dump Error Stack<br />
SQLPLUS&gt; oradebug setospid<br />
SQLPLUS&gt; oradebug event immediate trace name errorstack level 3<br />
SQLPLUS&gt; REM Dump Parallel Server DLM locks<br />
SQLPLUS&gt; oradebug lkdebug -a convlock<br />
SQLPLUS&gt; oradebug lkdebug -a convres<br />
SQLPLUS&gt; oradebug lkdebug -r (i.e 0x8066d338 from convres dump)</p>
<p>Are there any undocumented commands in Oracle? (for DBA)<br />
Sure there are, but it is hard to find them. Look at these examples:<br />
From Server Manager (Oracle7.3 and above): ORADEBUG HELP<br />
It looks like one can change memory locations with the ORADEBUG POKE command. Anyone brave enough to test this one for us?</p>
<p>Previously this functionality was available with ORADBX (ls -l $ORACLE_HOME/rdbms/lib/oradbx.o; make -f oracle.mk oradbx)</p>
<p>SQL*Plus: ALTER SESSION SET CURRENT_SCHEMA = SYS</p>
<p>If the maximum record retrieved property of the query is set to 10 then a summary value will be calculated?<br />
Only for 10 records.</p>
<p>What are the different objects that you cannot copy or reference in object groups?<br />
Objects of different modules<br />
Another object groups<br />
Individual block dependent items<br />
Program units.</p>
<p>What is an OLE?<br />
Object Linking &amp; Embedding provides you with the capability to integrate objects from many Ms-Windows applications into a</p>
<p>single compound document creating integrated applications enables you to use the features form .</p>
<p>Can a repeating frame be created without a data group as a base?<br />
No</p>
<p>Is it possible to set a filter condition in a cross product group in matrix reports?<br />
No</p>
<p>What is Overloading of procedures ?<br />
The Same procedure name is repeated with parameters of different datatypes and parameters in different positions, varying</p>
<p>number of parameters is called overloading of procedures. e.g. DBMS_OUTPUT put_line</p>
<p>What are the return values of functions SQLCODE and SQLERRM ? What is Pragma EXECPTION_INIT ? Explain the usage ?<br />
SQLCODE returns the latest code of the error that has occurred.<br />
SQLERRM returns the relevant error message of the SQLCODE.</p>
<p>What are the datatypes a available in PL/SQL ?<br />
Some scalar data types such as NUMBER, VARCHAR2, DATE, CHAR, LONG, BOOLEAN. Some composite data types such as RECORD &amp; TABLE.</p>
<p>What are the two parts of a procedure ?<br />
Procedure Specification and Procedure Body.</p>
<p>What is the basic structure of PL/SQL ?<br />
PL/SQL uses block structure as its basic structure. Anonymous blocks or nested blocks can be used in PL/SQL</p>
<p>What is PL/SQL table ?<br />
Objects of type TABLE are called “PL/SQL tables”, which are modeled as (but not the same as) database tables, PL/SQL tables</p>
<p>use a primary PL/SQL tables can have one column and a primary key. Cursors</p>
<p>WHAT IS RMAN ? (for DBA)<br />
Recovery Manager is a tool that: manages the process of creating backups and also manages the process of restoring and</p>
<p>recovering from them.</p>
<p>WHY USE RMAN ? (for DBA)<br />
No extra costs …Its available free<br />
?RMAN introduced in Oracle 8 it has become simpler with newer versions and easier than user managed backups<br />
?Proper security<br />
?You are 100% sure your database has been backed up.<br />
?Its contains detail of the backups taken etc in its central repository<br />
Facility for testing validity of backups also commands like crosscheck to check the status of backup.<br />
Faster backups and restores compared to backups without RMAN<br />
RMAN is the only backup tool which supports incremental backups.<br />
Oracle 10g has got further optimized incremental backup which has resulted in improvement of performance during backup and</p>
<p>recovery time<br />
Parallel operations are supported<br />
Better querying facility for knowing different details of backup<br />
No extra redo generated when backup is taken..compared to online<br />
backup without RMAN which results in saving of space in hard disk<br />
RMAN an intelligent tool<br />
Maintains repository of backup metadata<br />
Remembers backup set location<br />
Knows what need to backed up<br />
Knows what is required for recovery<br />
Knows what backups are redundant</p>
<p>UNDERSTANDING THE RMAN ARCHITECTURE<br />
An oracle RMAN comprises of<br />
RMAN EXECUTABLE This could be present and fired even through client side<br />
TARGET DATABASE This is the database which needs to be backed up .<br />
RECOVERY CATALOG Recovery catalog is optional otherwise backup details are stored in target database controlfile .<br />
It is a repository of information queried and updated by Recovery Manager<br />
It is a schema or user stored in Oracle database. One schema can support many databases<br />
It contains information about physical schema of target database datafile and archive log ,backup sets and pieces Recovery</p>
<p>catalog is a must in following scenarios<br />
. In order to store scripts<br />
. For tablespace point in time recovery</p>
<p>Media Management Software<br />
Media Management software is a must if you are using RMAN for storing backup in tape drive directly.</p>
<p>Backups in RMAN<br />
Oracle backups in RMAN are of the following type<br />
RMAN complete backup OR RMAN incremental backup<br />
These backups are of RMAN proprietary nature</p>
<p>IMAGE COPY<br />
The advantage of uing Image copy is its not in RMAN proprietary format..</p>
<p>Backup Format<br />
RMAN backup is not in oracle format but in RMAN format. Oracle backup comprises of backup sets and it consists of backup</p>
<p>pieces. Backup sets are logical entity In oracle 9i it gets stored in a default location There are two type of backup sets</p>
<p>Datafile backup sets, Archivelog backup sets One more important point of data file backup sets is it do not include empty</p>
<p>blocks. A backup set would contain many backup pieces.<br />
A single backup piece consists of physical files which are in RMAN proprietary format.</p>
<p>Example of taking backup using RMAN<br />
Taking RMAN Backup<br />
In non archive mode in dos prompt type<br />
RMAN<br />
You get the RMAN prompt<br />
RMAN &gt; Connect Target<br />
Connect to target database : Magic<br />
using target database controlfile instead of recovery catalog</p>
<p>Lets take a simple backup of database in non archive mode<br />
shutdown immediate ; – &#8211; Shutdowns the database<br />
startup mount<br />
backup database ;- its start backing the database<br />
alter database open;<br />
We can fire the same command in archive log mode<br />
And whole of datafiles will be backed<br />
Backup database plus archivelog;</p>
<p>Restoring database<br />
Restoring database has been made very simple in 9i .<br />
It is just<br />
Restore database..<br />
RMAN has become intelligent to identify which datafiles has to be restored<br />
and the location of backuped up file.</p>
<p>Oracle Enhancement for RMAN in 10 G</p>
<p>Flash Recovery Area<br />
Right now the price of hard disk is falling. Many dba are taking oracle database backup inside the hard disk itself since it</p>
<p>results in lesser mean time between recoverability.<br />
The new parameter introduced is<br />
DB_RECOVERY_FILE_DEST = /oracle/flash_recovery_area<br />
By configuring the RMAN RETENTION POLICY the flash recovery area will automatically delete obsolete backups and archive logs</p>
<p>that are no longer required based on that configuration Oracle has introduced new features in incremental backup</p>
<p>Change Tracking File<br />
Oracle 10g has the facility to deliver faster incrementals with the implementation of changed tracking file feature.This will</p>
<p>results in faster backups lesser space consumption and also reduces the time needed for daily backups</p>
<p>Incrementally Updated Backups<br />
Oracle database 10g Incrementally Updates Backup features merges the image copy of a datafile with RMAN incremental backup.</p>
<p>The resulting image copy is now updated with block changes captured by incremental backups.The merging of the image copy and</p>
<p>incremental backup is initiated with RMAN recover command. This results in faster recovery.</p>
<p>Binary compression technique reduces backup space usage by 50-75%.</p>
<p>With the new DURATION option for the RMAN BACKUP command, DBAs can weigh backup performance against system service level</p>
<p>requirements. By specifying a duration, RMAN will automatically calculate the appropriate backup rate; in addition, DBAs can</p>
<p>optionally specify whether backups should minimize time or system load.</p>
<p>New Features in Oem to identify RMAN related backup like backup pieces, backup sets and image copy</p>
<p>Oracle 9i New features Persistent RMAN Configuration<br />
A new configure command has been introduced in Oracle 9i , that lets you configure various features including automatic</p>
<p>channels, parallelism ,backup options, etc.<br />
These automatic allocations and options can be overridden by commands in a RMAN command file.</p>
<p>Controlfile Auto backups<br />
Through this new feature RMAN will automatically perform a controlfile auto backup. after every backup or copy command.</p>
<p>Block Media Recovery<br />
If we can restore a few blocks rather than an entire file we only need few blocks.<br />
We even dont need to bring the data file offline.<br />
Syntax for it as follows<br />
Block Recover datafile 8 block 22;</p>
<p>Configure Backup Optimization<br />
Prior to 9i whenever we backed up database using RMAN our backup also used take backup of read only table spaces which had</p>
<p>already been backed up and also the same with archive log too.<br />
Now with 9i backup optimization parameter we can prevent repeat backup of read only tablespace and archive log. The command</p>
<p>for this is as follows Configure backup optimization on</p>
<p>Archive Log failover<br />
If RMAN cannot read a block in an archived log from a destination. RMAN automatically attempts to read from an alternate</p>
<p>location this is called as archive log failover</p>
<p>There are additional commands like<br />
backup database not backed up since time ’31-jan-2002 14:00:00′<br />
Do not backup previously backed up files<br />
(say a previous backup failed and you want to restart from where it left off).<br />
Similar syntax is supported for restores<br />
backup device sbt backup set all Copy a disk backup to tape<br />
(backing up a backup<br />
Additionally it supports<br />
. Backup of server parameter file<br />
. Parallel operation supported<br />
. Extensive reporting available<br />
. Scripting<br />
. Duplex backup sets<br />
. Corrupt block detection<br />
. Backup archive logs</p>
<p>Pitfalls of using RMAN<br />
Previous to version Oracle 9i backups were not that easy which means you had to allocate a channel compulsorily to take</p>
<p>backup You had to give a run etc . The syntax was a bit complex …RMAN has now become very simple and easy to use..<br />
If you changed the location of backup set it is compulsory for you to register it using RMAN or while you are trying to</p>
<p>restore backup It resulted in hanging situations<br />
There is no method to know whether during recovery database restore is going to fail because of missing archive log file.<br />
Compulsory Media Management only if using tape backup<br />
Incremental backups though used to consume less space used to be slower since it used to read the entire database to find the</p>
<p>changed blocks and also They have difficult time streaming the tape device. .<br />
Considerable improvement has been made in 10g to optimize the algorithm to handle changed block.</p>
<p>Observation<br />
Introduced in Oracle 8 it has become more powerful and simpler with newer version of Oracle 9 and 10 g.<br />
So if you really don’t want to miss something critical please start using RMAN.</p>
<p>Explain UNION,MINUS,UNION ALL, INTERSECT ?<br />
INTERSECT returns all distinct rows selected by both queries.MINUS – returns all distinct rows selected by the first query</p>
<p>but not by the second.UNION – returns all distinct rows selected by either queryUNION ALL – returns all rows selected by</p>
<p>either query, including all duplicates.</p>
<p>Should the OEM Console be displayed at all times (when there are scheduled jobs)? (for DBA)<br />
When a job is submitted the agent will confirm the status of the job. When the status shows up as scheduled, you can close</p>
<p>down the OEM console. The processing of the job is managed by the OIA (Oracle Intelligent Agent). The OIA maintains a .jou</p>
<p>file in the agent’s subdirectory. When the console is launched communication with the Agent is established and the contents</p>
<p>of the .jou file (binary) are reported to the console job subsystem. Note that OEM will not be able to send e-mail and paging</p>
<p>notifications when the Console is not started.</p>
<p>Difference between SUBSTR and INSTR ?<br />
INSTR (String1,String2(n,(m)),INSTR returns the position of the mth occurrence of the string 2 instring1. The search begins</p>
<p>from nth position of string1.SUBSTR (String1 n,m)SUBSTR returns a character string of size m in string1, starting from nth</p>
<p>position of string1.</p>
<p>What kind of jobs can one schedule with OEM? (for DBA)<br />
OEM comes with pre-defined jobs like Export, Import, run OS commands, run sql scripts, SQL*Plus commands etc. It also gives</p>
<p>you the flexibility of scheduling custom jobs written with the TCL language.</p>
<p>What are the pre requisites ?<br />
I. to modify data type of a column ? ii. to add a column with NOT NULL constraint ? To Modify the datatype of a column the</p>
<p>column must be empty. to add a column with NOT NULL constrain, the table must be empty.</p>
<p>How does one backout events and jobs during maintenance slots? (for DBA)<br />
Managemnet and data collection activity can be suspended by imposing a blackout. Look at these examples:<br />
agentctl start blackout # Blackout the entrire agent<br />
agentctl stop blackout # Resume normal monitoring and management<br />
agentctl start blackout ORCL # Blackout database ORCL<br />
agentctl stop blackout ORCL # Resume normal monitoring and management<br />
agentctl start blackout -s jobs -d 00:20 # Blackout jobs for 20 minutes</p>
<p>What are the types of SQL Statement ?<br />
Data Definition Language :<br />
CREATE,ALTER,DROP,TRUNCATE,REVOKE,NO AUDIT &amp; COMMIT.</p>
<p>Data Manipulation Language:<br />
INSERT,UPDATE,DELETE,LOCK</p>
<p>TABLE,EXPLAIN PLAN &amp; SELECT.Transactional Control:<br />
COMMIT &amp; ROLLBACKSession Control: ALTERSESSION &amp; SET</p>
<p>ROLESystem Control :<br />
ALTER SYSTEM.</p>
<p>What is the Oracle Intelligent Agent? (for DBA)<br />
The Oracle Intelligent Agent (OIA) is an autonomous process that needs to run on a remote node in the network to make the</p>
<p>node OEM manageable. The Oracle Intelligent Agent is responsible for:<br />
. Discovering targets that can be managed (Database Servers, Net8 Listeners, etc.);<br />
. Monitoring of events registered in Enterprise Manager; and<br />
. Executing tasks associated with jobs submitted to Enterprise Manager.</p>
<p>How does one start the Oracle Intelligent Agent? (for DBA)<br />
One needs to start an OIA (Oracle Intelligent Agent) process on all machines that will to be managed via OEM.<br />
For OEM 9i and above:<br />
agentctl start agent<br />
agentctl stop agent</p>
<p>For OEM 2.1 and below:<br />
lsnrctl dbsnmp_start<br />
lsnrctl dbsnmp_status</p>
<p>On Windows NT, start the “OracleAgent” Service.<br />
If the agent doesn’t want to start, ensure your environment variables are set correctly and delete the following files before</p>
<p>trying again:<br />
1) In $ORACLE_HOME/network/admin: snmp_ro.ora and snmp_rw.ora.<br />
2) Also delete ALL files in $ORACLE_HOME/network/agent/.</p>
<p>Can one write scripts to send alert messages to the console?<br />
Start the OEM console and create a new event. Select option “Enable Unsolicited Event”. Select test “Unsolicited Event”. When</p>
<p>entering the parameters, enter values similar to these:<br />
Event Name: /oracle/script/myalert<br />
Object: *<br />
Severity: *<br />
Message: *<br />
One can now write the script and invoke the oemevent command to send alerts to the console. Look at this example: oemevent</p>
<p>/oracle/script/myalert DESTINATION alert “My custom error message” where DESTINATION is the same value as entered in the</p>
<p>“Monitored Destinations” field when you’ve registered the event in the OEM Console.</p>
<p>Where can one get more information about TCL? (for DBA)<br />
One can write custom event checking routines for OEM using the TCL (Tool Command Language) language. Check the following</p>
<p>sites for more information about TCL:<br />
. The Tcl Developer Xchange – download and learn about TCL<br />
. OraTCL at Sourceforge – Download the OraTCL package<br />
. Tom Poindexter’s Tcl Page – Oratcl was originally written by Tom Poindexter</p>
<p>Are there any troubleshooting tips for OEM? (for DBA)<br />
. Create the OEM repository with a user (which will manage the OEM) and store it in a tablespace that does not share any data</p>
<p>with other database users. It is a bad practice to create the repository with SYS and System.<br />
. If you are unable to launch the console or there is a communication problem with the intelligent agent (daemon). Ensure OCX</p>
<p>files are registered. Type the following in the DOS prompt (the current directory should be $ORACLE_HOME\BIN:<br />
C:\Orawin95\Bin&gt; RegSvr32 mmdx32.OCX<br />
C:\Orawin95\Bin&gt; RegSvr32 vojt.OCX<br />
. If you have a problem starting the Oracle Agent<br />
Solution A: Backup the *.Q files and Delete all the *.Q Files ($Oracle_home/network/agent folder)<br />
Backup and delete SNMP_RO.ora, SNMP_RW.ora, dbsnmp.ver and services.ora files ($Oracle_Home/network/admin folder) Start the</p>
<p>Oracle Agent service.<br />
Solution B: Your version of Intelligent Agent could be buggy. Check with Oracle for any available patches. For example, the</p>
<p>Intelligent Agent that comes with Oracle 8.0.4 is buggy.<br />
Sometimes you get a Failed status for the job that was executed successfully.<br />
Check the log to see the results of the execution rather than relying on this status.</p>
<p>What is import/export and why does one need it? (for DBA)<br />
The Oracle export (EXP) and import (IMP) utilities are used to perform logical database backup and recovery. They are also</p>
<p>used to move Oracle data from one machine, database or schema to another.<br />
The imp/exp utilities use an Oracle proprietary binary file format and can thus only be used between Oracle databases. One</p>
<p>cannot export data and expect to import it into a non-Oracle database. For more information on how to load and unload data</p>
<p>from files, read the SQL*Loader FAQ.<br />
The export/import utilities are also commonly used to perform the following tasks:<br />
. Backup and recovery (small databases only)<br />
. Reorganization of data/ Eliminate database fragmentation<br />
. Detect database corruption. Ensure that all the data can be read.<br />
. Transporting tablespaces between databases<br />
. Etc.</p>
<p>What is a display item?<br />
Display items are similar to text items but store only fetched or assigned values. Operators cannot navigate to a display</p>
<p>item or edit the value it contains.</p>
<p>How does one use the import/export utilities? (for DBA)<br />
Look for the “imp” and “exp” executables in your $ORACLE_HOME/bin directory. One can run them interactively, using command</p>
<p>line parameters, or using parameter files. Look at the imp/exp parameters before starting. These parameters can be listed by</p>
<p>executing the following commands: “exp help=yes” or “imp help=yes”.<br />
The following examples demonstrate how the imp/exp utilities can be used:<br />
exp scott/tiger file=emp.dmp log=emp.log tables=emp rows=yes indexes=no<br />
exp scott/tiger file=emp.dmp tables=(emp,dept)<br />
imp scott/tiger file=emp.dmp full=yes<br />
imp scott/tiger file=emp.dmp fromuser=scott touser=scott tables=dept<br />
exp userid=scott/tiger@orcl parfile=export.txt<br />
… where export.txt contains:<br />
BUFFER=100000<br />
FILE=account.dmp<br />
FULL=n<br />
OWNER=scott<br />
GRANTS=y<br />
COMPRESS=y<br />
NOTE: If you do not like command line utilities, you can import and export data with the “Schema Manager” GUI that ships with</p>
<p>Oracle Enterprise Manager (OEM).</p>
<p>What are the types of visual attribute settings?<br />
Custom Visual attributes Default visual attributes Named Visual attributes. Window</p>
<p>Can one export a subset of a table? (for DBA)<br />
From Oracle8i one can use the QUERY= export parameter to selectively unload a subset of the data from a table. Look at this</p>
<p>example:<br />
exp scott/tiger tables=emp query=\”where deptno=10\”</p>
<p>What are the two ways to incorporate images into a oracle forms application?<br />
Boilerplate Images<br />
Image_items</p>
<p>Can one monitor how fast a table is imported? (for DBA)<br />
If you need to monitor how fast rows are imported from a running import job, try one of the following methods:<br />
Method 1:<br />
select substr(sql_text,instr(sql_text,’INTO “‘),30) table_name,<br />
rows_processed,<br />
round((sysdate-to_date(first_load_time,’yyyy-mm-dd hh24:mi:ss’))*24*60,1) minutes,<br />
trunc(rows_processed/((sysdate-to_date(first_load_time,’yyyy-mm-dd hh24:mi:ss’))*24*60)) rows_per_min<br />
from sys.v_$sqlarea<br />
where sql_text like ‘INSERT %INTO “%’<br />
and command_type = 2<br />
and open_versions &gt; 0;<br />
For this to work one needs to be on Oracle 7.3 or higher (7.2 might also be OK). If the import has more than one table, this</p>
<p>statement will only show information about the current table being imported.<br />
Contributed by Osvaldo Ancarola, Bs. As. Argentina.<br />
Method 2:<br />
Use the FEEDBACK=n import parameter. This command will tell IMP to display a dot for every N rows imported.</p>
<p>Can one import tables to a different tablespace? (for DBA)<br />
Oracle offers no parameter to specify a different tablespace to import data into. Objects will be re-created in the</p>
<p>tablespace they were originally exported from. One can alter this behaviour by following one of these procedures: Pre-create</p>
<p>the table(s) in the correct tablespace:<br />
. Import the dump file using the INDEXFILE= option<br />
. Edit the indexfile. Remove remarks and specify the correct tablespaces.<br />
. Run this indexfile against your database, this will create the required tables in the appropriate tablespaces<br />
. Import the table(s) with the IGNORE=Y option.<br />
Change the default tablespace for the user:</p>
<p>. Revoke the “UNLIMITED TABLESPACE” privilege from the user<br />
. Revoke the user’s quota from the tablespace from where the object was exported. This forces the import utility to create</p>
<p>tables in the user’s default tablespace.<br />
. Make the tablespace to which you want to import the default tablespace for the user<br />
. Import the table</p>
<p>What do you mean by a block in forms4.0?<br />
Block is a single mechanism for grouping related items into a functional unit for storing, displaying and manipulating</p>
<p>records.</p>
<p>How is possible to restrict the user to a list of values while entering values for parameters?<br />
By setting the Restrict To List property to true in the parameter property sheet.</p>
<p>What is SQL*Loader and what is it used for? (for DBA)<br />
SQL*Loader is a bulk loader utility used for moving data from external files into the Oracle database. Its syntax is similar</p>
<p>to that of the DB2 Load utility, but comes with more options. SQL*Loader supports various load formats, selective loading,</p>
<p>and multi-table loads.</p>
<p>How does one use the SQL*Loader utility? (for DBA)<br />
One can load data into an Oracle database by using the sqlldr (sqlload on some platforms) utility. Invoke the utility without</p>
<p>arguments to get a list of available parameters. Look at the following example:<br />
sqlldr scott/tiger control=loader.ctl<br />
This sample control file (loader.ctl) will load an external data file containing delimited data:<br />
load data<br />
infile ‘c:\data\mydata.csv’<br />
into table emp<br />
fields terminated by “,” optionally enclosed by ‘”‘<br />
( empno, empname, sal, deptno )<br />
The mydata.csv file may look like this:<br />
10001,”Scott Tiger”, 1000, 40<br />
10002,”Frank Naude”, 500, 20<br />
Another Sample control file with in-line data formatted as fix length records. The trick is to specify “*” as the name of the</p>
<p>data file, and use BEGINDATA to start the data section in the control file.<br />
load data<br />
infile *<br />
replace<br />
into table departments<br />
( dept position (02:05) char(4),<br />
deptname position (08:27) char(20)<br />
)<br />
begindata<br />
COSC COMPUTER SCIENCE<br />
ENGL ENGLISH LITERATURE<br />
MATH MATHEMATICS<br />
POLY POLITICAL SCIENCE</p>
<p>How can a cross product be created?<br />
By selecting the cross products tool and drawing a new group surrounding the base group of the cross products.</p>
<p>Is there a SQL*Unloader to download data to a flat file? (for DBA)<br />
Oracle does not supply any data unload utilities. However, you can use SQL*Plus to select and format your data and then spool</p>
<p>it to a file:<br />
set echo off newpage 0 space 0 pagesize 0 feed off head off trimspool on<br />
spool oradata.txt<br />
select col1 || ‘,’ || col2 || ‘,’ || col3<br />
from tab1<br />
where col2 = ‘XYZ’;<br />
spool off<br />
Alternatively use the UTL_FILE PL/SQL package:<br />
rem Remember to update initSID.ora, utl_file_dir=’c:\oradata’ parameter<br />
declare<br />
fp utl_file.file_type;<br />
begin<br />
fp := utl_file.fopen(‘c:\oradata’,&#8217;tab1.txt’,&#8217;w’);<br />
utl_file.putf(fp, ‘%s, %s\n’, ‘TextField’, 55);<br />
utl_file.fclose(fp);<br />
end;<br />
/<br />
You might also want to investigate third party tools like SQLWays from Ispirer Systems, TOAD from Quest, or ManageIT Fast</p>
<p>Unloader from CA to help you unload data from Oracle.</p>
<p>Can one load variable and fix length data records? (for DBA)<br />
Yes, look at the following control file examples. In the first we will load delimited data (variable length):<br />
LOAD DATA<br />
INFILE *<br />
INTO TABLE load_delimited_data<br />
FIELDS TERMINATED BY “,” OPTIONALLY ENCLOSED BY ‘”‘<br />
TRAILING NULLCOLS<br />
( data1,<br />
data2<br />
)<br />
BEGINDATA<br />
11111,AAAAAAAAAA<br />
22222,”A,B,C,D,”<br />
If you need to load positional data (fixed length), look at the following control file example:<br />
LOAD DATA<br />
INFILE *<br />
INTO TABLE load_positional_data<br />
( data1 POSITION(1:5),<br />
data2 POSITION(6:15)<br />
)<br />
BEGINDATA<br />
11111AAAAAAAAAA<br />
22222BBBBBBBBBB<br />
Can one skip header records load while loading?<br />
Use the “SKIP n” keyword, where n = number of logical rows to skip. Look at this example:<br />
LOAD DATA<br />
INFILE *<br />
INTO TABLE load_positional_data<br />
SKIP 5<br />
( data1 POSITION(1:5),<br />
data2 POSITION(6:15)<br />
)<br />
BEGINDATA<br />
11111AAAAAAAAAA<br />
22222BBBBBBBBBB</p>
<p>Can one modify data as it loads into the database? (for DBA)<br />
Data can be modified as it loads into the Oracle Database. Note that this only applies for the conventional load path and not</p>
<p>for direct path loads.<br />
LOAD DATA<br />
INFILE *<br />
INTO TABLE modified_data<br />
( rec_no “my_db_sequence.nextval”,<br />
region CONSTANT ’31′,<br />
time_loaded “to_char(SYSDATE, ‘HH24:MI’)”,<br />
data1 POSITION(1:5) “:data1/100″,<br />
data2 POSITION(6:15) “upper(:data2)”,<br />
data3 POSITION(16:22)”to_date(:data3, ‘YYMMDD’)”<br />
)<br />
BEGINDATA<br />
11111AAAAAAAAAA991201<br />
22222BBBBBBBBBB990112<br />
LOAD DATA<br />
INFILE ‘mail_orders.txt’<br />
BADFILE ‘bad_orders.txt’<br />
APPEND<br />
INTO TABLE mailing_list<br />
FIELDS TERMINATED BY “,”<br />
( addr,<br />
city,<br />
state,<br />
zipcode,<br />
mailing_addr “decode(:mailing_addr, null, :addr, :mailing_addr)”,<br />
mailing_city “decode(:mailing_city, null, :city, :mailing_city)”,<br />
mailing_state<br />
)</p>
<p>Can one load data into multiple tables at once? (for DBA)<br />
Look at the following control file:<br />
LOAD DATA<br />
INFILE *<br />
REPLACE<br />
INTO TABLE emp<br />
WHEN empno != ‘ ‘<br />
( empno POSITION(1:4) INTEGER EXTERNAL,<br />
ename POSITION(6:15) CHAR,<br />
deptno POSITION(17:18) CHAR,<br />
mgr POSITION(20:23) INTEGER EXTERNAL<br />
)<br />
INTO TABLE proj<br />
WHEN projno != ‘ ‘<br />
( projno POSITION(25:27) INTEGER EXTERNAL,<br />
empno POSITION(1:4) INTEGER EXTERNAL<br />
)</p>
<p>What is the difference between boiler plat images and image items?<br />
Boiler plate Images are static images (Either vector or bit map) that you import from the file system or database to use a</p>
<p>graphical elements in your form, such as company logos and maps. Image items are special types of interface controls that</p>
<p>store and display either vector or bitmap images. Like other items that store values, image items can be either base table</p>
<p>items(items that relate directly to database columns) or control items. The definition of an image item is stored as part of</p>
<p>the form module FMB and FMX files, but no image file is actually associated with an image item until the item is populate at</p>
<p>run time.</p>
<p>What are the triggers available in the reports?<br />
Before report, Before form, After form , Between page, After report.</p>
<p>Why is a Where clause faster than a group filter or a format trigger?<br />
Because, in a where clause the condition is applied during data retrievalthan after retrieving the data.</p>
<p>Can one selectively load only the records that one need? (for DBA)<br />
Look at this example, (01) is the first character, (30:37) are characters 30 to 37:<br />
LOAD DATA<br />
INFILE ‘mydata.dat’ BADFILE ‘mydata.bad’ DISCARDFILE ‘mydata.dis’<br />
APPEND<br />
INTO TABLE my_selective_table<br />
WHEN (01) &lt;&gt; ‘H’ and (01) &lt;&gt; ‘T’ and (30:37) = ’19991217′<br />
(<br />
region CONSTANT ’31′,<br />
service_key POSITION(01:11) INTEGER EXTERNAL,<br />
call_b_no POSITION(12:29) CHAR<br />
)</p>
<p>Can one skip certain columns while loading data? (for DBA)<br />
One cannot use POSTION(x:y) with delimited data. Luckily, from Oracle 8i one can specify FILLER columns. FILLER columns are</p>
<p>used to skip columns/fields in the load file, ignoring fields that one does not want. Look at this example: — One cannot use</p>
<p>POSTION(x:y) as it is stream data, there are no positional fields-the next field begins after some delimiter, not in column</p>
<p>X. –&gt;<br />
LOAD DATA<br />
TRUNCATE INTO TABLE T1<br />
FIELDS TERMINATED BY ‘,’<br />
( field1,<br />
field2 FILLER,<br />
field3<br />
)</p>
<p>How does one load multi-line records? (for DBA)<br />
One can create one logical record from multiple physical records using one of the following two clauses:<br />
. CONCATENATE: – use when SQL*Loader should combine the same number of physical records together to form one logical record.<br />
. CONTINUEIF – use if a condition indicates that multiple records should be treated as one. Eg. by having a ‘#’ character in</p>
<p>column 1.</p>
<p>How can get SQL*Loader to COMMIT only at the end of the load file? (for DBA)<br />
One cannot, but by setting the ROWS= parameter to a large value, committing can be reduced. Make sure you have big rollback</p>
<p>segments ready when you use a high value for ROWS=.</p>
<p>Can one improve the performance of SQL*Loader? (for DBA)<br />
A very simple but easily overlooked hint is not to have any indexes and/or constraints (primary key) on your load tables</p>
<p>during the load process. This will significantly slow down load times even with ROWS= set to a high value.<br />
Add the following option in the command line: DIRECT=TRUE. This will effectively bypass most of the RDBMS processing.</p>
<p>Turn off database logging by specifying the UNRECOVERABLE option. This option can only be used with direct data loads. Run multiple load jobs concurrently.</p>
<p>How does one use SQL*Loader to load images, sound clips and documents? (for DBA) SQL*Loader can load data from a “primary data file”, SDF (Secondary Data file – for loading nested tables and VARRAYs) or LOGFILE. The LOBFILE method provides and easy way to load documents, images and audio clips into BLOB and CLOB columns.</p>
<p>What is the difference between the conventional and direct path loader? (for DBA)</p>
<p>The conventional path loader essentially loads the data by using standard INSERT statements. The direct path loader (DIRECT=TRUE) bypasses much of the logic involved with that, and loads directly into the Oracle data files. More information about the restrictions of direct path loading can be obtained from the Utilities Users Guide.</p>
<p>What are the various types of Exceptions ?<br />
User defined and Predefined Exceptions.</p>
<p>Can we define exceptions twice in same block ?<br />
No.</p>
<p>What is the difference between a procedure and a function ?</p>
<p>Functions return a single variable by value whereas procedures do not return any variable by value. Rather they return multiple variables by passing variables by reference through their OUT parameter.</p>
<p>Can you have two functions with the same name in a PL/SQL block ?<br />
Yes.</p>
<p>Can you have two stored functions with the same name ?<br />
Yes.</p>
<p>Can you call a stored function in the constraint of a table ?<br />
No.</p>
<p>What are the various types of parameter modes in a procedure ?<br />
IN, OUT AND INOUT.</p>
<p>What is Over Loading and what are its restrictions ?</p>
<p>OverLoading means an object performing different functions depending upon the no. of parameters or the data type of the parameters passed to it.</p>
<p>Can functions be overloaded ?<br />
Yes.</p>
<p>Can 2 functions have same name &amp; input parameters but differ only by return datatype ?<br />
No.</p>
<p>What are the constructs of a procedure, function or a package ?<br />
The constructs of a procedure, function or a package are :<br />
variables and constants<br />
cursors<br />
exceptions</p>
<p>Why Create or Replace and not Drop and recreate procedures ?<br />
So that Grants are not dropped.</p>
<p>Can you pass parameters in packages ? How ?<br />
Yes. You can pass parameters to procedures or functions in a package.</p>
<p>What are the parts of a database trigger ?<br />
The parts of a trigger are:<br />
A triggering event or statement<br />
A trigger restriction<br />
A trigger action</p>
<p>What are the various types of database triggers ?<br />
There are 12 types of triggers, they are combination of :<br />
Insert, Delete and Update Triggers.<br />
Before and After Triggers.<br />
Row and Statement Triggers.<br />
(3*2*2=12)</p>
<p>What is the advantage of a stored procedure over a database trigger ?<br />
We have control over the firing of a stored procedure but we have no control over the firing of a trigger.</p>
<p>What is the maximum no. of statements that can be specified in a trigger statement ?<br />
One.</p>
<p>Can views be specified in a trigger statement ?<br />
No</p>
<p>What are the values of :new and <img src='http://www.pdftutorials.com/wp-includes/images/smilies/icon_surprised.gif' alt=':o' class='wp-smiley' />  ld in Insert/Delete/Update Triggers ?<br />
INSERT : new = new value, old = NULL<br />
DELETE : new = NULL, old = old value<br />
UPDATE : new = new value, old = old value</p>
<p>What are cascading triggers? What is the maximum no of cascading triggers at a time?<br />
When a statement in a trigger body causes another trigger to be fired, the triggers are said to be cascading. Max = 32.</p>
<p>What are mutating triggers ?<br />
A trigger giving a SELECT on the table on which the trigger is written.</p>
<p>What are constraining triggers ?<br />
A trigger giving an Insert/Update on a table having referential integrity constraint on the triggering table.</p>
<p>Describe Oracle database’s physical and logical structure ?<br />
Physical : Data files, Redo Log files, Control file.<br />
Logical : Tables, Views, Tablespaces, etc.</p>
<p>Can you increase the size of a tablespace ? How ?<br />
Yes, by adding datafiles to it.</p>
<p>What is the use of Control files ?<br />
Contains pointers to locations of various data files, redo log files, etc.</p>
<p>What is the use of Data Dictionary ?</p>
<p>Used by Oracle to store information about various physical and logical Oracle structures e.g. Tables, Tablespaces, datafiles, etc</p>
<p>What are the advantages of clusters ?<br />
Access time reduced for joins.</p>
<p>What are the disadvantages of clusters ?<br />
The time for Insert increases.</p>
<p>Can Long/Long RAW be clustered ?<br />
No.</p>
<p>Can null keys be entered in cluster index, normal index ?<br />
Yes.</p>
<p>Can Check constraint be used for self referential integrity ? How ?</p>
<p>Yes. In the CHECK condition for a column of a table, we can reference some other column of the same table and thus enforce self referential integrity.</p>
<p>What are the min. extents allocated to a rollback extent ?<br />
Two</p>
<p>What are the states of a rollback segment ? What is the difference between partly available and needs recovery ?<br />
The various states of a rollback segment are :<br />
ONLINE, OFFLINE, PARTLY AVAILABLE, NEEDS RECOVERY and INVALID.</p>
<p>What is the difference between unique key and primary key ?<br />
Unique key can be null; Primary key cannot be null.</p>
<p>An insert statement followed by a create table statement followed by rollback ? Will the rows be inserted ?<br />
No.</p>
<p>an you define multiple savepoints ?<br />
Yes.</p>
<p>Can you Rollback to any savepoint ?<br />
Yes.</p>
<p>What is the maximum no. of columns a table can have ?<br />
254.</p>
<p>What is the significance of the &amp; and &amp;&amp; operators in PL SQL ?</p>
<p>The &amp; operator means that the PL SQL block requires user input for a variable. The &amp;&amp; operator means that the value of this variable should be the same as inputted by the user previously for this same variable. If a transaction is very large, and the rollback segment is not able to hold the rollback information, then will the transaction span across different rollback segments or will it terminate ? It will terminate (Please check ).</p>
<p>Can you pass a parameter to a cursor ?</p>
<p>Explicit cursors can take parameters, as the example below shows. A cursor parameter can appear in a query wherever a constant can appear. CURSOR c1 (median IN NUMBER) IS SELECT job, ename FROM emp WHERE sal &gt; median;</p>
<p>What are the various types of RollBack Segments ?<br />
Public Available to all instances<br />
Private Available to specific instance</p>
<p>Can you use %RowCount as a parameter to a cursor ?<br />
Yes</p>
<p>Is the query below allowed :<br />
Select sal, ename Into x From emp Where ename = ‘KING’<br />
(Where x is a record of Number(4) and Char(15))<br />
Yes</p>
<p>Is the assignment given below allowed :<br />
ABC = PQR (Where ABC and PQR are records)<br />
Yes</p>
<p>Is this for loop allowed :<br />
For x in &amp;Start..&amp;End Loop<br />
Yes</p>
<p>How many rows will the following SQL return :<br />
Select * from emp Where rownum &lt; 10;<br />
9 rows</p>
<p>How many rows will the following SQL return :<br />
Select * from emp Where rownum = 10;<br />
No rows</p>
<p>Which symbol preceeds the path to the table in the remote database ?<br />
@</p>
<p>Are views automatically updated when base tables are updated ?<br />
Yes</p>
<p>Can a trigger written for a view ?<br />
No</p>
<p>If all the values from a cursor have been fetched and another fetch is issued, the output will be : error, last record or</p>
<p>first record ?<br />
Last Record</p>
<p>A table has the following data : [[5, Null, 10]]. What will the average function return ?<br />
7.5</p>
<p>Is Sysdate a system variable or a system function?<br />
System Function</p>
<p>Consider a sequence whose currval is 1 and gets incremented by 1 by using the nextval reference we get the next number 2. Suppose at this point we issue an rollback and again issue a nextval. What will the output be ?<br />
3</p>
<p>Definition of relational DataBase by Dr. Codd (IBM)?</p>
<p>A Relational Database is a database where all data visible to the user is organized strictly as tables of data values and where all database operations work on these tables.</p>
<p>What is Multi Threaded Server (MTA) ?</p>
<p>In a Single Threaded Architecture (or a dedicated server configuration) the database manager creates a separate process for each database user. But in MTA the database manager can assign multiple users (multiple user processes) to a single dispatcher (server process), a controlling process that queues request for work thus reducing the databases memory requirement and resources.</p>
<p>Which are initial RDBMS, Hierarchical &amp; N/w database ?<br />
RDBMS – R system<br />
Hierarchical – IMS<br />
N/W – DBTG</p>
<p>What is Functional Dependency</p>
<p>Given a relation R, attribute Y of R is functionally dependent on attribute X of R if and only if each X-value has associated with it precisely one -Y value in R</p>
<p>What is Auditing ?<br />
The database has the ability to audit all actions that take place within it.<br />
a) Login attempts, b) Object Accesss, c) Database Action Result of Greatest(1,NULL) or Least(1,NULL) NULL</p>
<p>While designing in client/server what are the 2 imp. things to be considered ?<br />
Network Overhead (traffic), Speed and Load of client server</p>
<p>When to create indexes ?<br />
To be created when table is queried for less than 2% or 4% to 25% of the table rows.</p>
<p>How can you avoid indexes ?</p>
<p>TO make index access path unavailable – Use FULL hint to optimizer for full table scan – Use INDEX or AND-EQUAL hint to optimizer to use one index or set to indexes instead of another. – Use an expression in the Where Clause of the SQL.</p>
<p>What is the result of the following SQL :<br />
Select 1 from dual<br />
UNION<br />
Select ‘A’ from dual;<br />
Error</p>
<p>Can database trigger written on synonym of a table and if it can be then what would be the effect if original table is accessed.<br />
Yes, database trigger would fire.</p>
<p>Can you alter synonym of view or view ?<br />
No</p>
<p>Can you create index on view ?<br />
No</p>
<p>What is the difference between a view and a synonym ?</p>
<p>Synonym is just a second name of table used for multiple link of database. View can be created with many tables, and with virtual columns and with conditions. But synonym can be on view.</p>
<p>What is the difference between alias and synonym ?<br />
Alias is temporary and used with one query. Synonym is permanent and not used as alias.</p>
<p>What is the effect of synonym and table name used in same Select statement ?<br />
Valid</p>
<p>What’s the length of SQL integer ?<br />
32 bit length</p>
<p>What is the difference between foreign key and reference key ?</p>
<p>Foreign key is the key i.e. attribute which refers to another table primary key. Reference key is the primary key of table referred by another table. Can dual table be deleted, dropped or altered or updated or inserted ?<br />
Yes</p>
<p>If content of dual is updated to some value computation takes place or not ?<br />
Yes</p>
<p>If any other table same as dual is created would it act similar to dual?<br />
Yes</p>
<p>For which relational operators in where clause, index is not used ?<br />
&lt;&gt; , like ‘% …’ is NOT functions, field +constant, field || ”</p>
<p>Assume that there are multiple databases running on one machine. How can you switch from one to another ?<br />
Changing the ORACLE_SID</p>
<p>What are the advantages of Oracle ?</p>
<p>Portability : Oracle is ported to more platforms than any of its competitors, running on more than 100 hardware platforms and 20 networking protocols. Market Presence : Oracle is by far the largest RDBMS vendor and spends more on R &amp; D than most of its competitors earn in total revenue. This market clout means that you are unlikely to be left in the lurch by Oracle and there are always lots of third party interfaces available. Backup and Recovery : Oracle provides industrial strength support for on-line backup and recovery and good software fault tolerence to disk failure. You can also do point-in-time recovery. Performance : Speed of a ‘tuned’ Oracle Database and application is quite good, even with large databases. Oracle can manage &gt; 100GB databases.</p>
<p>Multiple database support : Oracle has a superior ability to manage multiple databases within the same transaction using a two-phase commit protocol.</p>
<p>What is a forward declaration ? What is its use ?</p>
<p>PL/SQL requires that you declare an identifier before using it. Therefore, you must declare a subprogram before calling it. This declaration at the start of a subprogram is called forward declaration. A forward declaration consists of a subprogram specification terminated by a semicolon.</p>
<p>What are actual and formal parameters ?</p>
<p>Actual Parameters : Subprograms pass information using parameters. The variables or expressions referenced in the parameter list of a subprogram call are actual parameters. For example, the following procedure call lists two actual parameters named</p>
<p>emp_num and amount:<br />
Eg. raise_salary(emp_num, amount);</p>
<p>Formal Parameters : The variables declared in a subprogram specification and referenced in the subprogram body are formal parameters. For example, the following procedure declares two formal parameters named emp_id and increase: Eg. PROCEDURE raise_salary (emp_id INTEGER, increase REAL) IS current_salary REAL;</p>
<p>What are the types of Notation ?<br />
Position, Named, Mixed and Restrictions.</p>
<p>What all important parameters of the init.ora are supposed to be increased if you want to increase the SGA size ?</p>
<p>In our case, db_block_buffers was changed from 60 to 1000 (std values are 60, 550 &amp; 3500) shared_pool_size was changed from 3.5MB to 9MB (std values are 3.5, 5 &amp; 9MB) open_cursors was changed from 200 to 300 (std values are 200 &amp; 300) db_block_size was changed from 2048 (2K) to 4096 (4K) {at the time of database creation}. The initial SGA was around 4MB when the server RAM was 32MB and The new SGA was around 13MB when the server RAM was increased to 128MB.</p>
<p>If I have an execute privilege on a procedure in another users schema, can I execute his procedure even though I do not have privileges on the tables within the procedure ?<br />
Yes</p>
<p>What are various types of joins ?<br />
Equijoins, Non-equijoins, self join, outer join</p>
<p>What is a package cursor ?</p>
<p>A package cursor is a cursor which you declare in the package specification without an SQL statement. The SQL statement for the cursor is attached dynamically at runtime from calling procedures.</p>
<p>If you insert a row in a table, then create another table and then say Rollback. In this case will the row be inserted ?<br />
Yes. Because Create table is a DDL which commits automatically as soon as it is executed. The DDL commits the transaction</p>
<p>even if the create statement fails internally (eg table already exists error) and not syntactically.</p>
<p>What are the various types of queries ??<br />
Normal Queries<br />
Sub Queries<br />
Co-related queries<br />
Nested queries<br />
Compound queries</p>
<p>What is a transaction ?<br />
A transaction is a set of SQL statements between any two COMMIT and ROLLBACK statements.</p>
<p>What is implicit cursor and how is it used by Oracle ?<br />
An implicit cursor is a cursor which is internally created by Oracle. It is created by Oracle for each individual SQL.</p>
<p>Which of the following is not a schema object : Indexes, tables, public synonyms, triggers and packages ?<br />
Public synonyms</p>
<p>What is PL/SQL?</p>
<p>PL/SQL is Oracle’s Procedural Language extension to SQL. The language includes object oriented programming techniques such as encapsulation, function overloading, information hiding (all but inheritance), and so, brings state-of-the-art programming to the Oracle database server and a variety of Oracle tools.</p>
<p>Is there a PL/SQL Engine in SQL*Plus?</p>
<p>No. Unlike Oracle Forms, SQL*Plus does not have a PL/SQL engine. Thus, all your PL/SQL are send directly to the database engine for execution. This makes it much more efficient as SQL statements are not stripped off and send to the database individually.</p>
<p>Is there a limit on the size of a PL/SQL block?</p>
<p>Currently, the maximum parsed/compiled size of a PL/SQL block is 64K and the maximum code size is 100K. You can run the following select statement to query the size of an existing package or procedure.<br />
SQL&gt; select * from dba_object_size where name = ‘procedure_name’</p>
<p>Can one read/write files from PL/SQL?</p>
<p>Included in Oracle 7.3 is a UTL_FILE package that can read and write files. The directory you intend writing to has to be in your INIT.ORA file (see UTL_FILE_DIR=… parameter). Before Oracle 7.3 the only means of writing a file was to use</p>
<p>DBMS_OUTPUT with the SQL*Plus SPOOL command.<br />
DECLARE<br />
fileHandler UTL_FILE.FILE_TYPE;<br />
BEGIN<br />
fileHandler := UTL_FILE.FOPEN(‘/home/oracle/tmp’, ‘myoutput’,&#8217;W’);<br />
UTL_FILE.PUTF(fileHandler, ‘Value of func1 is %sn’, func1(1));<br />
UTL_FILE.FCLOSE(fileHandler);<br />
END;</p>
<p>How can I protect my PL/SQL source code?</p>
<p>PL/SQL V2.2, available with Oracle7.2, implements a binary wrapper for PL/SQL programs to protect the source code. This is done via a standalone utility that transforms the PL/SQL source code into portable binary object code (somewhat larger than the original). This way you can distribute software without having to worry about exposing your proprietary algorithms and methods. SQL*Plus and SQL*DBA will still understand and know how to execute such scripts. Just be careful, there is no “decode” command available.<br />
The syntax is:<br />
wrap iname=myscript.sql oname=xxxx.yyy</p>
<p>Can one use dynamic SQL within PL/SQL? OR Can you use a DDL in a procedure ? How ?<br />
From PL/SQL V2.1 one can use the DBMS_SQL package to execute dynamic SQL statements.<br />
Eg: CREATE OR REPLACE PROCEDURE DYNSQL<br />
AS<br />
cur integer;<br />
rc integer;<br />
BEGIN<br />
cur := DBMS_SQL.OPEN_CURSOR;<br />
DBMS_SQL.PARSE(cur,’CREATE TABLE X (Y DATE)’, DBMS_SQL.NATIVE);<br />
rc := DBMS_SQL.EXECUTE(cur);<br />
DBMS_SQL.CLOSE_CURSOR(cur);<br />
END;</p>
<p>What is the difference between a view and a synonym in Oracle ?</p>
<p>Synonym is just a second name for a table used for multiple link of database.View can be created with many tables, and with virtual columns and with conditions but its not physically stored.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pdftutorials.com/questions/oracle-interview-questions.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>NETWORKING INTERVIEW QUESTIONS</title>
		<link>http://www.pdftutorials.com/questions/networking-interview-questions.html</link>
		<comments>http://www.pdftutorials.com/questions/networking-interview-questions.html#comments</comments>
		<pubDate>Thu, 13 Oct 2011 13:29:03 +0000</pubDate>
		<dc:creator>Tutorial Master</dc:creator>
				<category><![CDATA[questions]]></category>

		<guid isPermaLink="false">http://www.pdftutorials.com/test/?p=3850</guid>
		<description><![CDATA[1. What are 10Base2, 10Base5 and 10BaseT Ethernet LANs 10Base2—An Ethernet term meaning a maximum transfer rate of 10 Megabits per second that uses baseband signaling, with a contiguous cable segment length of 100 meters and a maximum of 2 segments. 10Base5—An Ethernet term meaning a maximum transfer rate of 10 Megabits per second that <a href="http://www.pdftutorials.com/questions/networking-interview-questions.html"> read more <span class="meta-nav">&#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p>1. What are 10Base2, 10Base5 and 10BaseT Ethernet LANs<br />
10Base2—An Ethernet term meaning a maximum transfer rate of 10 Megabits per second that uses baseband<br />
signaling, with a contiguous cable segment length of 100<br />
meters and a maximum of 2 segments.<br />
10Base5—An Ethernet term meaning a maximum transfer rate of 10 Megabits per second that uses baseband<br />
signaling, with 5 continuous segments not exceeding 100<br />
meters per segment.<br />
10BaseT—An Ethernet term meaning a maximum transfer rate of 10 Megabits per second that uses baseband<br />
signaling and twisted pair cabling.</p>
<p>2. Explain the difference between an unspecified passive open and a fully specified passive open<br />
An unspecified passive open has the server waiting for a connection request from a client. A fully specified passive<br />
open has the server waiting for a connection from a<br />
specific client.</p>
<p>3. Explain the function of Transmission Control Block<br />
A TCB is a complex data structure that contains a considerable amount of information about each connection.</p>
<p>4. Explain a Management Information Base (MIB)<br />
A Management Information Base is part of every SNMP-managed device. Each SNMP agent has the MIB database that<br />
contains information about the device’s status, its<br />
performance, connections, and configuration. The MIB is queried by SNMP.</p>
<p>5. Explain anonymous FTP and why would you use it<br />
Anonymous FTP enables users to connect to a host without using a valid login and password. Usually, anonymous FTP<br />
uses a login called anonymous or guest, with the<br />
password usually requesting the user’s ID for tracking purposes only. Anonymous FTP is used to enable a large number<br />
of users to access files on the host without having<br />
to go to the trouble of setting up logins for them all. Anonymous FTP systems usually have strict controls over the areas<br />
an anonymous user can access.</p>
<p>6. Explain a pseudo tty<br />
A pseudo tty or false terminal enables external machines to connect through Telnet or rlogin. Without a pseudo tty, no<br />
connection can take place.</p>
<p>7. Explain REX<br />
What advantage does REX offer other similar utilities</p>
<p>8. What does the Mount protocol do<br />
The Mount protocol returns a file handle and the name of the file system in which a requested file resides. The message<br />
is sent to the client from the server after reception<br />
of a client’s request.</p>
<p>9. Explain External Data Representation<br />
External Data Representation is a method of encoding data within an RPC message, used to ensure that the data is not<br />
system-dependent.<br />
10. Explain the Network Time Protocol ?</p>
<p>11. BOOTP helps a diskless workstation boot. How does it get a message to the network looking for its IP address and the location of its operating system boot files<br />
BOOTP sends a UDP message with a subnetwork broadcast address and waits for a reply from a server that gives it the IP address. The same message might contain the name of the machine that has the boot files on it. If the boot image location is not specified, the workstation sends another UDP message to query the server.</p>
<p>12. Explain a DNS resource record<br />
A resource record is an entry in a name server’s database. There are several types of resource records used, including name-to-address resolution information. Resource records are maintained as ASCII files.</p>
<p>13. What protocol is used by DNS name servers<br />
DNS uses UDP for communication between servers. It is a better choice than TCP because of the improved speed a connectionless protocol offers. Of course, transmission reliability suffers with UDP.</p>
<p>14. Explain the difference between interior and exterior neighbor gateways<br />
Interior gateways connect LANs of one organization, whereas exterior gateways connect the organization to the outside world.</p>
<p>15. Explain the HELLO protocol used for<br />
The HELLO protocol uses time instead of distance to determine optimal routing. It is an alternative to the Routing Information Protocol.</p>
<p>16. What are the advantages and disadvantages of the three types of routing tables<br />
The three types of routing tables are fixed, dynamic, and fixed central. The fixed table must be manually modified every time there is a change. A dynamic table changes its information based on network traffic, reducing the amount of manual maintenance. A fixed central table lets a manager modify only one table, which is then read by other devices. The fixed central table reduces the need to update each machine’s table, as with the fixed table. Usually a dynamic table causes the fewest problems for a network<br />
administrator, although the table’s contents can change without the administrator being aware of the change.</p>
<p>17. Explain a TCP connection table</p>
<p>18. Explain source route<br />
It is a sequence of IP addresses identifying the route a datagram must follow. A source route may<br />
optionally be included in an IP datagram header.</p>
<p>19. Explain RIP (Routing Information Protocol)<br />
It is a simple protocol used to exchange information between the routers.</p>
<p>20. Explain SLIP (Serial Line Interface Protocol)<br />
It is a very simple protocol used for transmission of IP datagrams across a serial line.</p>
<p>21. Explain Proxy ARP<br />
It is using a router to answer ARP requests. This will be done when the originating host believes that a destination is local, when in fact is lies beyond router.</p>
<p>22. Explain OSPF<br />
It is an Internet routing protocol that scales well, can route traffic along multiple paths, and uses knowledge of an Internet’s topology to make accurate routing decisions.</p>
<p>23. Explain Kerberos<br />
It is an authentication service developed at the Massachusetts Institute of Technology. Kerberos uses encryption to prevent intruders from discovering passwords and gaining unauthorized access to files.</p>
<p>24. Explain a Multi-homed Host<br />
It is a host that has a multiple network interfaces and that requires multiple IP addresses is called as a Multi-homed Host.</p>
<p>25. Explain NVT (Network Virtual Terminal)<br />
It is a set of rules defining a very simple virtual terminal interaction. The NVT is used in the start of a Telnet session.<br />
26. Explain Gateway-to-Gateway protocol<br />
It is a protocol formerly used to exchange routing information between Internet core routers.</p>
<p>27. Explain BGP (Border Gateway Protocol)<br />
It is a protocol used to advertise the set of networks that can be reached with in an autonomous system. BGP enables this information to be shared with the autonomous system. This is newer than EGP (Exterior Gateway Protocol).<br />
28. Explain autonomous system<br />
It is a collection of routers under the control of a single administrative authority and that uses a common Interior Gateway Protocol.</p>
<p>29. Explain EGP (Exterior Gateway Protocol)<br />
It is the protocol the routers in neighboring autonomous systems use to identify the set of networks that can be reached<br />
within or via each autonomous system.</p>
<p>30. Explain IGP (Interior Gateway Protocol)<br />
It is any routing protocol used within an autonomous system.</p>
<p>31. Explain Mail Gateway<br />
It is a system that performs a protocol translation between different electronic mail delivery protocols.</p>
<p>32. Explain wide-mouth frog<br />
Wide-mouth frog is the simplest known key distribution center (KDC) authentication protocol.</p>
<p>33. What are Digrams and Trigrams<br />
The most common two letter combinations are called as digrams. e.g. th, in, er, re and an. The most common three letter combinations are called as trigrams. e.g. the, ing, and, and ion.<br />
34. Explain silly window syndrome<br />
It is a problem that can ruin TCP performance. This problem occurs when data are passed to the sending TCP entity in large blocks, but an interactive application on the receiving side reads 1 byte at a time.<br />
35. Explain region<br />
When hierarchical routing is used, the routers are divided into what we call regions, with each router knowing all the details about how to route packets to destinations within its own region, but knowing nothing about the internal structure of other regions.<br />
36. Explain multicast routing<br />
Sending a message to a group is called multicasting, and its routing algorithm is called multicast routing.<br />
37. Explain traffic shaping<br />
One of the main causes of congestion is that traffic is often busy. If hosts could be made to transmit at a uniform rate, congestion would be less common. Another open loop method to help manage congestion is forcing the packet to be transmitted at a more predictable rate. This is called traffic shaping.<br />
38. Explain packet filter<br />
Packet filter is a standard router equipped with some extra functionality. The extra functionality allows every incoming or outgoing packet to be inspected. Packets meeting some criterion are forwarded normally. Those that fail the test are dropped.<br />
39. Explain virtual path<br />
Along any transmission path from a given source to a given destination, a group of virtual circuits can be grouped together into what is called path.<br />
40. Explain virtual channel<br />
Virtual channel is normally a connection from one source to one destination, although multicast connections are also permitted. The other name for virtual channel is virtual circuit.<br />
41. Explain logical link control<br />
One of two sublayers of the data link layer of OSI reference model, as defined by the IEEE 802 standard. This sublayer is responsible for maintaining the link between computers when they are sending data across the physical network connection.<br />
42. Why should you care about the OSI Reference Model<br />
It provides a framework for discussing network operations and design.<br />
43. Explain the difference between routable and non- routable protocols<br />
Routable protocols can work with a router and can be used to build large networks. Non-Routable protocols are designed to work on small, local networks and cannot be used with a router<br />
44. Explain MAU<br />
In token Ring , hub is called Multistation Access Unit(MAU).<br />
45. Explain 5-4-3 rule<br />
In a Ethernet network, between any two points on the network, there can be no more than five network segments or four repeaters, and of those five segments only three of segments can be populated.<br />
46. Explain the difference between TFTP and FTP application layer protocols<br />
The Trivial File Transfer Protocol (TFTP) allows a local host to obtain files from a remote host but does not provide reliability or security. It uses the fundamental packet delivery services offered by UDP.<br />
The File Transfer Protocol (FTP) is the standard mechanism provided by TCP / IP for copying a file from one host to another. It uses the services offered by TCP and so is reliable and secure. It establishes two connections (virtual circuits) between the hosts, one for data transfer and another for control information.<br />
47. Explain the range of addresses in the classes of internet addresses<br />
Class A 0.0.0.0 – 127.255.255.255<br />
Class B 128.0.0.0 – 191.255.255.255<br />
Class C 192.0.0.0 – 223.255.255.255<br />
Class D 224.0.0.0 – 239.255.255.255<br />
Class E 240.0.0.0 – 247.255.255.255</p>
<p>48. Explain the minimum and maximum length of the header in the TCP segment and IP datagram<br />
The header should have a minimum length of 20 bytes and can have a maximum length of 60 bytes.<br />
49. Explain difference between ARP and RARP<br />
The address resolution protocol (ARP) is used to associate the 32 bit IP address with the 48 bit physical address, used by a host or a router to find the physical address of another host on its network by sending a ARP query packet that includes the IP address of the receiver. The reverse address resolution protocol (RARP) allows a host to discover its Internet address when it knows only its physical address.<br />
50. Explain ICMP<br />
ICMP is Internet Control Message Protocol, a network layer protocol of the TCP/IP suite used by hosts and gateways to send notification of datagram problems back to the sender. It uses the echo test / reply to test whether a destination is reachable and responding. It also handles both control and error messages.<br />
51. What are the data units at different layers of the TCP / IP protocol suite<br />
The data unit created at the application layer is called a message, at the transport layer the data unit created is called either a segment or an user datagram, at the network layer the data unit created is called the datagram, at the data link layer the datagram is encapsulated in to a frame and<br />
finally transmitted as signals along the transmission media.</p>
<p>52. Explain Project 802<br />
It is a project started by IEEE to set standards that enable intercommunication between equipment from a variety of manufacturers. It is a way for specifying functions of the physical layer, the data link layer and to some extent the network layer to allow for interconnectivity of major LAN protocols.<br />
It consists of the following:<br />
802.1 is an internetworking standard for compatibility of different LANs and MANs across protocols.<br />
802.2 Logical link control (LLC) is the upper sublayer of the data link layer which is non-architecture-specific, that is remains the same for all IEEE-defined LANs.<br />
Media access control (MAC) is the lower sublayer of the data link layer that contains some distinct modules each carrying proprietary information specific to the LAN product being used. The modules are Ethernet LAN (802.3), Token ring LAN (802.4), Token bus LAN (802.5).<br />
802.6 is distributed queue dual bus (DQDB) designed to be used in MANs.<br />
53. Explain Bandwidth<br />
Every line has an upper limit and a lower limit on the frequency of signals it can carry. This limited range is called the bandwidth.<br />
54. Difference between bit rate and baud rate.<br />
Bit rate is the number of bits transmitted during one second whereas baud rate refers to the number of signal units per second that are required to represent those bits. baud rate = bit rate / N where N is no-of-bits represented by each signal shift.<br />
55. Explain MAC address<br />
The address for a device as it is identified at the Media Access Control (MAC) layer in the network architecture. MAC address is usually stored in ROM on the network adapter card and is unique.</p>
<p>56. Explain attenuation<br />
The degeneration of a signal over distance on a network cable is called attenuation.</p>
<p>57. Explain cladding<br />
A layer of a glass surrounding the center fiber of glass inside a fiber-optic cable.</p>
<p>58. Explain RAID<br />
A method for providing fault tolerance by using multiple hard disk drives.</p>
<p>59. Explain NETBIOS and NETBEUI<br />
NETBIOS is a programming interface that allows I/O requests to be sent to and received from a remote computer and it hides the networking hardware from applications. NETBEUI is NetBIOS extended user interface. A transport protocol designed by microsoft and IBM for the use on small subnets.</p>
<p>60. Explain redirector<br />
Redirector is software that intercepts file or prints I/O requests and translates them into network requests. This comes under presentation layer.<br />
61. Explain Beaconing<br />
The process that allows a network to self-repair networks problems. The stations on the network notify the other stations on the ring when they are not receiving the transmissions. Beaconing is used in Token ring and FDDI networks.<br />
62. Explain terminal emulation, in which layer it comes<br />
Telnet is also called as terminal emulation. It belongs to application layer.</p>
<p>63. Explain frame relay, in which layer it comes<br />
Frame relay is a packet switching technology. It will operate in the data link layer.</p>
<p>64. What do you meant by “triple X” in Networks<br />
The function of PAD (Packet Assembler Disassembler) is described in a document known as X.3. The standard protocol has been defined between the terminal and the PAD, called X.28; another standard protocol exists between hte PAD and the network, called X.29. Together, these three recommendations are often called “triple X”<br />
65. Explain SAP<br />
Series of interface points that allow other computers to communicate with the other layers of network protocol stack.</p>
<p>66. Explain subnet<br />
A generic term for section of a large networks usually separated by a bridge or router.</p>
<p>67. Explain Brouter<br />
Hybrid devices that combine the features of both bridges and routers.</p>
<p>68. How Gateway is different from Routers<br />
A gateway operates at the upper levels of the OSI model and translates information between two completely different network architectures or data formats.</p>
<p>69. What are the different type of networking / internetworking devices<br />
Repeater: Also called a regenerator, it is an electronic device that operates only at physical layer. It receives the signal in the network before it becomes weak, regenerates the original bit pattern and puts the refreshed copy back in to the link.<br />
Bridges: These operate both in the physical and data link layers of LANs of same type. They divide a larger network in to smaller segments. They contain logic that allow them to keep the traffic for each segment separate and thus are repeaters that relay a frame only the side of the segment containing the intended recipent and control congestion.<br />
Routers: They relay packets among multiple interconnected networks (i.e. LANs of different type). They operate in the physical, data link and network layers. They contain software that enable them to determine which of the several possible paths is the best for a particular transmission.<br />
Gateways:<br />
They relay packets among networks that have different protocols (e.g. between a LAN and a WAN). They accept a packet formatted for one protocol and convert it to a packet formatted for another protocol before forwarding it. They operate in all seven layers of the OSI model.<br />
70. Explain mesh network<br />
A network in which there are multiple network links between computers to provide multiple paths for data to travel.<br />
71. Explain passive topology<br />
When the computers on the network simply listen and receive the signal, they are referred to as passive because they don’t amplify the signal in any way. Example for passive topology – linear bus.</p>
<p>72. What are the important topologies for networks<br />
BUS topology:<br />
In this each computer is directly connected to primary network cable in a single line.<br />
Advantages:<br />
Inexpensive, easy to install, simple to understand, easy to extend.<br />
STAR topology:<br />
In this all computers are connected using a central hub.<br />
Advantages:<br />
Can be inexpensive, easy to install and reconfigure and easy to trouble shoot physical problems.<br />
RING topology:<br />
In this all computers are connected in loop.<br />
Advantages:<br />
All computers have equal access to network media, installation can be simple, and signal does not degrade as much as<br />
in other topologies because each computer<br />
regenerates it.</p>
<p>73. What are major types of networks and explain<br />
Server-based network<br />
Peer-to-peer network<br />
Peer-to-peer network, computers can act as both servers sharing resources and as clients using the resources.<br />
Server-based networks provide centralized control of network resources and rely on server computers to provide security and network administration</p>
<p>74. Explain Protocol Data Unit<br />
The data unit in the LLC level is called the protocol data unit (PDU). The PDU contains of four fields a destination service access point (DSAP), a source service access point (SSAP), a control field and an information field. DSAP, SSAP are addresses used by the LLC to identify the protocol stacks on the receiving and sending machines that are generating and using the data. The control field specifies whether the PDU frame is a information frame (I – frame) or a supervisory frame (S – frame) or a<br />
unnumbered frame (U – frame).<br />
75. Explain difference between baseband and broadband transmission<br />
In a baseband transmission, the entire bandwidth of the cable is consumed by a single signal. In broadband transmission, signals are sent on multiple frequencies, allowing multiple signals to be sent simultaneously.<br />
76. What are the possible ways of data exchange<br />
(i) Simplex (ii) Half-duplex (iii) Full-duplex.</p>
<p>77. What are the types of Transmission media<br />
Signals are usually transmitted over some transmission media that are broadly classified in to two categories.<br />
Guided Media:<br />
These are those that provide a conduit from one device to another that include twisted-pair, coaxial cable and fiber-optic cable. A signal traveling along any of these media is directed and is contained by the physical limits of the medium. Twisted-pair and coaxial cable use metallic that accept<br />
and transport signals in the form of electrical current. Optical fiber is a glass or plastic cable that accepts and transports signals in the form of light.<br />
Unguided Media:<br />
This is the wireless media that transport electromagnetic waves without using a physical conductor. Signals are broadcast either through air. This is done through radio communication, satellite communication and cellular telephony.<br />
78. Explain point-to-point protocol<br />
A communications protocol used to connect computers to remote networking services including Internet service providers.</p>
<p>79. What are the two types of transmission technology available<br />
(i) Broadcast and (ii) point-to-point</p>
<p>80. Difference between the communication and transmission.<br />
Transmission is a physical movement of information and concern issues like bit polarity, synchronization, clock etc. Communication means the meaning full exchange of information between two communication media.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pdftutorials.com/questions/networking-interview-questions.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>JAVA INTERVIEW QUESTIONS</title>
		<link>http://www.pdftutorials.com/questions/java-interview-questions.html</link>
		<comments>http://www.pdftutorials.com/questions/java-interview-questions.html#comments</comments>
		<pubDate>Thu, 13 Oct 2011 13:28:24 +0000</pubDate>
		<dc:creator>Tutorial Master</dc:creator>
				<category><![CDATA[questions]]></category>

		<guid isPermaLink="false">http://www.pdftutorials.com/test/?p=3848</guid>
		<description><![CDATA[1. What is a transient variable? A transient variable is a variable that may not be serialized. 2. Which containers use a border Layout as their default layout? The window, Frame and Dialog classes use a border layout as their default layout. 3. Why do threads block on I/O? Threads block on I/O (that is <a href="http://www.pdftutorials.com/questions/java-interview-questions.html"> read more <span class="meta-nav">&#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p>1. What is a transient variable?<br />
A transient variable is a variable that may not be serialized.</p>
<p>2. Which containers use a border Layout as their default layout?<br />
The window, Frame and Dialog classes use a border layout as their default layout.</p>
<p>3. Why do threads block on I/O?<br />
Threads block on I/O (that is enters the waiting state) so that other threads may execute while the I/O Operation is performed.</p>
<p>4. How are Observer and Observable used?<br />
Objects that subclass the Observable class maintain a list of observers. When an Observable object is updated it invokes the update() method of each of its observers to notify the observers that it has changed state. The Observer interface is implemented by objects that observe Observable objects.</p>
<p>5. What is synchronization and why is it important?<br />
With respect to multithreading, synchronization is the capability to control the access of multiple threads to shared resources. Without synchronization, it is possible for one thread to modify a shared object while another thread is in the process of using or updating that object’s value. This often leads to significant errors.</p>
<p>6. Can a lock be acquired on a class?<br />
Yes, a lock can be acquired on a class. This lock is acquired on the class’s Class object.</p>
<p>7. What’s new with the stop(), suspend() and resume() methods in JDK 1.2?<br />
The stop(), suspend() and resume() methods have been deprecated in JDK 1.2.<br />
8. Is null a keyword?<br />
The null value is not a keyword.</p>
<p>9. What is the preferred size of a component?<br />
The preferred size of a component is the minimum component size that will allow the component to display normally.</p>
<p>10. What method is used to specify a container’s layout?<br />
The setLayout() method is used to specify a container’s layout.</p>
<p>11. Which containers use a FlowLayout as their default layout?<br />
The Panel and Applet classes use the FlowLayout as their default layout.</p>
<p>12. What state does a thread enter when it terminates its processing?<br />
When a thread terminates its processing, it enters the dead state.</p>
<p>13. What is the Collections API?<br />
The Collections API is a set of classes and interfaces that support operations on collections of objects.</p>
<p>14. which characters may be used as the second character of an identifier, but not as the first character of an identifier?<br />
The digits 0 through 9 may not be used as the first character of an identifier but they may be used after the first character of an identifier.<br />
15. What is the List interface?<br />
The List interface provides support for ordered collections of objects.</p>
<p>16. How does Java handle integer overflows and underflows?<br />
It uses those low order bytes of the result that can fit into the size of the type allowed by the operation.</p>
<p>17. What is the Vector class?<br />
The Vector class provides the capability to implement a growable array of objects</p>
<p>18. What modifiers may be used with an inner class that is a member of an outer class?<br />
A (non-local) inner class may be declared as public, protected, private, static, final, or abstract.</p>
<p>19. What is an Iterator interface?<br />
The Iterator interface is used to step through the elements of a Collection.</p>
<p>20. What is the difference between the &gt;&gt; and &gt;&gt;&gt; operators?<br />
The &gt;&gt; operator carries the sign bit when shifting right. The &gt;&gt;&gt; zero-fills bits that have been shifted out.</p>
<p>21. Which method of the Component class is used to set the position and size of a component?<br />
setBounds()<br />
22. How many bits are used to represent Unicode, ASCII, UTF-16, and UTF-8 characters?<br />
Unicode requires 16 bits and ASCII require 7 bits. Although the ASCII character set uses only 7 bits, it is usually represented as 8 bits. UTF-8 represents characters using 8, 16, and 18 bit patterns. UTF-16 uses 16-bit and larger bit patterns.</p>
<p>23 What is the difference between yielding and sleeping?<br />
When a task invokes its yield() method, it returns to the ready state. When a task invokes its sleep() method, it returns to the waiting state.</p>
<p>24. Which java.util classes and interfaces support event handling?<br />
The EventObject class and the EventListener interface support event processing.</p>
<p>25. Is sizeof a keyword?<br />
The sizeof operator is not a keyword.</p>
<p>26. What are wrapper classes?<br />
Wrapper classes are classes that allow primitive types to be accessed as objects.</p>
<p>27. Does garbage collection guarantee that a program will not run out of memory?<br />
Garbage collection does not guarantee that a program will not run out of memory. It is possible for programs to use up memory resources faster than they are garbage collected. It is also possible for programs to create objects that are not subject to garbage collection.</p>
<p>28. What restrictions are placed on the location of a package statement within a source code file?<br />
A package statement must appear as the first line in a source code file (excluding blank lines and comments).<br />
29. Can an object’s finalize() method be invoked while it is reachable?<br />
An object’s finalize() method cannot be invoked by the garbage collector while the object is still reachable. However, an object’s finalize() method may be invoked by other objects.</p>
<p>30. What is the immediate superclass of the Applet class?<br />
Panel</p>
<p>31. What is the difference between preemptive scheduling and time slicing?<br />
Under preemptive scheduling, the highest priority task executes until it enters the waiting or dead states or a higher priority task comes into existence. Under time slicing, a task executes for a predefined slice of time and then reenters the pool of ready tasks. The scheduler then determines which task should execute next, based on priority and other factors.</p>
<p>32. Name three Component subclasses that support painting.<br />
The Canvas, Frame, Panel, and Applet classes support painting.</p>
<p>33. What value does readLine() return when it has reached the end of a file?<br />
The readLine() method returns null when it has reached the end of a file.</p>
<p>34. What is the immediate superclass of the Dialog class?<br />
Window.</p>
<p>35. What is clipping?<br />
Clipping is the process of confining paint operations to a limited area or shape.<br />
36. What is a native method?<br />
A native method is a method that is implemented in a language other than Java.</p>
<p>37. Can a for statement loop indefinitely?<br />
Yes, a for statement can loop indefinitely. For example, consider the following:<br />
for(;;) ;</p>
<p>38. What are order of precedence and associativity, and how are they used?<br />
Order of precedence determines the order in which operators are evaluated in expressions. Associatity determines whether an expression is evaluated left-to-right or right-to-left</p>
<p>39. When a thread blocks on I/O, what state does it enter?<br />
A thread enters the waiting state when it blocks on I/O.</p>
<p>40. To what value is a variable of the String type automatically initialized?<br />
The default value of a String type is null.</p>
<p>41. What is the catch or declare rule for method declarations?<br />
If a checked exception may be thrown within the body of a method, the method must either catch the exception or declare it in its throws clause.</p>
<p>42. What is the difference between a MenuItem and a CheckboxMenuItem?<br />
The CheckboxMenuItem class extends the MenuItem class to support a menu item that may be checked or unchecked.<br />
43. What is a task’s priority and how is it used in scheduling?<br />
A task’s priority is an integer value that identifies the relative order in which it should be executed with respect to other tasks. The scheduler attempts to schedule higher priority tasks before lower priority tasks.</p>
<p>44. What class is the top of the AWT event hierarchy?<br />
The java.awt.AWTEvent class is the highest-level class in the AWT event-class hierarchy.</p>
<p>45. When a thread is created and started, what is its initial state?<br />
A thread is in the ready state after it has been created and started.</p>
<p>46. Can an anonymous class be declared as implementing an interface and extending a class?<br />
An anonymous class may implement an interface or extend a superclass, but may not be declared to do both.</p>
<p>47. What is the range of the short type?<br />
The range of the short type is -(2^15) to 2^15 – 1.</p>
<p>48. What is the range of the char type?<br />
The range of the char type is 0 to 2^16 – 1.</p>
<p>49. In which package are most of the AWT events that support the event-delegation model defined?<br />
Most of the AWT-related events of the event-delegation model are defined in the java.awt.event package. The AWTEvent class is defined in the java.awt package.<br />
50. What is the immediate superclass of Menu?<br />
MenuItem</p>
<p>51. What is the purpose of finalization?<br />
The purpose of finalization is to give an unreachable object the opportunity to perform any cleanup processing before the object is garbage collected.</p>
<p>52. Which class is the immediate superclass of the MenuComponent class.<br />
Object</p>
<p>53. What invokes a thread’s run() method?<br />
After a thread is started, via its start() method or that of the Thread class, the JVM invokes the thread’s run() method when the thread is initially executed.</p>
<p>54. What is the difference between the Boolean &amp; operator and the &amp;&amp; operator?<br />
If an expression involving the Boolean &amp; operator is evaluated, both operands are evaluated. Then the &amp; operator is applied to the operand. When an expression involving the &amp;&amp; operator is evaluated, the first operand is evaluated. If the first operand returns a value of true then the second operand is evaluated. The &amp;&amp; operator is then applied to the first and second operands. If the first operand evaluates to false, the evaluation of the second operand is skipped.</p>
<p>55. Name three subclasses of the Component class.<br />
Box.Filler, Button, Canvas, Checkbox, Choice, Container, Label, List, Scrollbar, or TextComponent</p>
<p>56. What is the GregorianCalendar class?<br />
The GregorianCalendar provides support for traditional Western calendars.<br />
57. Which Container method is used to cause a container to be laid out and redisplayed?<br />
validate()</p>
<p>58. What is the purpose of the Runtime class?<br />
The purpose of the Runtime class is to provide access to the Java runtime system.</p>
<p>59. How many times may an object’s finalize() method be invoked by the<br />
garbage collector?<br />
An object’s finalize() method may only be invoked once by the garbage collector.</p>
<p>60. What is the purpose of the finally clause of a try-catch-finally statement?<br />
The finally clause is used to provide the capability to execute code no matter whether or not an exception is thrown or caught.</p>
<p>61. What is the argument type of a program’s main() method?<br />
A program’s main() method takes an argument of the String[] type.</p>
<p>62. Which Java operator is right associative?<br />
The = operator is right associative.</p>
<p>63. What is the Locale class?<br />
The Locale class is used to tailor program output to the conventions of a particular geographic, political, or cultural region.64. Can a double value be cast to a byte?<br />
Yes, a double value can be cast to a byte.</p>
<p>65. What is the difference between a break statement and a continue statement?<br />
A break statement results in the termination of the statement to which it applies (switch, for, do, or while). A continue statement is used to end the current loop iteration and return control to the loop statement.</p>
<p>66. What must a class do to implement an interface?<br />
It must provide all of the methods in the interface and identify the interface in its implements clause.</p>
<p>67. What method is invoked to cause an object to begin executing as a separate thread?<br />
The start() method of the Thread class is invoked to cause an object to begin executing as a separate thread.</p>
<p>68. Name two subclasses of the TextComponent class.<br />
TextField and TextArea</p>
<p>69. What is the advantage of the event-delegation model over the earlier event-inheritance model?<br />
The event-delegation model has two advantages over the event-inheritance model. First, it enables event handling to be handled by objects other than the ones that generate the events (or their containers). This allows a clean separation between a component’s design and its use. The other advantage of the event-delegation model is that it performs much better in applications where many events are generated. This performance improvement is due to the fact that the event-delegation model does not have to repeatedly process unhandled events, as is the case of the event-inheritance<br />
model.</p>
<p>70. Which containers may have a MenuBar?<br />
Frame<br />
71. How are commas used in the initialization and iteration parts of a for statement?<br />
Commas are used to separate multiple statements within the initialization and iteration parts of a for statement.</p>
<p>72. What is the purpose of the wait(), notify(), and notifyAll() methods?<br />
The wait(),notify(), and notifyAll() methods are used to provide an efficient way for threads to wait for a shared resource. When a thread executes an object’s wait() method, it enters the waiting state. It only enters the ready state after another thread invokes the object’s notify() or notifyAll() methods.</p>
<p>73. What is an abstract method?<br />
An abstract method is a method whose implementation is deferred to a subclass.</p>
<p>74. How are Java source code files named?<br />
A Java source code file takes the name of a public class or interface that is defined within the file. A source code file may contain at most one public class or interface. If a public class or interface is defined within a source code file, then the source code file must take the name of the public class or interface. If no public class or interface is defined within a source code file, then the file must take on a name that is different than its classes and interfaces. Source code files use the .java extension.</p>
<p>75. What is the relationship between the Canvas class and the Graphics class?<br />
A Canvas object provides access to a Graphics object via its paint() method.</p>
<p>76. What are the high-level thread states?<br />
The high-level thread states are ready, running, waiting, and dead.</p>
<p>77. What value does read() return when it has reached the end of a file?<br />
The read() method returns -1 when it has reached the end of a file.<br />
78. Can a Byte object be cast to a double value?<br />
No, an object cannot be cast to a primitive value.</p>
<p>79. What is the difference between a static and a non-static inner class?<br />
A non-static inner class may have object instances that are associated with instances of the class’s outer class. A static inner class does not have any object instances.</p>
<p>80. What is the difference between the String and StringBuffer classes?<br />
String objects are constants. StringBuffer objects are not.</p>
<p>81. If a variable is declared as private, where may the variable be accessed?<br />
A private variable may only be accessed within the class in which it is declared.</p>
<p>82. What is an object’s lock and which objects have locks?<br />
An object’s lock is a mechanism that is used by multiple threads to obtain synchronized access to the object. A thread may execute a synchronized method of an object only after it has acquired the object’s lock. All objects and classes have locks. A class’s lock is acquired on the class’s Class object.</p>
<p>83. What is the Dictionary class?<br />
The Dictionary class provides the capability to store key-value pairs.</p>
<p>84. How are the elements of a BorderLayout organized?<br />
The elements of a BorderLayout are organized at the borders (North, South, East, and West) and the center of a container.<br />
85. What is the % operator?<br />
It is referred to as the modulo or remainder operator. It returns the remainder of dividing the first operand by the second operand.</p>
<p>86. When can an object reference be cast to an interface reference?<br />
An object reference be cast to an interface reference when the object implements the referenced interface.</p>
<p>87. What is the difference between a Window and a Frame?<br />
The Frame class extends Window to define a main application window that can have a menu bar.</p>
<p>88. Which class is extended by all other classes?<br />
The Object class is extended by all other classes.</p>
<p>89. Can an object be garbage collected while it is still reachable?<br />
A reachable object cannot be garbage collected. Only unreachable objects may be garbage collected..</p>
<p>90. Is the ternary operator written x : y ? z or x ? y : z ?<br />
It is written x ? y : z.</p>
<p>91. What is the difference between the Font and FontMetrics classes?<br />
The FontMetrics class is used to define implementation-specific properties, such as ascent and descent, of a Font object.<br />
92. How is rounding performed under integer division?<br />
The fractional part of the result is truncated. This is known as rounding toward zero.</p>
<p>93. What happens when a thread cannot acquire a lock on an object?<br />
If a thread attempts to execute a synchronized method or synchronized statement and is unable to acquire an object’s lock, it enters the waiting state until the lock becomes available.</p>
<p>94. What is the difference between the Reader/Writer class hierarchy and the InputStream/OutputStream class hierarchy?<br />
The Reader/Writer class hierarchy is character-oriented, and the InputStream/OutputStream class hierarchy is byte-oriented.</p>
<p>95. What classes of exceptions may be caught by a catch clause?<br />
A catch clause can catch any exception that may be assigned to the Throwable type. This includes the Error and Exception types.</p>
<p>96. If a class is declared without any access modifiers, where may the class be accessed?<br />
A class that is declared without any access modifiers is said to have package access. This means that the class can only be accessed by other classes and interfaces that are defined within the same package.</p>
<p>97. What is the SimpleTimeZone class?<br />
The SimpleTimeZone class provides support for a Gregorian calendar.</p>
<p>98. What is the Map interface?<br />
The Map interface replaces the JDK 1.1 Dictionary class and is used associate keys with values.99. Does a class inherit the constructors of its superclass?<br />
A class does not inherit constructors from any of its super classes.</p>
<p>100. For which statements does it make sense to use a label?<br />
The only statements for which it makes sense to use a label are those statements that can enclose a break or continue statement.</p>
<p>101. What is the purpose of the System class?<br />
The purpose of the System class is to provide access to system resources.</p>
<p>102. Which TextComponent method is used to set a TextComponent to the read-only state?<br />
setEditable()</p>
<p>103. How are the elements of a CardLayout organized?<br />
The elements of a CardLayout are stacked, one on top of the other, like a deck of cards.</p>
<p>104. Is &amp;&amp;= a valid Java operator?<br />
No, it is not.</p>
<p>105. Name the eight primitive Java types.<br />
The eight primitive types are byte, char, short, int, long, float, double, and boolean.<br />
106. Which class should you use to obtain design information about an object?<br />
The Class class is used to obtain information about an object’s design.</p>
<p>107. What is the relationship between clipping and repainting?<br />
When a window is repainted by the AWT painting thread, it sets the clipping regions to the area of the window that requires repainting.</p>
<p>108. Is “abc” a primitive value?<br />
The String literal “abc” is not a primitive value. It is a String object.</p>
<p>109. What is the relationship between an event-listener interface and an event-adapter class?<br />
An event-listener interface defines the methods that must be implemented by an event handler for a particular kind of event. An event adapter provides a default implementation of an event-listener interface.</p>
<p>110. What restrictions are placed on the values of each case of a switch statement?<br />
During compilation, the values of each case of a switch statement must evaluate to a value that can be promoted to an int value.</p>
<p>111. What modifiers may be used with an interface declaration?<br />
An interface may be declared as public or abstract.</p>
<p>112. Is a class a subclass of itself?<br />
A class is a subclass of itself.<br />
113. What is the highest-level event class of the event-delegation model?<br />
The java.util.EventObject class is the highest-level class in the event-delegation class hierarchy.</p>
<p>114. What event results from the clicking of a button?<br />
The ActionEvent event is generated as the result of the clicking of a button.</p>
<p>115. How can a GUI component handle its own events?<br />
A component can handle its own events by implementing the required event-listener interface and adding itself as its own event listener.</p>
<p>116. What is the difference between a while statement and a do statement?<br />
A while statement checks at the beginning of a loop to see whether the next loop iteration should occur. A do statement checks at the end of a loop to see whether the next iteration of a loop should occur. The do statement will always execute the body of a loop at least once.</p>
<p>117. How are the elements of a GridBagLayout organized?<br />
The elements of a GridBagLayout are organized according to a grid. However, the elements are of different sizes and may occupy more than one row or column of the grid. In addition, the rows and columns may have different sizes.</p>
<p>118. What advantage do Java’s layout managers provide over traditional windowing systems?<br />
Java uses layout managers to lay out components in a consistent manner across all windowing platforms. Since Java’s layout managers aren’t tied to absolute sizing and positioning, they are able to accommodate platform-specific differences among windowing systems.</p>
<p>119. What is the Collection interface?<br />
The Collection interface provides support for the implementation of a mathematical bag – an unordered collection of objects that may contain duplicates.<br />
120. What modifiers can be used with a local inner class?<br />
A local inner class may be final or abstract.</p>
<p>121. What is the difference between static and non-static variables?<br />
A static variable is associated with the class as a whole rather than with specific instances of a class. Non-static variables take on unique values with each object instance.</p>
<p>122. What is the difference between the paint() and repaint() methods?<br />
The paint() method supports painting via a Graphics object. The repaint() method is used to cause paint() to be invoked by the AWT painting thread.</p>
<p>123. What is the purpose of the File class?<br />
The File class is used to create objects that provide access to the files and directories of a local file system.</p>
<p>124. Can an exception be rethrown?<br />
Yes, an exception can be rethrown.</p>
<p>125. Which Math method is used to calculate the absolute value of a number?<br />
The abs() method is used to calculate absolute values.</p>
<p>126. How does multithreading take place on a computer with a single CPU?<br />
The operating system’s task scheduler allocates execution time to multiple tasks. By quickly switching between executing tasks, it creates the impression that tasks execute sequentially.<br />
127. When does the compiler supply a default constructor for a class?<br />
The compiler supplies a default constructor for a class if no other constructors are provided.</p>
<p>128. When is the finally clause of a try-catch-finally statement executed?<br />
The finally clause of the try-catch-finally statement is always executed unless the thread of execution terminates or an exception occurs within the execution of the finally clause.</p>
<p>129. Which class is the immediate superclass of the Container class?<br />
Component</p>
<p>130. If a method is declared as protected, where may the method be accessed?<br />
A protected method may only be accessed by classes or interfaces of the same package or by subclasses of the class in which it is declared.</p>
<p>131. How can the Checkbox class be used to create a radio button?<br />
By associating Checkbox objects with a CheckboxGroup.</p>
<p>132. Which non-Unicode letter characters may be used as the first character of an identifier?<br />
The non-Unicode letter characters $ and _ may appear as the first character of an identifier</p>
<p>133. What restrictions are placed on method overloading?<br />
Two methods may not have the same name and argument list but different return types.<br />
134. What happens when you invoke a thread’s interrupt method while it is sleeping or waiting?<br />
When a task’s interrupt() method is executed, the task enters the ready state. The next time the task enters the running state, an InterruptedException is thrown.</p>
<p>135. What is casting?<br />
There are two types of casting, casting between primitive numeric types and casting between object references. Casting between numeric types is used to convert larger values, such as double values, to smaller values, such as byte values. Casting between object references is used to refer to an object by a compatible class, interface, or array type reference.</p>
<p>136. What is the return type of a program’s main() method?<br />
A program’s main() method has a void return type.</p>
<p>137. Name four Container classes.<br />
Window, Frame, Dialog, FileDialog, Panel, Applet, or ScrollPane</p>
<p>138. What is the difference between a Choice and a List?<br />
A Choice is displayed in a compact form that requires you to pull it down to see the list of available choices. Only one item may be selected from a Choice. A List may be displayed in such a way that several List items are visible. A List supports the selection of one or more List items.</p>
<p>139. What class of exceptions are generated by the Java run-time system?<br />
The Java runtime system generates RuntimeException and Error exceptions.</p>
<p>140. What class allows you to read objects directly from a stream?<br />
The ObjectInputStream class supports the reading of objects from input streams.<br />
141. What is the difference between a field variable and a local variable?<br />
A field variable is a variable that is declared as a member of a class. A local variable is a variable that is declared local to a method.</p>
<p>142. Under what conditions is an object’s finalize() method invoked by the garbage collector?<br />
The garbage collector invokes an object’s finalize() method when it detects that the object has become unreachable.</p>
<p>143. How are this () and super () used with constructors?<br />
this() is used to invoke a constructor of the same class. super() is used to invoke a superclass constructor.</p>
<p>144. What is the relationship between a method’s throws clause and the exceptions that can be thrown during the method’s execution?<br />
A method’s throws clause must declare any checked exceptions that are not caught within the body of the method.</p>
<p>145. What is the difference between the JDK 1.02 event model and the event-delegation model introduced with JDK 1.1?<br />
The JDK 1.02 event model uses an event inheritance or bubbling approach. In this model, components are required to handle their own events. If they do not handle a particular event, the event is inherited by (or bubbled up to) the component’s container. The container then either handles the event or it is bubbled up to its container and so on, until the highest-level container has been tried.<br />
In the event-delegation model, specific objects are designated as event handlers for GUI components. These objects implement event-listener interfaces. The event-delegation model is more efficient than the event-inheritance model because it eliminates the processing required to support the bubbling of unhandled events.</p>
<p>146. How is it possible for two String objects with identical values not to be equal under the == operator?<br />
The == operator compares two objects to determine if they are the same object in memory. It is possible for two String objects to have the same value, but located indifferent areas of memory.</p>
<p>147. Why are the methods of the Math class static?<br />
So they can be invoked as if they are a mathematical code library.<br />
148. What Checkbox method allows you to tell if a Checkbox is checked?<br />
getState()</p>
<p>149. What state is a thread in when it is executing?<br />
An executing thread is in the running state.</p>
<p>150. What are the legal operands of the instanceof operator?<br />
The left operand is an object reference or null value and the right operand is a class, interface, or array type.</p>
<p>151. How are the elements of a GridLayout organized?<br />
The elements of a GridBad layout are of equal size and are laid out using the squares of a grid.</p>
<p>152. What an I/O filter?<br />
An I/O filter is an object that reads from one stream and writes to another, usually altering the data in some way as it is passed from one stream to another.</p>
<p>153. If an object is garbage collected, can it become reachable again?<br />
Once an object is garbage collected, it ceases to exist. It can no longer become reachable again.</p>
<p>154. What is the Set interface?<br />
The Set interface provides methods for accessing the elements of a finite mathematical set. Sets do not allow duplicate elements.<br />
155. What classes of exceptions may be thrown by a throw statement?<br />
A throw statement may throw any expression that may be assigned to the Throwable type.</p>
<p>156. What are E and PI?<br />
E is the base of the natural logarithm and PI is mathematical value pi.</p>
<p>157. Are true and false keywords?<br />
The values true and false are not keywords.</p>
<p>158. What is a void return type?<br />
A void return type indicates that a method does not return a value.</p>
<p>159. What is the purpose of the enableEvents() method?<br />
The enableEvents() method is used to enable an event for a particular object. Normally, an event is enabled when a listener is added to an object for a particular event. The enableEvents() method is used by objects that handle events by overriding their event-dispatch methods.</p>
<p>160. What is the difference between the File and RandomAccessFile classes?<br />
The File class encapsulates the files and directories of the local file system. The RandomAccessFile class provides the methods needed to directly access data contained in any part of a file.</p>
<p>161. What happens when you add a double value to a String?<br />
The result is a String object.162. What is your platform’s default character encoding?<br />
If you are running Java on English Windows platforms, it is probably Cp1252. If you are running Java on English Solaris platforms, it is most likely 8859_1..</p>
<p>163. Which package is always imported by default?<br />
The java.lang package is always imported by default.</p>
<p>164. What interface must an object implement before it can be written to a stream as an object?<br />
An object must implement the Serializable or Externalizable interface before it can be written to a stream as an object.</p>
<p>165. How are this and super used?<br />
this is used to refer to the current object instance. super is used to refer to the variables and methods of the superclass of the current object instance.</p>
<p>166. What is the purpose of garbage collection?<br />
The purpose of garbage collection is to identify and discard objects that are no longer needed by a program so that their resources may be reclaimed and<br />
reused.</p>
<p>167. What is a compilation unit?<br />
A compilation unit is a Java source code file.</p>
<p>168. What interface is extended by AWT event listeners?<br />
All AWT event listeners extend the java.util.EventListener interface.<br />
169. What restrictions are placed on method overriding?<br />
Overridden methods must have the same name, argument list, and return type.<br />
The overriding method may not limit the access of the method it overrides.<br />
The overriding method may not throw any exceptions that may not be thrown<br />
by the overridden method.</p>
<p>170. How can a dead thread be restarted?<br />
A dead thread cannot be restarted.</p>
<p>171. What happens if an exception is not caught?<br />
An uncaught exception results in the uncaughtException() method of the thread’s ThreadGroup being invoked, which eventually results in the termination of the program in which it is thrown.</p>
<p>172. What is a layout manager?<br />
A layout manager is an object that is used to organize components in a container.</p>
<p>173. Which arithmetic operations can result in the throwing of an ArithmeticException?<br />
Integer / and % can result in the throwing of an ArithmeticException.</p>
<p>174. What are three ways in which a thread can enter the waiting state?<br />
A thread can enter the waiting state by invoking its sleep() method, by blocking on I/O, by unsuccessfully attempting to acquire an object’s lock, or by invoking an object’s wait() method. It can also enter the waiting state by invoking its<br />
(deprecated) suspend() method.</p>
<p>175. Can an abstract class be final?<br />
An abstract class may not be declared as final.176. What is the ResourceBundle class?<br />
The ResourceBundle class is used to store locale-specific resources that can be loaded by a program to tailor the program’s appearance to the particular locale in which it is being run.</p>
<p>177. What happens if a try-catch-finally statement does not have a catch clause to handle an exception that is thrown within the body of the try statement?<br />
The exception propagates up to the next higher level try-catch statement (if any) or results in the program’s termination.</p>
<p>178. What is numeric promotion?<br />
Numeric promotion is the conversion of a smaller numeric type to a larger numeric type, so that integer and floating-point operations may take place. In numerical promotion, byte, char, and short values are converted to int<br />
values. The int values are also converted to long values, if necessary. The long and float values are converted to double values, as required.</p>
<p>179. What is the difference between a Scrollbar and a ScrollPane?<br />
A Scrollbar is a Component, but not a Container. A ScrollPane is a Container. A ScrollPane handles its own events and performs its own scrolling.</p>
<p>180. What is the difference between a public and a non-public class?<br />
A public class may be accessed outside of its package. A non-public class may not be accessed outside of its package.</p>
<p>181. To what value is a variable of the boolean type automatically initialized?<br />
The default value of the boolean type is false.</p>
<p>182. Can try statements be nested?<br />
Try statements may be tested.<br />
183. What is the difference between the prefix and postfix forms of the ++ operator?<br />
The prefix form performs the increment operation and returns the value of the increment operation. The postfix form returns the current value all of the expression and then performs the increment operation on that value.</p>
<p>184. What is the purpose of a statement block?<br />
A statement block is used to organize a sequence of statements as a single statement group.</p>
<p>185. What is a Java package and how is it used?<br />
A Java package is a naming context for classes and interfaces. A package is used to create a separate name space for groups of classes and interfaces. Packages are also used to organize related classes and interfaces into a single API unit and to control accessibility to these classes and interfaces.</p>
<p>186. What modifiers may be used with a top-level class?<br />
A top-level class may be public, abstract, or final.</p>
<p>187. What are the Object and Class classes used for?<br />
The Object class is the highest-level class in the Java class hierarchy. The Class class is used to represent the classes and interfaces that are loaded by a Java program.</p>
<p>188. How does a try statement determine which catch clause should be used to handle an exception?<br />
When an exception is thrown within the body of a try statement, the catch clauses of the try statement are examined in the order in which they appear. The first catch clause that is capable of handling the exception is executed.<br />
The remaining catch clauses are ignored.</p>
<p>189. Can an unreachable object become reachable again?<br />
An unreachable object may become reachable again. This can happen when the object’s finalize() method is invoked and the object performs an operation which causes it to become accessible to reachable objects.190. When is an object subject to garbage collection?<br />
An object is subject to garbage collection when it becomes unreachable to the program in which it is used.</p>
<p>191. What method must be implemented by all threads?<br />
All tasks must implement the run() method, whether they are a subclass of Thread or implement the Runnable interface.</p>
<p>192. What methods are used to get and set the text label displayed by a Button object?<br />
getLabel() and setLabel()</p>
<p>193. Which Component subclass is used for drawing and painting?<br />
Canvas</p>
<p>194. What are synchronized methods and synchronized statements?<br />
Synchronized methods are methods that are used to control access to an object. A thread only executes a synchronized method after it has acquired the lock for the method’s object or class. Synchronized statements are similar to synchronized methods. A synchronized statement can only be executed after a thread has acquired the lock for the object or class referenced in the synchronized statement195. What are the two basic ways in which classes that can be run as threads may be defined?<br />
A thread class may be declared as a subclass of Thread, or it may implement the Runnable interface.</p>
<p>196. What are the problems faced by Java programmers who don’t use layout managers?<br />
Without layout managers, Java programmers are faced with determining how their GUI will be displayed across multiple windowing systems and finding a common sizing and positioning that will work within the constraints imposed by each windowing system.</p>
<p>197. What is the difference between an if statement and a switch statement?<br />
The if statement is used to select among two alternatives. It uses a boolean expression to decide which alternative should be executed. The switch statement is used to select among multiple alternatives. It uses an int expression to determine which alternative should be executed.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pdftutorials.com/questions/java-interview-questions.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

