mysql - sql COUNT function returns an array instead of mysqli object? -
I want to count some lines in my database and I am using the following code:
$ tag name = person; Tagged as $ Query = "SELECT COUNT (thread_tag_map.tag_id) tag, thread_tag_map where thread_tag_map.tag_id = tags.id and tags.name = '$ tagname'"; $ Result = $ this- & gt; Do_query ($ query); Return result;
When I use print_r ($ result), it shows an associative array array ([tagcount]) => 3.
This is not a Mysquali object Should I use mysqli_fetch_assoc?
Can anyone explain?
The exact description depends on an API dependent on the programming language.
Comments
Post a Comment