Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [ZF] PDO_SQLITE - problem z primary key
localhost
post
Post #1





Grupa: Zarejestrowani
Postów: 1
Pomógł: 0
Dołączył: 22.11.2006

Ostrzeżenie: (0%)
-----


tabela:
Kod
CREATE TABLE `sections` (
  `sid` int(11) NOT NULL auto_increment,
  `name` varchar(50) NOT NULL,
  `content` text NOT NULL,
  `position` int(11) NOT NULL default '0',
  PRIMARY KEY  (`sid`)
)

model:
Kod
class Sections extends Zend_Db_Table_Abstract
{  
    protected $_name = 'sections';
    protected $_primary = 'sid';
[...]
}

Gdy używam PDO_SQLITE dostaje error:
Kod
Fatal error: Uncaught exception 'Zend_Db_Table_Exception' with message 'Primary key column(s) (sid) are not columns in this table ()'

W przypadku PDO_MYSQL wszystko śmiga. Co może być nie tak?

Pozdrawiam.
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 19.08.2025 - 18:38