Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2

Thread: Propel Building

  1. #1
    Regular Coder
    Join Date
    Apr 2005
    Location
    Ireland
    Posts
    122
    Thanks
    4
    Thanked 0 Times in 0 Posts

    Propel Building

    Hi

    I recently installed Propel using PEAR.

    I created a folder("Project") and and put my schema.xml, build.properties and runtime-conf.xml files in the folder.

    Running the following command then created all the necessary classes, etc.
    C:\Project> propel-gen

    I deleted this folder and files and am trying to set it up in a new site im developing as follows:

    C:\Site\DAO> propel-gen

    I get the following error:
    Code:
    Execution of target "sql-template" failed for the following reason: C:\PHP\data\propel_generator\build-propel.xml:198:1:
     No schema files were found (matching your schema fileset definition).
    [phingcall] C:\PHP\data\propel_generator\build-propel.xml:198:1: No schema files were found (matching your schema filese
    t definition).
    Execution of target "sql" failed for the following reason: C:\PHP\data\propel_generator\build-propel.xml:182:22: Executi
    on of the target buildfile failed. Aborting.
    [phingcall] C:\PHP\data\propel_generator\build-propel.xml:182:22: Execution of the target buildfile failed. Aborting.
    Execution of target "main" failed for the following reason: C:\PHP\data\propel_generator\build-propel.xml:92:22: Executi
    on of the target buildfile failed. Aborting.
        [phing] C:\PHP\data\propel_generator\build-propel.xml:92:22: Execution of the target buildfile failed. Aborting.
    build.properties:
    Code:
    # set the paths to the Propel installation, your project home and your
    # build files
    project.home = C:\Site\DAO
    project.build = ${project.home}/build
    
    # set some basic properties for the project and the database connection
    propel.project = Site
    propel.database = mysql
    propel.targetPackage = 
    propel.database.url = mysql://root:@localhost/Site
    propel.mysql.tableType = InnoDB
    
    # set the directories for the schema.xml and the runtime-conf.xml files 
    # and the path to the template files that Propel uses
    propel.schema.dir = ${project.build}
    propel.conf.dir = ${project.build}
    propel.templatePath = ${propel.home}/templates
    
    # set the directories for the generated output, i.e. the data object classes, a
    # PHP file with the configuration data and the SQL files
    propel.output.dir = ${project.home}
    propel.php.dir = ${propel.output.dir}/classes
    propel.phpconf.dir = ${propel.output.dir}/config
    propel.sql.dir = ${project.build}/sql
    
    # set the name for the configuration file
    propel.runtime.phpconf.file = propel-config.php

    runtime-conf.xml
    Code:
    <?xml version="1.0" encoding="ISO-8859-1"?>
    
    <config>
      <propel>
      <datasources default="site">
       <datasource id="site"> <!-- this ID must match <database name=""> in schema.xml -->
        <adapter>mysql</adapter> <!-- sqlite, mysql, myssql, oracle, or pgsql -->
        <connection>
         <dsn>mysql:host=localhost;dbname=bookstore</dsn> <!-- the PDO connection DSN for database -->
         <user>root</user>
         <password>password</password>
        </connection>
       </datasource>
      </datasources>
     </propel>
    </config>

    Any help would be greatly appreciated.
    Last edited by tom123; 10-08-2009 at 09:08 PM.

  • #2
    Regular Coder
    Join Date
    Apr 2005
    Location
    Ireland
    Posts
    122
    Thanks
    4
    Thanked 0 Times in 0 Posts
    Even any remote idea guys?
    My head is balck and blue at this stage from banging it off the wall!


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •