move the cursor to the previous row - Maple Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Connectivity : Database Package : Result : Database/Result/Previous

Result:-Previous - move the cursor to the previous row

Calling Sequence

result:-Previous( )

Parameters

result

-

Result module

Description

• 

Previous moves the row cursor maintained within result to the previous row in the table.

• 

If the new Row is a valid row containing table data, Previous returns true.  If the new row is before the first row of the table, Previous returns false.

• 

The row cursor can be moved forward using the Next command.

Examples

Create a Result.

driver:=Database[LoadDriver]:

conn:=driver:-OpenConnectionurl,name,pass:res:=conn:-ExecuteQuerySELECT name FROM animals:

Move the cursor to the end of the table.

whileres:-Nextdoend do:

Now inspect the table backwards.

whileres:-Previousdores:-GetData1end do:

hamster

pig

parrot

lizard

snake

horse

rat

cat

dog

fish

(1)

See Also

Database, Database[Result], Database[Result][First], Database[Result][GotoRow], Database[Result][Last], Database[Result][Next], Database[usage]


Download Help Document

Was this information helpful?



Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam