Multiple arrays inside data


Posted on 16th Feb 2014 07:03 pm by admin

Hi,

Simple question. I have a column called "array" in my database, and inserted into each field is the following imploded array:
Code: mctriangle,570.65,355.1,1,1,0

It is an instance of an object. Each field in each row contains this information as an imploded array.

[0] = Name
[1] = X Axis
[2] = Y Axis
[3] = ScaleX
[4] = ScaleY
[5] = Rotation

When extracted from the database, it is exploded back into the array above.

As you can see, I would need to store a lot of rows for each object. Say we use 200 objects, thats 200 rows, which would be hard to search through.

My question is: Could I store multiple imploded arrays inside 1 row only. E.g:

mctriangle,570.65,355.1,1,1,0&&mctriangle,570.65,355.1,1,1,0&&mctriangle,570.65,355.1,1,1,0&&mctriangle,570.65,355.1,1,1,0&&mctriangle,570.65,355.1,1,1,0

The above would be 5 objects in one row of data, each imploded array separated by &&. How would I go about doing such a thing?

Thanks!

No comments posted yet

Your Answer:

Login to answer
291 Like 19 Dislike
Previous forums Next forums
Other forums

Question about the upload of large files
Hi there,

I have a question about the upload of large files, like videos (files generally abo

UDP Multicast question
Hey,

Im not really in the know when it comes to network related programming and activitie

Random date selection
i want to select random date with time(hour+minutes+sec) where date is specified(10/22/2009) and tim

PHP and XML image gallery variable issue
I'm trying to display the large image on the same page as the thumbnails, to do that I'm passing a v

printing links
Hi every1

i am connecting to a table in sql and the looping through with a while ($ var = my

Grouping and sorting results
Please help with this query.

I have 2 tables in a database, countires and cities. states look

Using Windows message as a Handle
Hi,

I am writing one of my first multithreaded programs.

In one of the thread,

parse error
On my local machine I keep getting parse error for my footer. When I put it online, it doesn't show

What am I missing here? Help!
Hello all!. I can't seem to get this working right. Well - it renders right, but something is goin

Include ("Absolute Path") of a file?
I'm not sure what I'm doing wrong. I am writing my php code in the same directory of the file that

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash