| |
| |
|
|
|
|
| |
|
| |
|
| :: |
| Author |
Message |
AmirAbbas phpBB SEO Team


Joined: 11 May 2006 Posts: 529 Location: IRAN
|
Posted: Sat May 20, 2006 1:35 pm Post subject: how can i make a db update file |
|
|
i want to make premodded phpbb
i have some question
it this time i've installed over 20 mod
some of this mod has a database update file and some of them has a SQL queries
i want to make a one install file for all standard phpbb table and for all of my mods
i want to install another template as a default template instead of phpbb.
i found a script that is useful for make DB_update files
you must give the sql queries to this script and then this script will make a db_update for you
but i couldn't find a tool for extract sql queries from db update files
have you any suggestion ?
thank you |
|
|
| Back to top |
|
 |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 15242
|
Posted: Sat May 20, 2006 2:24 pm Post subject: Re: how can i make a db update file |
|
|
Well, if you want to make your install as compatible as phpBB itself, you should edit the sql schemas located in the original phpBB2/install/schemas.
You would just have to properly add the table definitions and default settings for mod's tables and to mod phpBB table settings for them to be directly created with the modified settings.
Should not be that hard, open the files up, and open as well a db backup of your moded forum, you'll find in there what could be the proper alteration for phpBB tables. Concerning new tables, the sql provided in the mod file should suffice.
You should at least be able to create an auto install for mysql without suffering too much  |
_________________ Useful links :
SEO Forum || SEO Directory || SEO phpBB || SEO phpBB3 || Search
____________________
Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Référencement phpBB3 || Recherche |
|
| Back to top |
|
 |
AmirAbbas phpBB SEO Team


Joined: 11 May 2006 Posts: 529 Location: IRAN
|
Posted: Fri May 26, 2006 3:12 pm Post subject: Re: how can i make a db update file |
|
|
ok i found two schema file in install folder
1- mysql_schema.sql
2- basic_schema.sql
the first one will make all the tables abd the second one will add default values to
config table
am i right ?
i think i must add all off sql queries at the end of mysql_schema.sql file
but there is a problem
some mods have a db_update.php file
how can i extract the sql queries from these files ?
thanks dcz |
|
|
| Back to top |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 15242
|
Posted: Fri May 26, 2006 10:55 pm Post subject: Re: how can i make a db update file |
|
|
| amir abbas wrote: | ok i found two schema file in install folder
1- mysql_schema.sql
2- basic_schema.sql
the first one will make all the tables abd the second one will add default values to
config table
am i right ?
|
Yes you are
A bit more than just the config default setupe, the default cat, forum and post as well.
| amir abbas wrote: |
i think i must add all off sql queries at the end of mysql_schema.sql file
but there is a problem
some mods have a db_update.php file
how can i extract the sql queries from these files ?
thanks dcz |
You are welcome
So that's why I told you to start working with a full db backup of a sample install (without any more post than the demo one but fully working, once all of your premod code is final) of your premod, so that all of the sql you'd have manually or through a php script will be added in it.
Then you'd just have to copy and paste (you have to follow exactly the way it is written down in the phpBB install files so you might have to change small things as well; with phpmyadmin you can end up with "`" to protect fields, if so get rid of those) code from the db backup to the phpBB sql install files.
You'll face several cases :
A mod added a table, then, you should find the sql definition of it in the db backup followed by the insert for the default settings. Just paste it all in the mysql_schema.sql. You can paste the inserts in mysql_basic.sql, but I am not sure this is really required, it could work as well if you just paste all of it (table definition + inserts) in mysql_schema.sql.
A mod modified a phpBB table, then, copy and overwrite this table definition from the db backupt to the mysql_schema.sql, and do the same with the eventual associated inserts in mysql_basic.sql.
All other non modded nor added phpBB table should be left as is in the original phpBB sql install files.
Quite simple in the end  |
_________________ Useful links :
SEO Forum || SEO Directory || SEO phpBB || SEO phpBB3 || Search
____________________
Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Référencement phpBB3 || Recherche |
|
| Back to top |
|
 |
AmirAbbas phpBB SEO Team


Joined: 11 May 2006 Posts: 529 Location: IRAN
|
Posted: Sat May 27, 2006 6:56 am Post subject: Re: how can i make a db update file |
|
|
thank you  |
|
|
| Back to top |
|
 |
|
|
| Navigation |
Similar Topics |
|
|
|
|
|
|
|
| |
|
|
|
|
| |
|
|
|
|
| |