DEV Community

Hmaier Jihen
Hmaier Jihen

Posted on

How to Get data in mutiple @ManyToMany in Nest.js

I have a ManyToMany relation between two entities and I don't know how can I Get data from the join table "device_users_user"

@Entity()
export class Device{

  @PrimaryColumn()
  Name:string;


  @Column({ nullable: true})
  Port:number;

  @Column({ nullable: true})
  IPadress:string;

  @Column({ nullable: true})
  Location:string;

  @ManyToMany(type => User)
    @JoinTable()
    users: User[];

  }
@Entity()
export class

Top comments (0)