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($c onn);
$stmt2 = OCIParse($conn, "begin
gi_rio_api.get_ road_asset_data _headers(:myset ); end;");
OCIBindByName($ stmt2,":myset", &$the_cursor ,-1,OCI_B_CURSOR) ;
OCIExecute($stm t2);
OCIExecute($the _cursor);
while (OCIFetchInto($ the_cursor,&$my set,OCI_B_CURSO R))
{
$column_name = $myset[1]; //
$column_desc =$myset[0];
$column_array [] = array( $column_name,$c olumn_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
Buzz
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($c onn);
$stmt2 = OCIParse($conn, "begin
gi_rio_api.get_ road_asset_data _headers(:myset ); end;");
OCIBindByName($ stmt2,":myset", &$the_cursor ,-1,OCI_B_CURSOR) ;
OCIExecute($stm t2);
OCIExecute($the _cursor);
while (OCIFetchInto($ the_cursor,&$my set,OCI_B_CURSO R))
{
$column_name = $myset[1]; //
$column_desc =$myset[0];
$column_array [] = array( $column_name,$c olumn_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
Buzz