English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

Basic PHP Tutorial

Advanced PHP Tutorial

PHP & MySQL

PHP Reference Manual

PHP odbc_cursor() Function Usage and Example

PHP ODBC Reference Manual

The odbc_cursor() function retrieves the cursor name.

Syntax

string odbc_cursor ( resource $result_id )

Definition and Usage

Used to get cursor information

Return Value

It returns the cursor name as a string, otherwise it returns false.

Parameter

NumberParameters and Description
1

result_id

It contains a result identifier

Example

Try the following example

<?php
   $input_ID = odbc_connect("DSN", "user_id", "pass_id");
   $result = odbc_exec($input_ID, "SELECT FirstName, LastName FROM Employees ORDER BY LastName");
   
   echo odbc_cursor($result);
?>

PHP ODBC Reference Manual