node to traverse cannot be null (Hibernate SQL)
- by tiswas
I'm performing a SQL query through hibernate, which looks like:
SELECT thi
FROM track_history_items thi
JOIN artists art
ON thi.artist_id = art.id
WHERE thi.type = "TrackBroadcast"
GROUP BY art.name
ORDER thi.createdAt DESC
but I'm getting the message that 'Node to traverse cannot be null!'. Anyone know what could be causing this?
--EDIT--
I'm pretty sure that this problem is being caused by the possibility of artist_id to be null. However, I can't prevent this, so can I just skip the rows track_history_item rows which have a null artist_id?