Current location: Hot Scripts Forums » Programming Languages » PHP » Temporary Data Storage


Temporary Data Storage

Reply
  #1 (permalink)  
Old 02-21-05, 02:19 AM
eddyvlad eddyvlad is offline
Wannabe Coder
 
Join Date: Sep 2003
Location: In The Bloody Pits Of Hell
Posts: 160
Thanks: 2
Thanked 0 Times in 0 Posts
Temporary Data Storage

I've developed a script consisting PHP and MYSQL to read the binary data of a Microsoft Excel document (.xls), display them in a table, user is to select the column type and click submit for all the data to be loaded into the database. Unlike using COM (rarely works on all computer), I've used an opensource library (in php also) which can read the binary data and convert it to readable format.
One main disadvantage of using that method, it is very slow. I'm talking about 5mb of excel data with more than 5000 rows. It took me about 3 mins to load the data into tables.
What I'm thinking is to load the data into a temporary storage so user can browse by showing only 100 rows per page. So each sheet will be divided into pages. I can't do that with the current method because going to the next page means waiting for another 3mins. I was thinking of using session. But loading 5000 rows (More than 5mb) into a session? Do you think it's a good idea? Another method is to write the data into a text file, since text file is not binary, it will be much faster. But it's a hassle to do the codes to write and retrieve that data. readdir, read, fopen..... *phew* that's alot....

So err.... is session a good idea? Can I store loads of data into session array and still have a faster output?
__________________
Mr. Brown Eyes
Reply With Quote
  #2 (permalink)  
Old 02-21-05, 03:48 AM
NeverMind's Avatar
NeverMind NeverMind is offline
Community VIP
 
Join Date: Aug 2003
Location: K.S.A
Posts: 2,257
Thanks: 0
Thanked 2 Times in 1 Post
try ..
but what is this other method you used for reading binary data? because we can't advise if we don't know what you are talking about?
__________________
PHPSimplicity
We don't need a reason to help people - Zidane [FF9]
Reply With Quote
  #3 (permalink)  
Old 02-21-05, 09:36 AM
eddyvlad eddyvlad is offline
Wannabe Coder
 
Join Date: Sep 2003
Location: In The Bloody Pits Of Hell
Posts: 160
Thanks: 2
Thanked 0 Times in 0 Posts
I don't have any other method. I'm afraid I have to make alot of changes on my script. Because my current script is very very slow. I would like to distribute the script so others can improve on it. Furthermore, I couldn't find any other scripts like mine being freely distributed. Also, since I used open source library, it's fair that I make mine open source too. But my script has too much preconfigured settings meant for my work server and database. So it's not distributable yet.
__________________
Mr. Brown Eyes
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
MLS Data Retrieval dotcomtim Job Offers & Assistance 0 11-26-04 05:09 PM
Problem getting data from DataGrid on update petersza ASP.NET 5 10-19-04 11:37 PM
How to Extract Intra Day Stock Price Data from Java Chart??? (only source of data!!) omkarsnisal Everything Java 0 10-29-03 02:25 AM
Print data by date perleo PHP 2 08-09-03 09:35 AM


All times are GMT -5. The time now is 05:33 AM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.