mysql - eloquent query doesn't work properly -


i'm trying query mysql database eloquent laravel doesn't work.

user::where('id', 1)->first() 

however when try sql query works.

db::table('users')->first() 

thanks in advance.

may didn't use user namespace. if not, use user model namespace in controller.


Comments

Popular posts from this blog

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -