Path

ez projects / ezoracle / forum / general / pb using script ezsqlinsert...


Pb using script ezsqlinsertschema.php to install oracle 11g

You need to be logged in to post messages in the forums. New users may register here.

dada Mr

Member since:
23 June 2009

Posts: 5

Tuesday 23 June 2009 12:24:38 pm

Hello,

I'm working on window xp with WAMP 2.0.
I've installed ezpublish-4.1.3 from scratch with the extension oracle 2.0 ( last one i believe ) . I've followed the manual.
On this server , running an oracle database 11 g

I do a program's test to control that the connection is ok on the database with php
It works very good !



 $oracle_user = "EZPUBLISH";


 $oracle_pwd = "EZPUBLISH";


 $machine    = "XE11";


$conn=OCI_CONNECT($oracle_user,$oracle_pwd,$machine);


        if (!$conn )


        {


        


                echo "pb connexion";


                die;


        }       


        echo "connect├ę avec OCI_connect";


oci_close($conn);




when I launch the php commande



C:\wamp\www\ezpublish-4.1.3>php bin/php/ezsqlinsertschema.php --type=oracle --us


er=EZPUBLISH --password=EZPUBLISH share/db_schema.dba XE11


Could not initialize database:


* Tried database 'XE11' locally with user 'EZPUBLISH' and with a 'EZPUBLISH'


* No database handler was found for 'oracle'




I have some question No database handler what does it mean ?
How can we debug the functions and classes in ezpublish?

Thx
bangkok94

Up

Gaetano Giunta

Member since:
30 November 1999

Posts: 269

Tuesday 23 June 2009 3:55:22 pm

Are you sure you followed carefully step 8: "Enable the extension"?

you need to
- have the extension activated
- have the extensions autoload regenerated

"no database handler was found" means that the php class eZOracleDB was not found by the system when tryng to load it

Principal Consultant International Business
Member of the Community Project Board

Up

dada Mr

Member since:
23 June 2009

Posts: 5

Tuesday 23 June 2009 5:46:11 pm

Ok you're totally right , I forget this step 8
Now I have a message.

after launching the regeneration of the extension autoload file :
http://localhost/ezpublish-4.1.3/bin/php/ezpgenerateautoloads.php

I have this message below:

Scanning for PHP-files. The directory file 'C:/wamp/www/ezpublish-4.1.3/bin/php/extension' could not be found.


Up

Gaetano Giunta

Member since:
30 November 1999

Posts: 269

Tuesday 23 June 2009 6:07:24 pm

You should run that script from php command line, and starting from the ezpublish root directory - it should not be run via web access.

If you prefer to update the autoloads via a GUI, you can do that in the admin interface of eZ Publish, but only after you have installed it successfully (cat-and-tail problem in your case)

Principal Consultant International Business
Member of the Community Project Board

Up

dada Mr

Member since:
23 June 2009

Posts: 5

Tuesday 23 June 2009 7:11:03 pm

Ok.I run that script from php command
I have this message

Scanning for PHP-files.

Scan complete. Found 52 PHP files.

Searching for classes (tokenizing).

Found 20 classes, added 20 of them to the autoload array.


=> so the extension are activated
and the extensions autoload regenerated


Next step should be the initialisation of the database.


C:\wamp\www\ezpublish-4.1.3>php bin/php/ezsqlinsertschema.php --type=oracle --us
er=EZPUBLISH --password=EZPUBLISH share/db_schema.dba XE11
Could not initialize database:
* Tried database 'XE11' locally with user 'EZPUBLISH' and with a 'EZPUBLISH'
* No database handler was found for 'oracle'


but I have the same message than before ?


Up

Gaetano Giunta

Member since:
30 November 1999

Posts: 269

Tuesday 23 June 2009 7:25:44 pm

Can you verify that:

1 - in settings/override/site.ini.append.php you have this:
[ExtensionSettings]
ActiveExtensions[]
...
ActiveExtensions[]=ezoracle
...

2 - in var/autoload/ezp_extension.php you have this:
...
'eZOracleDB' => 'extension/ezoracle/ezdb/dbms-drivers/ezoracledb.php',
...

If point 1 is false, you will have to add that line and rerun ezpgenerateautoloads.php

Principal Consultant International Business
Member of the Community Project Board

Up

dada Mr

Member since:
23 June 2009

Posts: 5

Wednesday 24 June 2009 10:16:21 am

Ok tanks for your answer.

My site.ini.append.php is situated i folder settings/override/



<?php 

ExtensionSettings]


ActiveExtensions[]


ActiveExtensions[]=ezoracle


?>




this file contains only 3 lines ??

I run >php bin/php/ezpgenerateautoloads.php


