Google Answers Logo
View Question
 
Q: Web programing ( No Answer,   0 Comments )
Question  
Subject: Web programing
Category: Computers > Software
Asked by: 888-ga
List Price: $30.00
Posted: 25 Jul 2003 03:14 PDT
Expires: 04 Aug 2003 09:23 PDT
Question ID: 234911
What i am trying to do is to setup a small web site for small online
DVD store with add a new customer,query movies and list all movies we
have using postgreSQL and php, could somebody help me out for the
tables and scripts. Thank you!
Answer  
There is no answer at this time.

The following answer was rejected by the asker (they received a refund for the question).
Subject: Re: Web programing
Answered By: joseleon-ga on 25 Jul 2003 03:44 PDT
 
Hello, 888:

  I will be more than happy to help you setup your DVD store, but let
me recommend you a prebuilt package, it's called osCommerce and I'm
sure it fits all your requeriments althought uses MySQL instead
PostgreSQL.

Here is some info:
  
Main web site
http://www.oscommerce.com

Feature list
http://www.oscommerce.com/about/features

Contributions to enhance your shop
http://www.oscommerce.com/community/contributions

I currently run the spanish support site for osCommerce:
 
http://oscommerce.qadram.com
 
And I could assist you in setup your online store. You decide, custom
made scripts for a simple store or the prebuilt package.

Regards.

Request for Answer Clarification by 888-ga on 25 Jul 2003 04:14 PDT
I need to use postgresql rather than mysql.
Could you help ?

Regards

Clarification of Answer by joseleon-ga on 25 Jul 2003 05:18 PDT
Hello:
  No problem, just tell me exactly what do you need, that is, a closed
feature list. You said tables and scripts for:

-New customer
-List articles
-Seach

By the way, I will try to adapt osCommerce to PostgreSQL, what is the
deadline for this project?

Regards.

Request for Answer Clarification by 888-ga on 25 Jul 2003 11:36 PDT
The feature What I need for a DVD rent station is listed as followed:

Add a new account 
Add a new movie
List all DVDs
Search for a specific account
Search for a movie
The DVD now is under whose account 

Tables:
MOVIE(dvdno,title,cast,year) 
ACCOUNT(accountno,firstname,lastname,address,city,state,phonenumber)
RENT(dvdno,accuntno)
pls amend the table as needed, that's what i though
I will do the main page myself,but if you could do it, i will be very appreciate!

Clarification of Answer by joseleon-ga on 26 Jul 2003 01:22 PDT
Hello:
  Here you have the script to generate the tables you need, I will
work on the scripts to perform database mantenaince and I will submit
them here:

/*==========================================================================*/
/*  Tables                                                            
     */
/*==========================================================================*/

CREATE TABLE movies (
    movie_id SERIAL NOT NULL,
    movie_title VARCHAR(80) NOT NULL,
    movie_cast TEXT,
    movie_year INT2,
    PRIMARY KEY (movie_id)
);

CREATE TABLE accounts (
    account_id SERIAL NOT NULL,
    account_firstname VARCHAR(40) NOT NULL,
    account_lastname VARCHAR(40) NOT NULL,
    account_address VARCHAR(80) NOT NULL,
    account_city VARCHAR(40) NOT NULL,
    account_state VARCHAR(40) NOT NULL,
    account_phonenumber VARCHAR(20) NOT NULL,
    PRIMARY KEY (account_id)
);

CREATE TABLE rents (
    rent_id SERIAL NOT NULL,
    movie_id INT4 NOT NULL,
    account_id INT4 NOT NULL,
    PRIMARY KEY (rent_id, movie_id, account_id)
);

/*==========================================================================*/
/*  Foreign Keys                                                      
     */
/*==========================================================================*/

ALTER TABLE rents
    ADD FOREIGN KEY (movie_id) REFERENCES movies (movie_id);

ALTER TABLE rents
    ADD FOREIGN KEY (account_id) REFERENCES accounts (account_id);

Request for Answer Clarification by 888-ga on 27 Jul 2003 00:52 PDT
Thank you very much! Hope to get your scripts soon.

Request for Answer Clarification by 888-ga on 28 Jul 2003 11:35 PDT
Could I know when can i get those scripts? Pls advise. Thank you!

Clarification of Answer by joseleon-ga on 29 Jul 2003 01:14 PDT
Hello:
 You can download the scripts from here:

http://www.xpde.com/google.rar

I have tried to write a very easy to understand code, an experienced
PHP developer will say it's not the best solution, but I think it's
better for you this way, so you can learn of it.

I have used ADOdb as database layer, using PostgreSQL as default, but
you can easily change it to use MySQL or another.

Check out the config.inc.php file to edit your database connection
parameters.

Feel free to request for any clarification.

Regards.

Request for Answer Clarification by 888-ga on 29 Jul 2003 03:21 PDT
Hello,
I tried to add some data but get the following error, would you pls
help me to fix it. Thank  you !

platform: linux


Warning: pg_connect() unable to connect to PostgreSQL server: FATAL:
No pg_hba.conf entry for host 138.202.210.7, user cchang3, database
cchang3 in /home/cchang3/public_html/adodb/drivers/adodb-postgres64.inc.php
on line 457

Thx & regards

Clarification of Answer by joseleon-ga on 30 Jul 2003 06:43 PDT
Hello:
  This error it's outside the scope of this answer because it's a
misconfiguration of your server, in any case, tell you that you have
to edit the file pg_hba.conf (usually in /etc/postgres) and add an
entry to allow (trust) the host 138.202.210.7 to connect to the
PostgreSQL server.

Regards.
Reason this answer was rejected by 888-ga:
I am asking for a web-programming, but without configration, I cannot
even test if it works, the code to me is useless. I don't wanna ask
another question about config and I am asking to get a refund for this
question.
Pls check. Thank you !

Comments  
There are no comments at this time.

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy