kcotter Posted February 3, 2011 Share Posted February 3, 2011 Hello, I'm fairly new to PHP, and I'm looking to create an online catalog for a furniture/appliance store. I'm wondering the best way to go about this. I'm looking at SQLMaestro's "PHP Generator for MySQL" http://www.sqlmaestro.com/products/mysql/phpgenerator/ ... But, I'm curious if you guys can point me in the right direction. I've never created a database before, and I want to do it the way that makes the most sense... Any advice would be appreciated!! Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/ Share on other sites More sharing options...
denno020 Posted February 3, 2011 Share Posted February 3, 2011 Find some tutorials. I've only learnt PHP myself in the last couple of months by watching youtube videos, and now I'm very confident working with it. Just read what you can. It's better to learn how to code that to use a GUI (which is what I think the SQLMaestro thing is), as it will allow you to better understand what you're writing, and also make it more efficient. Other than that, I'd suggest paying someone . Denno Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1169412 Share on other sites More sharing options...
kcotter Posted February 3, 2011 Author Share Posted February 3, 2011 I wish... But, I probalby don't have the budget for that. What is the difference between a MySQL and just a Microsoft Access database? I'll look for some tutorials... Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1169424 Share on other sites More sharing options...
ZulfadlyAshBurn Posted February 3, 2011 Share Posted February 3, 2011 MySQL and Microsoft Access Database are almost the same thing. MySQL is use mainly for Apache/Unix servers while MSSQL or Microsoft Access Database are used on Windows Servers. If you need any help, you can always pay people to do it for you Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1169426 Share on other sites More sharing options...
kcotter Posted February 3, 2011 Author Share Posted February 3, 2011 Paying someone would be great, but I don't think I have the budget. Not sure how hard it would be for someone to set up my database so I could just add the furniture and stuff... I guess that could be easy for the right person. But, I'm sure there's more to it than I'm aware of. Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1169428 Share on other sites More sharing options...
denno020 Posted February 3, 2011 Share Posted February 3, 2011 It really isn't that hard at all. The best way for you to do it is to sit down with a pen and paper, and work out what bits of information you need for each item. This will be how many columns your products table has. Add one for id, which is completely necessary, and which you will also make the primary key (unique identifier). Once you have your tables worked out on paper, you can translate that into a database. I would highly suggest using phpMyAdmin. It will make everything soooo much easier.Go to youtube and see what you can find on how to create tables using phpMyAdmin. I promise you it isn't as scary as you're thinking it is. Denno Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1169433 Share on other sites More sharing options...
kcotter Posted February 3, 2011 Author Share Posted February 3, 2011 thanks a lot for the help!!! I'm going to for sure look into phpMyAdmin. I'm at work now, and youtube (along with most other stuff) is blocked... I do know that I'll be using GoDaddy. And I'm pretty sure you can log on and create a database thru the godaddy interface, but maybe I don't need to do it that way if I use phpMyAdmin... For some reason I'm picture a database as a file that you can create. Then you just upload it to your mysql folder on your server... Am I even thinking the right way? Does phpMyAdmin help create the file (database)? Sorry for the stupid questions.. But, you're helping me a ton! Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1169439 Share on other sites More sharing options...
BlueSkyIS Posted February 3, 2011 Share Posted February 3, 2011 godaddy allows you to create the database, then they provide phpmyadmin to manage it. while the database is a file, you will probably never see or touch it. Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1169446 Share on other sites More sharing options...
kcotter Posted February 9, 2011 Author Share Posted February 9, 2011 ok, so I created my database with GoDaddy... I'm not really sure on how to set it up, so maybe you guys can help me, or get me going in the right direction.... I'm making a product catalog for a rent to own store. There will be no "cart" just a catalog that shows the price, title, and short description of each product. Also, a photo. Anyway, I have 4 main categories... Appliances, Computers, Electronics and Furniture. Now I'm getting confused because under Appliances (for example) there are 3 categories... Kitchen, Laundry and Other. Also under Kitchen (for example) there are 5 categories... Freezers, Microwaves, etc.... and under each of those categories are the actual products. For example, an Acme Freezer would be listed under Appliances>Kitchen>Freezers>.... So, my first issue is, I created a database, and I need to create a tables.. Do I start off with 4 tables (Appliances, Computers, Electronics and Furniture)? Or should I just make one table and call it Products and put every product in it? The only tutorials I can find are teaching me how to make a member log in and stuff... any help would be cool. Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1171671 Share on other sites More sharing options...
fortnox007 Posted February 9, 2011 Share Posted February 9, 2011 Hi kcotter, i don't think you will end up having something that works as good as you want if you have complety no idea about the logic of a relational database. If you like i can look up some videos for you and link it, it's a complete lecture on how to setup a good database structure. Right now you will just make tables not knowing what it will bring in the end. -Edit: here you are, after you have seen these, get a pen and pencil and write down the relationships: Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1171674 Share on other sites More sharing options...
kcotter Posted February 9, 2011 Author Share Posted February 9, 2011 Yeah, I just started researching this tonight. If you have time to post up some links that would be cool. Over the next few days/weeks I plan on getting a crash course in mysql. I'm pretty green right now, but I know way more than I did 6 hours ago. thanks for the reply! Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1171677 Share on other sites More sharing options...
fortnox007 Posted February 9, 2011 Share Posted February 9, 2011 Yeah, I just started researching this tonight. If you have time to post up some links that would be cool. Over the next few days/weeks I plan on getting a crash course in mysql. I'm pretty green right now, but I know way more than I did 6 hours ago. thanks for the reply! That's the best i can give, just use pen and pencil and watch it as if it were a lecture, footagee is a bit oldschool, but the ideas are still the same Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1171679 Share on other sites More sharing options...
kcotter Posted February 9, 2011 Author Share Posted February 9, 2011 Ok, so I was thinking about this again this morning. Please let me know if I'm way off base, but I'm thinking I should create 1 table, and call it all_products or something... and have the following fields or columns: id category1 category2 category3 title description avail_colors price image_name (not sure if this is possible or not, but each product would have an image in an "image" directory) Then I can create a php form where I can enter the info into text boxes that submit to these fields... at least this is the direction I'm thinking... does this seem like a good plan of attack? Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1171766 Share on other sites More sharing options...
crmamx Posted February 9, 2011 Share Posted February 9, 2011 You do not create a database with phpMyAdmin. Most every host that allows databases use the cPanel software, which allows you to set up email, files, logs, security, domains, security, databases and a couple of others. Database setup and maintenance is done with MySQL. Table setup and maintenance is done with phpMyAdmin, tho to set up a site you will have to learn php. Before you do anything, I would strongly suggest you study and have a good understanding of a relational database. Then design on paper every field that you want to use and how it relates to another field/s. Now do a flowchart of the programs you will need to access/add/change/delete/display the data. Otherwise you will waste many, many hours and end up with a mess which you will have to redo. Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1171783 Share on other sites More sharing options...
crmamx Posted February 9, 2011 Share Posted February 9, 2011 I was in the furniture mfg business for many years and will give you a couple of examples of what I was talking about. partno file - a unique part number for every product If you offer more than one color for a part number you cannot put colors in that file. You must cross reference and link from the partno file to a colorno file. Same for any other attribute that offers options. Price. If you offer different prices to different customers then you must design your database to reflect that option. Discounts? It can get pretty complicated and must be thought out. Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1171789 Share on other sites More sharing options...
kcotter Posted February 9, 2011 Author Share Posted February 9, 2011 Those are good points. Just so we're on the same page, I'm basically recreating a site just like this: http://www.continentalrto.com/ The color field would probably not be "avail_colors" it should just be "color" . If they have a black couch, they don't offer it in brown also... My mistake. But I thought I should have a field named "color" just so you could search the database for every black piece of furniture for example... Every product is individual, and the only relation it would have to other products is the category it's in. This seems like it shouldn't be that hard. I can't believe I can't find a tutorial to set up exactly what I'm talking about. Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1171799 Share on other sites More sharing options...
BlueSkyIS Posted February 9, 2011 Share Posted February 9, 2011 You do not create a database with phpMyAdmin. I do. Quote Link to comment https://forums.phpfreaks.com/topic/226571-database-questions/#findComment-1171867 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.