Data-Mapper ORM for Ionic2, AngularJS, ( Hybrid Mobile Applications ), Supports WebSQL and SQLite databases. Currently in active development. - TypeORM Fork
I am trying to clear data from database table(entity). I tried using repository as well as entityManager for this but was unable to achieve this.
Using Repository:
let repository = connection.getRepository(<entityName>);
repository.remove(<entityName>);
Error: Given object does not have a primary column, cannot transform it to database entity.
Using Entity Manager:
let manager = connection.createEntityManager();
manager.remove(<entityName>);
Error: RepositoryNotFoundError: No repository for "Function" was found. Looks like this entity is not registered in current "dbConnectionName" connection?
I am trying to clear data from database table(entity). I tried using repository as well as entityManager for this but was unable to achieve this. Using Repository:
Error: Given object does not have a primary column, cannot transform it to database entity.
Using Entity Manager:
Error: RepositoryNotFoundError: No repository for "Function" was found. Looks like this entity is not registered in current "dbConnectionName" connection?
Any help?