DEPRECATION WARNING

This documentation is not using the current rendering mechanism and is probably outdated. The extension maintainer should switch to the new system. Details on how to use the rendering mechanism can be found here.

EXT: GSA Standalone Database

Author:Kasper Skårhøj
Created:2002-11-01T00:32:00
Changed by:Rainer Kuhn
Changed:2009-11-27T16:20:30.830000000
Author:Rainer Kuhn
Email:t3extensions@punkt.de
Info 3:
Info 4:

EXT: GSA Standalone Database

Extension Key: pt_gsaminidb

Copyright 2008-2009, Rainer Kuhn, <t3extensions@punkt.de>

Manual revised for pt_gsaminidb version 1.0.0, 2009-11-27

Extension development sponsored by punkt.de GmbH ( `http://punkt.de/ <http://punkt.de/>`_ )

This document is published under the Open Content License

available from http://www.opencontent.org/opl.shtml

The content of this document is related to TYPO3

- a GNU/GPL CMS/Framework available from www.typo3.com

Table of Contents

EXT: GSA Standalone Database 1

Introduction 1

What does it do? 1

Administration 2

Installation of an additional (non TYPO3) GSA database 2

Installing the GSA database tables into an existing TYPO3 database 2

Known problems 3

To-Do list 3

Changelog 3

Introduction

What does it do?

This extension provides SQL scripts to import into your MySQL database server in order to create the minimal required additional GSA database tables to run GSA Shop and the extensions of the "General Shop Applications“ (GSA) category (the pt_gsa* extension family) as a TYPO3 standalone version without ERP usage.

You can chose to install a separate additional (non TYPO3) GSA database for this purpose, or to import the required GSA database tables into an existing TYPO3 database.

Administration

This extension pt_gsaminidb is just a “wrapper” for the SQL scripts, so the extension neither has to be installed at your TYPO3 instance, nor it bothers anything if it is installed...

As stated in the introduction, you can choose to install an additional (non TYPO3) GSA database to run the GSA extension, or to import the required GSA database tables into an existing TYPO3 database. The first option of using a separate database is the recommended way, but since not all TYPO3 users have the privileges to create an additional database on their database server, the second option has been implemented as a workaround and is explained below as well.

Installation of an additional (non TYPO3) GSA database

This is the recommended way to use the GSA database tables if you have full access to your database server.

The SQL script to create the GSA standalone database is located at pt_gsaminidb/res/GSAMINIDB.sql. The only installation requirement to run this SQL script is a MySQL database server. Using the unchanged SQL script, the default character set and collation of your database server installation will be used for the new database.

