Coming soon - Get a detailed view of why an account is flagged as spam!
view details

This post has been de-listed

It is no longer included in search results and normal feeds (front page, hot posts, subreddit posts, etc). It remains visible only via the author's post history.

2
[Semantical Error] line 0, col 64 near 'k': Error: Class App\Entity\.... has no association named .......
Author Summary
MaMe91 is in Semantical Error
Post Body

I am trying to join two tables to do a query:

public function findByFile_Ref_Id($query) {

$query = $query['ids'];

$q = $this->createQueryBuilder('h');

$result = $q

->leftJoin('h.file_ref_id', 'k')

//->add('where', $q->expr()->in('k.product_code', $query))

->getQuery()

->getResult();

//dump($result);die;

return $result;

}

I'm using a many-to-one unidirectional association:

/**

* @ORM\ManyToOne(targetEntity="KstoreHikashopProduct", inversedBy="hikashopFile")

* @ORM\JoinColumn(name="file_ref_id", referencedColumnName="product_id")

* @ORM\Column(type="integer")

*/

private $file_ref_id;

how is this possible?! what am I doing wrong?

Author
Account Strength
80%
Account Age
6 years
Verified Email
Yes
Verified Flair
No
Total Karma
251
Link Karma
97
Comment Karma
154
Profile updated: 6 days ago
Posts updated: 2 months ago

Subreddit

Post Details

We try to extract some basic information from the post title. This is not always successful or accurate, please use your best judgement and compare these values to the post title and body for confirmation.
Posted
4 years ago