|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| ||||||||||||||||||||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Class error
How can I use methods from pear db in some functions from my class?
I have extended the class DB_mssql to my class (class index extends DB_mssql{} and I am trying to call a method from DB_mssql: $variable = $this->getAssoc("EXECUTE procedure ? " , false , array( "code"=>1 ) ); and I am receiving an error: DB_Error Object ( [error_message_prefix] => [mode] => 1 [level] => 1024 [code] => -1 [message] => DB Error: unknown error [userinfo] => EXECUTE procedure 1 [nativecode=-14 - Changed database context to 'DatabaseName'.] [backtrace] => Array ( [0] => Array ( [file] => /usr/local/share/pear/DB.php [line] => 966 [function] => PEAR_Error [class] => PEAR_Error [type] => -> [args] => Array And so on... The interesting thing is that if I call that method afther objecting that function, it works perfect. The code is: $obj=new index(); (that is my class) $ms_sql=new DB_mssql(); $variable = $ms_sql->getAssoc("EXECUTE procedure ? " , false , array( "code"=>1 ) ); What can I do to call methods from inside of my class? Thank you. |
![]() |
| Viewing: Codewalkers Forums > PHP Related > PEAR Packages > Class error |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|