| Home | Previous Lesson: Declaring And Executing a Cursor Next Lesson: Executing the Cursor |
When you paste a cursor declaration in your PowerScript, PowerBuilder allows you to select a table and then it creates the template for you.
Before pasting the statement in your script, PowerBuilder prompts for the cursor name.
For example, you could declare as follows, to retrieve all product numbers and descriptions from the product_master:
DECLARE lProductMasterCursor1 CURSOR FOR
SELECT product_no,
item_product_description
FROM product_master ;
lProductMasterCursor1 is the name of the cursor we refer to in the following scripts.
| Home | Previous Lesson: Declaring And Executing a Cursor Next Lesson: Executing the Cursor |