If you want to use a different character set for the database created by the script you may complement the CREATE DATABASE statement at the beginning of the script with the appropriate MySQL instructions (see http://dev.mysql.com/doc/refman/5.1/en/charset-database.html ), e.g.

CREATE DATABASE `GSAMINIDB` CHARACTER SET utf8;

To create the database, just run the SQL script GSAMINIDB.sql at your MySQL database server as a MySQL admin user, e.g. by using the command line with pt_gsaminidb available in your TYPO3 extension directory:

mysql -u <your_MySQL_admin_username> -p < <path_to_your_typo3_project>/htdocs/typo3conf/ext/pt_gsaminidb/res/GSAMINIDB.sql

Don't forget to create an appropriate MySQL database user for this newly created database. Be aware not to use the same database user name for the GSA database like the one you already use for your TYPO3 database, since this may lead to access problems under certain circumstances.

You can create the new database user e.g. by executing this SQL command on your MySQL server's console:

GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,DROP,INDEX,ALTER
ON `GSAMINIDB`.*
TO <your_username>@localhost
IDENTIFIED BY '<your_password>';

If you're using this database with the extension “GSA Socket” (pt_gsasocket), you have to enter the database access information in pt_gsasocket's extension manager configuration.

Installing the GSA database tables into an existing TYPO3 database

Since not all TYPO3 users have the privileges to create an additional database on their database server, this workaround of installing the GSA database tables into an existing TYPO3 database is offered.

IMPORTANT : This way of using the GSA database tables is not recommended (please choose the above option of using a separate database if you are able to!), it is just a workaround to use only one database. Due to massive differences in the database design of the GSA database and the TYPO3 database, e.g. increment of IDs, expected table fields, NULL fields (expected by GSA, but not allowed in a default TYPO3 database table), this is not a complete TYPO3 integration of the GSA tables! The GSA database tables neither have a proper TYPO3 database/SQL integration nor there is a TCA integration for them – this results in some problems and risks:

  • The GSA database tables do not follow the TYPO3 guidelines for database table names. They are all prefixed with “tx_ptgsaminidb_*”, but this prefix is followed with the original GSA table name, most of themin German uppercase letters.
  • The GSA database tables are not installable using TYPO3's extension manager - you have to import them manually into your TYPO3 database using a SQL script.
  • The “Database Analyser” of TYPO3's install tool will complain about these tables when you use the “COMPARE” option: in the section “Removing tables (rename with prefix)” the install tool will offer you all GSA database tables (all prefixed with “tx_ptgsaminidb_*”) to rename them to deleted tables (prefixed with “zzz_deleted_tx_ptgsaminidb_*”9, and -if you've allowed this- in a second step to remove them completely. Be aware of this risk and instruct all TYPO3 admins never to allow any install tool modifications for the GSA database tables!
  • There will be no TCA access to the GSA database tables in the TYPO3 backend.
  • The GSA database will not be included in any TCA based actions of the TYPO3 core or of other extensions, e.g. a TCA based backup solution will not cover these tables.
  • Most GSA extension documentation and GSA extension inline comments refer to a separate GSA database only. You may have to “translate” the meaning of the documentation for your TYPO3-database-integrated GSA tables.

The SQL script to import the GSA database tables into your TYPO3 database is located at pt_gsaminidb/res/tx_ptgsaminidb_tables.sql. The only installation requirement to run this SQL script is a MySQL database server with a TYPO3 database installed. Using the unchanged SQL script, the default character set and collation of your existing database will be used for the new tables.

To create the GSA tables within your existing TYPO3 database , just import the SQL script tx_ptgsaminidb_tables.sql with the “SQL” function of phpMyAdmin available in your TYPO3 backend (“Tools” -> ”phpMyAdmin” -> ”SQL”). Alternatively you can run the script at your MySQL database server as a MySQL admin user, e.g. by using the command line with pt_gsaminidb available in your TYPO3 extension directory:

mysql -u <your_MySQL_admin_username> -p < <path_to_your_typo3_project>/htdocs/typo3conf/ext/pt_gsaminidb/res/tx_ptgsaminidb_tables.sql

If you're using this database with the extension “GSA Socket” (pt_gsasocket), you have to check the appropriate checkbox for the option “useGsaTablesInTypo3Database” in pt_gsasocket's extension manager configuration.

Known problems

  • Using an additional (non TYPO3) GSA database: Be aware not to use the same database user name for the GSA database like the one you already use for your TYPO3 database, since this may lead to access problems under certain circumstances due to a TYPO3 bug.
  • Using the GSA database tables in your TYPO3 database: no TYPO3/TCA integration of these tables – problems and risks see previous chapter of this manual.

To-Do list

Currently nothing.

Changelog

((generated))

v1.0.0:

GSAMINIDB.sql and tx_ptgsaminidb_tables.sql: changed data type of database fields “ARTIKEL.ZUSTEXT1” and “ARTIKEL.ZUSTEXT2” from "longblob" to "longtext" to enable the usage of MySQL's automatic charset conversion for these fields, too

v0.0.4:
  • added the SQL script tx_ptgsaminidb_tables.sql to allow the import of the required GSA database tables into an existing TYPO3 database (e.g. for users who do not have have the privileges to create an additional database on their database server) – this “2-in-1” database requires pt_gsashop version 0.14.0 or higher and all other GSA extensions (pt_gsa*) in versions since December 2008
  • adapted this manual accordingly
v0.0.3:
  • changed key “ARTIKELIdx5” of database table “ARTIKEL” to cover only the field “MATCH”, since the original combined key “(`MATCH`,`ARTNR`)” resulted in a MySQL error on UTF8 databases while importing the SQL script
  • added problem notice concerning database user name to this extension manual
  • changed extension status to “beta”
v0.0.2:

added dispatch cost record “frei” for cost-free handling (changes to SQL table definition of VERSART and SYNEWNUMBER) since this record is required by GSA Shop

v0.0.1:

initial version

img-1 EXT: GSA Standalone Database - 3