Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

ADDING AN EXISTING DATABASE


bs2713

Recommended Posts

Posted

I just installed OSCOMMERCE to a server which doesn't have a CPANEL and does not have access to phpMyAdmin.

 

I have my database which I would like to upload using MYSQL DROP TABLES...Unfortunately I have never done it in that way and have no knowledge of how to upload the database to the server.

 

Also I do not know from where I should be typing in these commands.

 

 

Please help me.

Posted

Hi Boris,

 

I just installed OSCOMMERCE to a server which doesn't have a CPANEL and does not have access to phpMyAdmin.

 

I have my database which I would like to upload using MYSQL DROP TABLES...Unfortunately I have never done it in that way and have no knowledge of how to upload the database to the server.

 

Also I do not know from where I should be typing in these commands.

 

Well, not having CPanel is not really a problem, but not even having phpMyAdmin is a problem. Are you absolutely certain that you have no sort of 'control panel' on your site ? Often phpmyadmin is not accessed this way:

 

http://example.com/phpmyadmin

 

BUT ...............

 

http://example.com/admin

 

it's amazing how many sites I have seen setup that way. Ask your hosting company, how do they expect you to setup a database without a tool like phpmyadmin ??

 

Anyway, to do it without such tools, you will need to have shell access, and also be able to be 'root' user (I _think_ with MySQL, on your account, so that you can, via mySQL:

 

* Add a user /password

* add database, tables

* Grant privileges to the user to be able to access the db

 

You can of course create it all with PHP, see http://au2.php.net/manual/en/function.mysql-create-db.php

 

Or, install phpmyadmin yourself. :D

 

Peter

Posted

I do have a control panel but I do not understand where do I type in this command to upload the database into the server? What is considered a shell? do I type this in the URL box?

 

 

 

 

 

Hi Boris,

Well, not having CPanel is not really a problem, but not even having phpMyAdmin is a problem. Are you absolutely certain that you have no sort of 'control panel' on your site ? Often phpmyadmin is not accessed this way:

 

http://example.com/phpmyadmin

 

BUT ...............

 

http://example.com/admin

 

it's amazing how many sites I have seen setup that way. Ask your hosting company, how do they expect you to setup a database without a tool like phpmyadmin ??

 

Anyway, to do it without such tools, you will need to have shell access, and also be able to be 'root' user (I _think_ with MySQL, on your account, so that you can, via mySQL:

 

* Add a user /password

* add database, tables

* Grant privileges to the user to be able to access the db

 

You can of course create it all with PHP, see http://au2.php.net/manual/en/function.mysql-create-db.php

 

Or, install phpmyadmin yourself.  :D

 

Peter

Posted

Hi,

 

Is there a 'Mysql' feature in your control panel ?

 

You don't actually need phpmyadmin for an osCommerce installation, as long as, via a 'MySQL' interface, you do this:

 

1. Create a username with a password

2. Create a database

3. Grant full privileges for the user created in setp 1, to the db created in step 2.

 

Peter

Posted

Yes, there is a MYSQL feature. I already created a database and set a password. The problem is that I have a database of my own that I would like to upload and use instead of the default one. I have downloaded WinSCP to execute this command

 

$> mysql -u <username> -p <databasename>

 

but it doesn't work for some reason...

 

How do I upload the existing database so the OSCOMMERCE store would use IT instead of the default database?

 

Thanks.

 

 

Hi,

 

Is there a 'Mysql' feature in your control panel ?

 

You don't actually need phpmyadmin for an osCommerce installation, as long as, via a 'MySQL' interface, you do this:

 

1. Create a username with a password

2. Create a database

3. Grant full privileges for the user created in setp 1, to the db created in step 2.

 

Peter

Posted

Hi,

 

Yes, there is a MYSQL feature. I already created a database and set a password. The problem is that I have a database of my own that I would like to upload and use instead of the default one.

 

I would advise not to do this, as I have seen far too many sites (osCommerce and others) were people "mix" databases, that is, a db is set aside for one particular purpose (example, osCommerce) and people go and add tables tot he db that have nothing to do with the 'system' or application.

 

Much better to keep your osCommerce db seperate. Why, because I have also seen users overwrite (production site) tables with another table of the same name. You will be taking extra risks and only giving yourself more work to "mix" all the tables in the same db.

 

I have downloaded WinSCP to execute this command

 

$> mysql -u <username> -p <databasename>

 

but it doesn't work for some reason...

 

 

If there is a "p" paramater, wouldn't the command be ...........

 

$> mysql -u <username> -p <password> ??

 

Peter

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...