Doctrine Project

  • Log In Access more options
    • Online Help
    • Keyboard Shortcuts
    • About JIRA
    • JIRA Credits
    • What’s New
  • Dashboards Access more options (Alt+d)
  • Projects Access more options (Alt+p)
  • Issues Access more options (Alt+i)
Doctrine 2 - ORM
  • Doctrine 2 - ORM
  • DDC-874

orm:convert-mapping

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: Bug Bug
  • Status: Resolved Resolved
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 2.0-BETA4
  • Fix Version/s: 2.0.1, 2.1
  • Component/s: ORM
  • Security Level: All
  • Labels:
    None
  • Environment:
    Ubuntu 10.10.

Description

I have a Postgres SQL database.
The Base has only one table "User" with two attributes (name and id).
"Id" is primary key.

The failure to execute the task:
php orm doctrine: convert-mapping - from-database yml / home / cristian / database.yml

is:

[Doctrine \ ORM \ Mapping \ MappingException]
No identifier / primary key for Specified Entity 'User'. Every Entity must have for an identifier / primary key

Script to create the table:

CREATE TABLE "User"
(
id serial NOT NULL,
name character varying (55),
CONSTRAINT "User_pkey" PRIMARY KEY (id)
)
WITH (
OIDS = FALSE
)
ALTER TABLE "User" OWNER TO postgres;

  • Options
    • Show All
    • Show Open
Progress
Resolved Sub-Tasks

Sub-Tasks

1.
A index has to be named as "primary" to be detected Doctrine\ORM\Mapping\Driver\DatabaseDriver::loadMetadataForClass() Sub-task Resolved Resolved Benjamin Eberlei
 

Activity

  • All
  • Comments
  • History
  • Activity
  • Source
Hide
Permalink
Benjamin Eberlei added a comment - 30/Dec/10 5:20 PM

Fixed in DDC-929

Show
Benjamin Eberlei added a comment - 30/Dec/10 5:20 PM Fixed in DDC-929

People

  • Assignee:
    Benjamin Eberlei
    Reporter:
    Cristian Rinaldi
Vote (0)
Watch (0)

Dates

  • Created:
    10/Nov/10 2:36 PM
    Updated:
    30/Dec/10 5:20 PM
    Resolved:
    30/Dec/10 5:20 PM
  • Atlassian JIRA (v5.2.7#850-sha1:b2af0c8)
  • Report a problem
  • Powered by a free Atlassian JIRA open source license for Doctrine Project. Try JIRA - bug tracking software for your team.