主义中未知的列类型“ nvarchar2”

时间:2019-01-30 12:49:42

标签: oracle doctrine symfony-2.3

我想要一个多语言列,所以我想添加一个“ NVARCHAR2”类型列,但是当我这样做时,我得到了:

Unknown column type "nvarchar2" requested. Any Doctrine type that you use has to be registered with \Doctrine\DBAL\Types\Type::addType(). You can get a list of all the known types with \Doctrine\DBAL\Types\Type::getTypesMap(). If this error occurs during database introspection then you might have forgotten to register all database types for a Doctrine Type. Use AbstractPlatform#registerDoctrineTypeMapping() or have your custom types implement Type#getMappedDatabaseTypes(). If the type name is empty you might have a problem with the cache or forgot some mapping information. 

我的代码:

/**
 * @var string
 *
 * @ORM\Column(name="name", type="nvarchar2", length=255, nullable=true)
 */
protected $translation;

我真的不明白为什么我不能使用“ nvarchar2”作为列类型

0 个答案:

没有答案