Start Discovering Solved Questions and Your Course Assignments
TextBooks Included
Solved Assignments
Asked Questions
Answered Questions
using the collection methodsthe collection methods below help to generalize the code and make collections easier to use and also make your
i have trying to do the homework but there is a mistake counting positive and negative numbers and computing the average of
use a for loop and give me the largest number divisible by 7 11 13 17 use the number from 1 to 10000 or even
manipulating local collectionswithin plsql to manipulate the local collection by using the table and cast operators the operands of cast are a
manipulating individual elementsfaraway you have manipulated an entire collection within the sql to manipulate the individual elements of the
some varray examplesin sql plus assume that you define an object type project as described belowsqlgt create type project as object 2 projectno
manipulating collectionswithin plsql the collections add procedural power and flexibility the biggest benefit is that your program can compute
assigning and comparing collectionsone collection can be assigned to other by an select insert update or fetch statement an assignment statement or
initializing and referencing collectionsuntil you initialize a collection a nested table or varray is automatically null ie the collection itself is
defining and declaring collectionsto create the collections you must define a collection type and then declare the collections of that type you can
varrays versus nested tablesthe nested tables are differing from varrays in the following ways1 varrays have a maximum size while nested tables
nested tables versus index-by tablesthe index-by tables and nested tables are just similar for eg they have similar structure and their
what is a collectionthe collection is an ordered group of elements all of similar type for eg the grades for a class of students each element has a
null statementthe null statement clearly specifies in action it does nothing other than to pass control to the next statement it can though improve
goto statementthe goto statement branches to a label unconditionally the label must be exclusive within its scope and should precede an executable
sequential controldissimilar to the if and loop statements the goto and null statements are not important to the plsql programming the configuration
dynamic rangesthe plsql lets you determine the loop range dynamically at run time as the example below showsselect countempno into empcount from
iteration schemesthe bounds of a loop range can be variables literals variables or expressions but must compute to integers below are some of the
for-loopwhile the number of iterations through a while loop is unknown till the loop completes then the number of iterations through a for loop is
while-loopthe while-loop statement relates a condition with the series of statements enclosed by the keywords loop and end loop as shownwhile
loop labelslike the plsql blocks loops can also be labeled the label an undeclared identifier enclosed by double angle brackets should appear at the
exit-whenthe exit-when statement permits a loop to complete conditionally whenever the exit statement is encountered the condition in the when clause
exitthe exit statement forces a loop to done unconditionally whenever an exit statement is encountered the loop is done immediately and controls the
iterative control loop statementsthe loop statement executes a series of statements multiple times there are 3 forms of loop statements loop
plsql conditional control if statementsfrequently it is necessary to take the alternative actions depending on the circumstances the if statement