====== Toolbox ====== {{:firstaid.png?nolink&128 |Werkzeugkiste}} ---- ===== SQL-Dump-Converter (online-Tool) ===== //Supports development for Website Baker 2.8.3(SP3 and up) / 2.10.x / 2.11-x//\\ **[[en:dev:all:devtools:manual-sqlconvert|Tutorial for the SQL-Dump-Converter]]** [[http://isteasy.de/otools/ConvertDump/?b=a20zw3|start SQL-Dump-Converter]] This tool, in conjunction with the (since WB 2.8.3 SP3) built-in SQL Importer is intended to facilitate and accelerate developing installation routines significantly.\\ The recent //**install.php**// - files with page-long, hand-drawn table definitions in PHP syntax finally are a thing of the past.\\ As a rule, each developer always builds his own table structure belonging to his new addon in the database. From now on, it is sufficient to export that structure (not data) with all tables belonging to it, e.g. via phpMyAdmin, shortly send teh dump through the converter and there you have a valid SQL structure import file. Just a few short lines of code to be inserted in each case in the //install.php//, //uninstall.php//, and //upgrade.php//, and the use of the new structure files during installation, uninstallation and upgrade is ensured.\\ An import file (//**install-struct.sql**//) shall contain all information on table definitions needed to install an addon.\\ So that a structure file can satisfy all possible modes of the importer, it must contain for each table, the successive combination of the following 2 SQL statements. **DROP TABLE IF EXISTS `{TABLE_PREFIX}mod_modulname_table`**\\ **CREATE TABLE IF NOT EXISTS `{TABLE_PREFIX}mod_modulname_table`** Diese Kombination beider Statements erlaubt es dem Importer, //**wahlweise**// eine komplette Neuanlage nach evt. vorherigem Löschen alter Tabellen //**oder**// Nachinstallation einzelner, fehlender Tabellen bei Reparatur / Upgrade //**oder**// einfach eine komplette Deinstallation vorzunehmen. This combination of the two statements will allow the importer, //**either**// to perform a complete new installation after a possible destroy of all old tables //**or**// retrofitting individual, lack of tables at repair / upgrade, //**or**// simply make a complete uninstall.