Page 1 of 2 12 LastLast
Results 1 to 10 of 20
  1. #1

    Default which is better/faster/efficient?


    problem:
    create a database table.
    view the data from the table you created previously.

    Solution A:

    create table and view the date in one single page (lets say 'pageA.php')

    Solution B;

    create a separate page for creating the table and another for viewing then just include the page for creating the table to the viewing page.


    pageA.php (for creating the database)
    pageB.php(for viewing the data. Includes pageA.php)


    which solution is best/faster/efficient?
    or will the result be the same?

    :> thank you.

  2. #2

    Default Re: which is better/faster/efficient?

    Hi. Some questions lng.

    How are you creating the table? Do you let the user create the table or is it pre-made? better/faster/more efficient in terms of what mn imo gipangita? bandwidth consumption? computer resources?

    Anyway, in your case. Best would be just make it one page. Unless you're going to add this to a later project. That would require more planning. Pero mrag assignment rmn ni tingai, dba? So yeah, this kind of thing is trivial for now. Mag diprensya ra jd na kung dako na kaayo imo database pero dli pd na masulbad ug lahi-lahi lng ug page. Ang search algorithm nmu ang imo planohon.

  3. #3

    Default Re: which is better/faster/efficient?

    I don't get it.

    pageA.php will create a database using the CREATE clause? or you meant inserting data in a table using the INSERT clause? Because you don't want people to click on links in your page that creates tables and databases.

    Depending on the bulk (how many forms/input boxes) and frequency (how many times do you enter these data in a period of time) of your data entry, if its not that much, merge the view and the data entry forms.

    If Bulk<Frequency = separate the form/input boxes with the view.
    If Frequency<Bulk = merge the form/input boxes with the view.

  4. #4

    Default Re: which is better/faster/efficient?

    better/faster/efficient in terms of processing time? PHP is procedural right? so i was thinking, would it be better/faster/efficient if another page processes the creation of the table.

    no forms are involved in either of the 2 pages. i won't let the user create the table. i create the table.

    and no, its not an assignment. :>

  5. #5

    Default Re: which is better/faster/efficient?

    This should give you synthetic results, but you have to do the experiment on your own to figure out which one is faster.

    Determine execution time in PHP - PHP code snippet - developer Fusion

  6. #6

    Default Re: which is better/faster/efficient?

    quick question, why put the creation of table logic in a php file? xensya na basin sayup ako question, but curious lang ko..

  7. #7

    Default Re: which is better/faster/efficient?

    Solution C

    Create the table beforehand, and just let your application display it.

  8. #8

    Default Re: which is better/faster/efficient?

    Quote Originally Posted by simoncpu View Post
    Solution C

    Create the table beforehand, and just let your application display it.
    This

    If kelangan jd ka mugamit ug PHP to create/insert data into the tables, I would use one page.

  9. #9

    Default Re: which is better/faster/efficient?

    follow-up question sa akoang previous na question..

    sakto ba akong sabot sa question ni ts na magbuhat ug table gamit ang php?
    or ang gi mean ni ts is gamit php to insert data/values to that table?

    so if magbuhat ug table gamit ang php ang gi mean ni ts --> wala ko ka gets ngano ing-anion?

    please enlighten me pud ky basin sayup ako panguta...

  10. #10

    Default Re: which is better/faster/efficient?

    @personalmgt: thnx for the link. I'll try it out.

    bale sulod sa php nga page nai sql to create the tables apil na insert2x. one time ra ang creation sa table. but ang insertion is balik2x. bale mura raman siyag temporary table gani.

    sorry kung lisud sabtun ang question >.<
    thank you for helping :>

  11.    Advertisement

Page 1 of 2 12 LastLast

Similar Threads

 
  1. Which is better older bands in Cebu or the New ones
    By janchrish in forum Music & Radio
    Replies: 75
    Last Post: 05-15-2009, 02:39 AM
  2. amd 64 3000+ (939) or P4 3.0ghz? which is better?
    By juan_carlos in forum Computer Hardware
    Replies: 62
    Last Post: 05-16-2007, 07:21 PM
  3. Which is better...???
    By afortaliza in forum Computer Hardware
    Replies: 8
    Last Post: 05-07-2006, 01:42 AM
  4. Internal or External TV Tuner: Which is better?
    By endofall in forum Computer Hardware
    Replies: 10
    Last Post: 02-01-2006, 12:36 PM
  5. flash vs. swishmax (which is better?)
    By heropy21 in forum Websites & Multimedia
    Replies: 23
    Last Post: 06-09-2005, 11:38 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
about us
We are the first Cebu Online Media.

iSTORYA.NET is Cebu's Biggest, Southern Philippines' Most Active, and the Philippines' Strongest Online Community!
follow us
#top