I add ( and verify it exists ) 'eZOracleDB' => 'extension/ezoracle/ezdb/dbms-drivers/ezoracledb.php',

in var/autoload/ezp_extension.php.

I launch
php bin/php/ezsqlinsertschema.php --type=oracle --us
er=EZPUBLISH --password=EZPUBLISH share/db_schema.dba XE11
Could not initialize database:
* Tried database 'XE11' locally with user 'EZPUBLISH' and with a 'EZPUBLISH'
* No database handler was found for 'oracle'

??
Up

Gaetano Giunta

Member since:
30 November 1999

Posts: 269

Wednesday 24 June 2009 10:32:13 am




<?php


ExtensionSettings]


ActiveExtensions[]


ActiveExtensions[]=ezoracle


?>




Yoi miss an opening bracket in there (unless that was justa typo when pasting to the web):
ExtensionSettings] => [ExtensionSettings]

Principal Consultant International Business
Member of the Community Project Board

Up

dada Mr

Member since:
23 June 2009

Posts: 5

Wednesday 24 June 2009 10:57:37 am

Exact I've done a mistake.thx.

I run again the ezpgenerateautoloads.php

it displays 54 php files instead of 52


Scan complete. Found 54 PHP files.

Searching for classes (tokenizing).

Found 22 classes, added 22 of them to the autoload array.


Now the ezp_extension.php generated is correct :)

<?php
/**
* Autoloader definition for eZ Publish Extension files.
*
* @copyright Copyright (C) 1999-2009 eZ Systems AS. All rights reserved.
* @license http://ez.no/licenses/gnu_gpl GNU GPL v2
* @version //autogentag//
* @package kernel
*
*/

return array(
'EnchantSpell' => 'extension/ezoe/modules/ezoe/classes/EnchantSpell.php',
'GoogleSpell' => 'extension/ezoe/modules/ezoe/classes/GoogleSpell.php',
'Moxiecode_JSON' => 'extension/ezoe/modules/ezoe/classes/utils/mcejson.php',
'Moxiecode_JSONReader' => 'extension/ezoe/modules/ezoe/classes/utils/mcejson.php',
'PSpell' => 'extension/ezoe/modules/ezoe/classes/PSpell.php',
'PSpellShell' => 'extension/ezoe/modules/ezoe/classes/PSpellShell.php',
'SpellChecker' => 'extension/ezoe/modules/ezoe/classes/SpellChecker.php',
'eZOEAjaxContent' => 'extension/ezoe/classes/ezoeajaxcontent.php',
'eZOEInputParser' => 'extension/ezoe/ezxmltext/handlers/input/ezoeinputparser.php',
'eZOEPacker' => 'extension/ezoe/autoloads/ezoepacker.php',
'eZOEPackerFunctions' => 'extension/ezoe/classes/ezoepackerfunctions.php',
'eZOETemplateUtils' => 'extension/ezoe/autoloads/ezoetemplateutils.php',
'eZOEXMLInput' => 'extension/ezoe/ezxmltext/handlers/input/ezoexmlinput.php',
'eZOOConverter' => 'extension/ezodf/classes/ezooconverter.php',
'eZOOGenerator' => 'extension/ezodf/classes/ezoogenerator.php',
'eZOOImport' => 'extension/ezodf/classes/ezooimport.php',
'eZOpenofficeUploadHandler' => 'extension/ezodf/uploadhandlers/ezopenofficeuploadhandler.php',
'eZOracleDB' => 'extension/ezoracle/ezdb/dbms-drivers/ezoracledb.php',
'eZOracleSchema' => 'extension/ezoracle/ezdb/dbms-schema/ezoracleschema.php',
'eZRESTODFHandler' => 'extension/ezodf/classes/ezrestodfhandler.php',
'ezodfInfo' => 'extension/ezodf/ezinfo.php',
'ezoeInfo' => 'extension/ezoe/ezinfo.php',
);

?>

but the have still the same problem.

C:\wamp\www\ezpublish-4.1.3>php bin/php/ezsqlinsertschema.php --type=oracle --u
er=EZPUBLISH --password=EZPUBLISH share/db_schema.dba XE11
Could not initialize database:
* Tried database 'XE11' locally with user 'EZPUBLISH' and with a 'EZPUBLISH'
* No database handler was found for 'oracle'

Up

Vidar Langseid

Member since:
11 March 2003

Posts: 3

Tuesday 30 June 2009 2:10:07 pm

Hi

The actual name of the db handler is ezoracle, not oracle. A temporary fix is available here: http://issues.ez.no/IssueView.php?Id=15109
Up

You need to be logged in to post messages in the forums. New users may register here.