Linked Questions
22 questions linked to/from MySQL : isn't in GROUP BY
-1 votes
1 answer
395 views
isn't in GROUP BY with DAY, MONTH, YEAR [duplicate]
I'm have trouble with having to work with ONLY_FULL_GROUP_BY mode (I wouldn't want to, but I'm forced to). The problem is that this requires me to include a column in the group by clause. This is a ...
0 votes
2 answers
144 views
Table to view with group_concat [duplicate]
I have the following table and i want to generate a view. See the result. How can i achieve that? I tried with group_cat but that doesnt work :( id product_id cat_id date 1 1 1 2018-05-...
0 votes
0 answers
233 views
PhpMyAdmin Error #1055 Message [duplicate]
I'm getting this message everytime I click on the Databases tab up top. Clicking on the error message's Edit link takes me to the SQL Queries section where it shows the SQL query that's listed on the ...
0 votes
1 answer
178 views
Laravel: Query works directly on MySQL but not on DB [duplicate]
I have the following query: SELECT cn.id, cn.title, cn.type, cn.status FROM ( SELECT v.concert_id as concert_id, SUM(v.position_votes + v.support_votes) as votes FROM ( SELECT q....
0 votes
1 answer
59 views
How to use Group By with Join table in laravel [duplicate]
When execute my query , I get error message like below. $ads = DB::table('ads') ->join('adimages','adimages.ad_id','=','ads.id') ->select( 'adimages.ad_id', ...
901 votes
38 answers
1.9m views
Disable ONLY_FULL_GROUP_BY
I accidentally enabled ONLY_FULL_GROUP_BY mode like this: SET sql_mode = 'ONLY_FULL_GROUP_BY'; How do I disable it?
2 votes
4 answers
14k views
A.* isn't in GROUP BY with left join on laravel query builder
$search_alls= DB::table('a16s as A') ->select('A.id') // ->select('A.*') ->addSelect(DB::raw('SUM(CASE WHEN B.approve = 1 ELSE 0 END) as Yshow')) ->leftjoin('a16s_likes ...
1 vote
3 answers
6k views
get total count in each ids from different table in laravel
i want to get each id's total count from another table named assign job. i saved user data into my users table and i add 3 jobs into assign job table with user id. but now i want to get total added ...
3 votes
1 answer
1k views
Displaying Notifications Logic
I am building a social network with Laravel framework, and I have a Notifications System. Basically whenever a user interacts with the website in these 5 different ways: User upvotes a Post. User ...
1 vote
2 answers
2k views
Laravel Eloquent Multiple Where with count
Following is the SQL query that I need to perform on laravel eloquent. SQL returns expected output. SELECT orders.id, orders.`status`, order_type, COUNT(order_type) as count FROM orders ...
0 votes
0 answers
2k views
phpmyadmin: #1055 - 'information_schema.s.SCHEMA_NAME' isn't in GROUP BY
I am getting the following error in PHPMyAdmin when I attempt to do click "Databases" tab: #1055 - 'information_schema.s.SCHEMA_NAME' isn't in GROUP BY Please advise on what code in phpmyadmin file ...
0 votes
2 answers
1k views
Create variable based query to select data in laravel
I created a helper function for count all notification in navbar, For this I am storing clause in a single variable. I am accessing it by calling- countData("notification","WHERE ...
1 vote
3 answers
1k views
Which laravel query to use to sort top entries according to related table
I have two models: posts and likes. Posts and likes have one-to-many relationship (so, one post has many likes). Likes model has also an isActive field which shows liking is active or passive. I want ...
0 votes
1 answer
644 views
Stored Procedure ER_WRONG_FIELD_WITH_GROUP
I have the following problem in a stored procedure: {"code":"ER_WRONG_FIELD_WITH_GROUP","errno":1055,"sqlState":"42000","index":0} Initially I suspected that it was the passing of parameters that ...