You are here: PHP and Oracle - Selecting string columns causes ORA-03106: fatal two-task communication protocol error « All PHP « IT news, forums, messages
PHP and Oracle - Selecting string columns causes ORA-03106: fatal two-task communication protocol error

Posted by Richard Conway on 07/17/05 22:16

Hi there,

After much faffing about, I have managed to get PHP working with Oracle
- kind of :)

It appears that for some reason, whenver I try to execute a select
statment that includes a column which contains text, I get a ORA-03106:
fatal two-task communication protocol error. This does not happen with
columns of numbers or dates as these work fine. The code I am using is
as follows:

<!------ Begin Code --------->

$db = "<database connection details>";
if ($ora_conn = oci_connect("Username", "Password",$db)) {
echo "<B>SUCCESS ! Connected to database<B>\n";
} else {
echo "<B>Could not connect to database<B>\n";
}

// Select Data...
$query1="SELECT LASTNAME FROM GUESTS";
$s = OCI_Parse($ora_conn, $query1);
oci_define_by_name($s, "LASTNAME", $var1);
oci_execute($s);
while (oci_fetch($s)) {
echo $var1 . "<BR>";
}

oci_close($ora_conn);

<!------ End Code --------->

Any help on this would be muchly appreciated.

Thanks,
Richard

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация