{"action":"opened","issue":{"url":"https://api.github.com/repos/lazychaser/laravel-nestedset/issues/93","repository_url":"https://api.github.com/repos/lazychaser/laravel-nestedset","labels_url":"https://api.github.com/repos/lazychaser/laravel-nestedset/issues/93/labels{/name}","comments_url":"https://api.github.com/repos/lazychaser/laravel-nestedset/issues/93/comments","events_url":"https://api.github.com/repos/lazychaser/laravel-nestedset/issues/93/events","html_url":"https://github.com/lazychaser/laravel-nestedset/issues/93","id":143009794,"number":93,"title":"withDepth doesn't work if tables have prefixes.","user":{"login":"chaotixlv","id":10274629,"avatar_url":"https://avatars.githubusercontent.com/u/10274629?v=3","gravatar_id":"","url":"https://api.github.com/users/chaotixlv","html_url":"https://github.com/chaotixlv","followers_url":"https://api.github.com/users/chaotixlv/followers","following_url":"https://api.github.com/users/chaotixlv/following{/other_user}","gists_url":"https://api.github.com/users/chaotixlv/gists{/gist_id}","starred_url":"https://api.github.com/users/chaotixlv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chaotixlv/subscriptions","organizations_url":"https://api.github.com/users/chaotixlv/orgs","repos_url":"https://api.github.com/users/chaotixlv/repos","events_url":"https://api.github.com/users/chaotixlv/events{/privacy}","received_events_url":"https://api.github.com/users/chaotixlv/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-03-23T16:27:12Z","updated_at":"2016-03-23T16:27:12Z","closed_at":null,"body":"Im using prefix for tables and when I try to get all nodes with depth it returns this error\r\n\r\n`SQLSTATE[42S22]: Column not found: 1054 Unknown column '_d._lft' in 'where clause' (SQL: select *, (select count(1) - 1 from `prx_table` as `sta__d` where `prx_table`.`_lft` between _d.`_lft` and _d.`_rgt`) as `depth` from `prx_table` where `prx_table`.`deleted_at` is null)`\r\n\r\nCode in controller\r\n\r\n`$cats = Forum::withDepth()->get();\r\n$cats->linkNodes();\r\n$categories = $cats->toTree();`\r\n\r\nWithout ` withDepth` everything works fine"}}