Jump to content

How to build PW site on top of existing database that keeps changing?


nickie
 Share

Recommended Posts

Hello and thanks for any help you can provide!

I know I'm in way over my head, but Processwire has me drunk on power. I know so little and yet so far I've been able to do pretty much everything I've wanted to, including all sorts of crazy admin features that until recently I'd thought were the sole purview of programming ninjas. 

Anyway on to my problem: thanks to PW I've picked up a lot of PHP, but I know next to nothing about MySQL. So you can assume utter-beginner level knowledge, but also full readiness to learn what needs to be learned to get the following done:

I have an existing database that has lots of data I want to use to model PW pages on. How would I build a PW site using some of the fields/tables in this database? The PW database would need to change and re-model this data in various ways.

This existing database also keeps changing. How can I stay in sync with the database, even while my database no longer looks like the existing database (cause my data changes too)?

Where can I start learning about what I need to know to start doing this and slowly get on top of it? Please point me in the right direction to start investigating - modules, books, tutorials - any input is welcome and deeply appreciated.

Thanks again.

  • Like 1
Link to comment
Share on other sites

Greetings,

First -- welcome to ProcessWire.

I think there might be a simple solution to your situation. But first, tell me this: are you planning to use ProcessWire as your sole CMS for this project, or do you plan to maintain another CMS along with it?

If you are planning to make a full switch to ProcessWire, I would suggest doing a one-time conversaion of the database into ProcessWire. Then from that point forward you are all set. Just for background, I have converted Joomla, WordPress, and Shopify databases into ProcessWire. You can do it. Just post here and people will help.

As far as learning MySql, this could be a great opportunity to do just that!

Thanks,

Matthew

  • Like 1
Link to comment
Share on other sites

Hi pwired - are you talking about PDOs or something else? How does PW api interact with database tables that haven't been created by it? In regular PHP terms?

Yes Matthew, PW only. So I can interact via PW with database tables that have not been created by processwire as long as they are in the same database? 

Let me ask an easier (for me to understand) question:

Say I have a database of products that is being auto-updated by some feeder in a given format. (product_id, product_name, price, source etc) I want to use some of the tables in this database to create PW pages for products, with fields that get their info from the database, and I also want to allow the PW-admin to make changes to these products, including their name and other information that has been extracted from the existing database. New items are also being added to the existing database every day (format same as before:product_id, product_name etc), and I would like these items to be added automatically to the PW site, without accidentally re-adding old items if their names have been changed.

Is this possible? Would I need to be interacting directly with the database or via PW?

(Gah, the fact that I don't even know the right questions to ask means I have a lot more studying yet to do. But I'll be back with more specific questions.)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...