Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

PHP - passing massive amount of data

Posted on 2011-03-23
2
Medium Priority
?
331 Views
Last Modified: 2012-05-11
My situation looks like this , i have a search screen where users enter search criteria, submit it
to the database and get the result. It could be even hundred thousand records.
User can select some or all of the records and go to next screen
Now on the next screen I want to show the details for each record one at a time, with  controls allowing to go to the next record. What is the best method to pass selected records on the previous screen ?. Save them to a file ?.
0
Comment
Question by:Rozamunda
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 9

Accepted Solution

by:
sshah254 earned 1000 total points
ID: 35202962
It depends on what you have and what you are dealing with.

Normally, one would not pull up all the data on the first screen ... only minimal data should be pulled up for the user to make selection of what she wants.

Once the selection is mad, some sort of identifier would be picked up and another call would be made to the db to retrieve all the necessary information on the second screen.

You can either do multiple calls ... or store the retrieved data in a file ... or session.  But if it is too much data, then you are asking for security / performance problems.

Ss
0
 
LVL 9

Expert Comment

by:AriMc
ID: 35202965
Passing hundreds of thousands of records to a single web-page doesn't sound like a good idea simply because it will take too much time to transfer the information from your server to the client and because the user will definitely not go through that kind of amount of data.

Traditionally in these situations the search outputs an error message saying something like "More than X records found, please refine the query" and then allow/force the user to do so.

0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Build an array called $myWeek which will hold the array elements Today, Yesterday and then builds up the rest of the week by the name of the day going back 1 week.   (CODE) (CODE) Then you just need to pass your date to the function. If i…
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Suggested Courses

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question