likely it looks like this: 21-JUN-2009. So when doctrine inserts
format and you get an exception. To get around this problem you can
$connection->setDateFormat(). Ideally doctrine should automatically
> What is the query that is failing? Can you debug it a bit and see
> what you can find?
> Thanks, Jon
> On Jun 19, 8:09 am, Tom808 <thomas_80...@yahoo.com> wrote:
> > Dear Jon,
> > thank you very much for your prompt response.
> > It took a moment to allow the server to connect to our proxy...
> > The problem (_seq vs. _SEQ) is now fixed with the last branch from SVN
> > - thanks a lot.
> > But i run in the next one:
> > Inserting a record i a table with actAs: Timestampable cause the
> > following error:
> > schema.yml:
> > atable:
> > actAs: [Timestampable]
> > columns:
> > acolumn: string(255)
> > php:
> > $atable = new atable();
> > $atable->acolumn = 'foo';
> > $atable->save();
> > PHP Fatal error: Uncaught exception
> > 'Doctrine_Connection_Oracle_Exception' with message 'SQLSTATE[HY000]:
> > General error: 1861 OCIStmtExecute: ORA-01861: literal does not match
> > format string
> > (/tmp/PDO_OCI-1.0/oci_statement.c:142)' in /srv/www/htdocs/test_doc/
> > svn/1.1/lib/Doctrine/Connection.php:1084
> > Stack trace:
> > #0 /srv/www/htdocs/test_doc/svn/1.1/lib/Doctrine/Connection/
> > Statement.php(253): Doctrine_Connection->rethrowException(Object
> > (PDOException), Object(Doctrine_Connection_Statement))
> > #1 /srv/www/htdocs/test_doc/svn/1.1/lib/Doctrine/Connection.php(1049):
> > Doctrine_Connection_Statement->execute(Array)
> > #2 /srv/www/htdocs/test_doc/svn/1.1/lib/Doctrine/Connection.php(693):
> > Doctrine_Connection->exec('INSERT INTO ata...', Array)
> > #3 /srv/www/htdocs/test_doc/svn/1.1/lib/Doctrine/Connection/
> > UnitOfWork.php(595): Doctrine_Connection->insert(Object
> > (Doctrine_Table), Array)
> > #4 /srv/www/htdocs/test_doc/svn/1.1/lib/Doctrine/Connection/
> > UnitOfWork.php(549): Doctrine_Connection_UnitOfWork->processSingleInsert(Object(atable))
> > #5 in /srv/www/htdocs/test_doc/svn/1.1/lib/Doctrine/Connection.php on
> > line 1084
> > Kind regards
> > Thomas
> > On Jun 19, 12:14 pm, Jonathan Wage <jonw...@gmail.com> wrote:
> > > I fixed this in the latest SVN. Can you try using the latest 1.1 branch of
> > > Doctrine and let me know.
> > > I've dedicated a lot of time recently to fine tuning the integration between
> > > Doctrine and oracle and would love to work with you to help fix any other
> > > small problems.
> > > Thanks, Jon
> > > On Fri, Jun 19, 2009 at 5:12 AM, Tom808 <thomas_80...@yahoo.com> wrote:
> > > > Hello,
> > > > using the follwoing schema.yml with Doctrine 1.1.2
> > > > atest:
> > > > columns:
> > > > aname: string(255)
> > > > and
> > > > Doctrine::generateModelsFromYaml('schema.yml', 'models');
> > > > Doctrine::createTablesFromModels('models');
> > > > will create the trigger and sequence as followed below.
> > > > The trigger tries to select ATEST_seq but the sequence name ist
> > > > ATEST_SEQ. Trying to insert a record does cause
> > > > ORA-01403: no data found
> > > > ORA-06512: at "DOC.ATEST_AI_PK", line 9
> > > > ORA-04088: error during execution of trigger 'DOC.ATEST_AI_PK
> > > > After manualy changin the trigger code to ATEST_SEQ" everthing works
> > > > fine. Is there any way to solve this issue?
> > > > Kind regards
> > > > Tom
> > > > CREATE SEQUENCE "ATEST_SEQ" MINVALUE 1 MAXVALUE
> > > > 999999999999999999999999999 INCREMENT BY 1 START WITH 1 NOCACHE
> > > > NOORDER NOCYCLE
> > > > create or replace TRIGGER ATEST_AI_PK
> > > > BEFORE INSERT
> > > > ON ATEST
> > > > FOR EACH ROW
> > > > DECLARE
> > > > last_Sequence NUMBER;
> > > > last_InsertID NUMBER;
> > > > BEGIN
> > > > SELECT ATEST_seq.NEXTVAL INTO :NEW.id FROM DUAL;
> > > > IF (:NEW.id IS NULL OR :NEW.id = 0) THEN
> > > > SELECT ATEST_seq.NEXTVAL INTO :NEW.id FROM DUAL;
> > > > ELSE
> > > > SELECT NVL(Last_Number, 0) INTO last_Sequence
> > > > FROM User_Sequences
> > > > WHERE Sequence_Name = 'ATEST_seq';
> > > > SELECT :NEW.id INTO last_InsertID FROM DUAL;
> > > > WHILE (last_InsertID > last_Sequence) LOOP
> > > > SELECT ATEST_seq.NEXTVAL INTO last_Sequence FROM DUAL;
> > > > END LOOP;
> > > > END IF;
> > > > END;
> > > --
> > > Jonathan H. Wage (+1 415 992 5468)
> > > Open Source Software Developer & Evangelist
> > > sensiolabs.com | jwage.com | doctrine-project.org | symfony-project.org
> > > You can contact Jonathan about Doctrine, Symfony and Open-Source or for
> > > training, consulting, application development, or business related questions
> > > at jonathan.w...@sensio.com- Hide quoted text -
> > > - Show quoted text -