php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #350 odbc_fetch_into() won't return a memo field
Submitted: 1998-05-05 18:52 UTC Modified: 1998-05-06 07:03 UTC
From: leon at clearink dot com Assigned:
Status: Closed Package: ODBC related
PHP Version: 3.0 Release Candidate 4 OS: NT 4.0
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: leon at clearink dot com
New email:
PHP Version: OS:

 

 [1998-05-05 18:52 UTC] leon at clearink dot com
This is probably related to the previous bug (349).

You can see this code run at:
<http://atlas.clearink.com/weird_odbc2.php3>

<HTML>
<HEAD><TITLE>Demonstration of Weird ODBC Behavior</TITLE></HEAD>
<BODY>
<?
	/* connect to the data source */
	echo "Connecting to database<BR><BR>\n";
	$DatabaseID = odbc_pconnect("mao", "", "");

	/* execute query */
	echo "Executing Query<BR><BR>\n";
	$dbResult = odbc_exec($DatabaseID, "SELECT * FROM activitytype");

	/* get each row */
	$rownumber = 0;
	while (odbc_fetch_into($dbResult, $rownumber, &$result_array)) 
	{
		echo "Fetched a row<BR><BR>\n";

		/* put three of the columns into variable */
		echo "Showing results<BR><BR>\n";

		$array_size = count($result_array);
		$array_count = 0;

		for($array_count = 0; $array_count < $array_size; $array_count++)
		{
			echo "$array_count : ";
			echo $result_array[$array_count];
			echo "<BR>\n";
		}

		echo "<BR>\n";

	}

	/* free the memory */
	echo "Freeing result<BR><BR>\n";
	odbc_free_result($dbResult);

?>

</BODY>
</HTML>

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1998-05-06 07:03 UTC] kara
Please refer to the documentation for odbc_longreadlen() and odbc_binmode() on how to get
LONG column values returned to your script.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Dec 22 01:01:30 2024 UTC