PHP Velho Oeste 2024

ODBC (Unified)

add a note add a note

User Contributed Notes 1 note

up
-8
henrique at augusto dot com
10 years ago
I have problems with php5-recode and php5-odbc. With both packages installed, odbc_execute() hangs up causing Segmentation Fault. I was using a simple script to test that:

<?php
#DSN "mydb" with a user and password "marin"
$connect = odbc_connect("myaccess", "", "");

# query the users table for name and surname
$query = "SELECT * FROM FRT_NAME";

# perform the query
$result = odbc_exec($connect, $query);

# fetch the data from the database
while(odbc_fetch_row($result)){
       
$name = odbc_result($result, 2);
        print(
"$name\n");
}

# close the connection
odbc_close($connect);
?>

After uninstalling php5-recode, the issue is solved.
To Top