473,408 Members | 2,734 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

MultiDimensional Array Count

This is how my db structure looks, i have around 350 rows like this one below each with a different number of comment_list and likes from friends.


All i want is a query that counts how many times each variable comes up in the db.

For example if we ran the query in this script we would get:

1.) 65653171 (3 Times)
2.) 67418530 (1 Time )

etc...

Any Ideas???


Expand|Select|Wrap|Line Numbers
  1.  [0] => Array
  2.  
  3.                 (
  4.                     [viewer_id] => 65653171
  5.                     [source_id] => 65653171
  6.                     [actor_id] => 65653171
  7.                     [comments] => Array
  8.  
  9.                         (
  10.  
  11.                             [comment_list] => Array
  12.                                 (
  13.                                     [0] => Array
  14.                                         (
  15.                                             [fromid] => 67418530
  16.                                         )
  17.                                     [1] => Array
  18.                                         (
  19.                                             [fromid] => 108832181
  20.                                         )
  21.                                 )
  22.                         )
  23.  
  24.                     [likes] => Array
  25.  
  26.                        (
  27.                             [friends] => Array
  28.                             (
  29.                                 [0] => 58579401
  30.                                 [1] => 55125266
  31.                                 [2] => 57449386
  32.                                 [3] => 60906602
  33.                                 )
  34.                             )
  35.                         )
  36.  
Nov 3 '09 #1
1 1745
code green
1,726 Expert 1GB
Any Ideas
Not really,I don't understand. Maybe the bold text is is too distracting.
This is how my db structure looks
You have posted a 2d array
All i want is a query that counts how many times each variable comes up in the db.
Where are the variables? And why would you want to count variables?
Nov 4 '09 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: janetb | last post by:
I have the value of checkboxes coming into an asp page. All checkboxes have the same name and the same number of values: e.g. jid(1) = 1,4,38 jid(2) = 18,233,0 etc. How do I put the above...
7
by: bijax | last post by:
hi, i am new to multidimensional array of c programming .pls help me to solve out this how to allocate memory for mutidimensional array? i.e a ;
1
by: Mark Smith | last post by:
I'm trying to copy data from a 1D array to a 2D array. The obvious thing doesn't work: int twoDee = new int; int oneDee = new int { 1, 2 }; Array.Copy(oneDee, 2, twoDee, 2, 2); This causes a...
2
by: chris | last post by:
Hi there, I created a Multidimensional array of labels Label lblMultiArray = new Label { {Label3, LblThuTotal}, {Label4,LblFriTotal} }; Now I would like to compare the values in the array,...
10
by: | last post by:
I'm fairly new to ASP and must admit its proving a lot more unnecessarily complicated than the other languages I know. I feel this is because there aren't many good official resources out there to...
1
by: Chuy08 | last post by:
If I have a multidimensional array like the following: Array $records =Array 0 = 30 year, 6.0; 1 = 30 year, 6.0; 2 = Pay Option, 1.0; 3 = Pay Option, 1.0; How could I flatten this to...
2
by: mareharbor | last post by:
Can anyone help me to change this array to a multidimensional array with 1 more components i want to add another "column" to the array with a similiar specification of "cell.Offset(0, -2).Value". So,...
5
by: LittleCake | last post by:
Hi All, I have a multidimensional array where each sub-array contains just two entries, which indicates a relationship between those two entries. for example the first sub-array: =Array ( =30...
4
Jezternz
by: Jezternz | last post by:
First of all I am open to any suggestions and advice. If a javscript multidimensional array is a bad way to do this please say so. I considered XML but I wondered if this would be a bad idea as it...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.