stored procedure results Question

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Hello most excellent and knowledgable PHP gurus
i have a small question regarding accessing elements in a cursor which
i hope is ok to ask,.

the following code works and i'm very pleased with myself

$the_cursor = OCINewCursor($conn);
$stmt2 = OCIParse($conn, "begin
gi_rio_api.get_road_asset_data_headers(:myset);  end;");
OCIBindByName($stmt2,":myset",&$the_cursor ,-1,OCI_B_CURSOR);
while (OCIFetchInto($the_cursor,&$myset,OCI_B_CURSOR))

           $column_name = $myset[1]; //
           $column_desc =$myset[0];
           $column_array [] = array( $column_name,$column_desc);

however, the database weenies tell me that they'll eb modifying stuff
onthe fly so i cant count on correct index values

how do i change the above code so i can access the fields in the
cursor by column name?

i'd ideally like to just put something like
  $column_name = $myset['COLUMN_NAME']; ..etc
what am i missing which  would solve my quandry?

regards and than you's


Site Timeline