Timeline for Count the rows with same ID in php
Current License: CC BY-SA 3.0
9 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Jun 17, 2015 at 14:27 | answer | added | spencer7593 | timeline score: 2 | |
| Jun 17, 2015 at 14:25 | vote | accept | Floeske | ||
| Jun 17, 2015 at 14:20 | comment | added | Benno Eggnauer | For your query, the group by is not required, you count all rows given by the where clause. | |
| Jun 17, 2015 at 14:19 | comment | added | spencer7593 | It looks like the problem you are reporting is that you expect a count of 2 to be returned, but the count is returning 1. I think what this means is that the two occurrences of C# appear to be the same to you, but they are actually different values, likely due to "hidden" whitespace characters in one of the values. As a test, try a query like SELECT curs_code, HEX(curs_code), CHAR_LENGTH(curs_code) FROM cursus WHERE curs_code LIKE '%C#%'. | |
| Jun 17, 2015 at 14:18 | answer | added | Alexandre | timeline score: 3 | |
| Jun 17, 2015 at 14:16 | comment | added | Floeske | How do you mean group? | |
| Jun 17, 2015 at 14:16 | comment | added | b14r | I think you need to GROUP the results, google it :) | |
| S Jun 17, 2015 at 14:09 | review | Triage | |||
| Jun 17, 2015 at 14:10 | |||||
| S Jun 17, 2015 at 14:09 | history | asked | Floeske | CC BY-SA 3.0 |