Библиотека QT для работы со схемой базы данных.  1.0.1
qdataschemadriver-postgresql.h
1 /****************************************************************************
2 ** $Id: qdataschemadriver-postgresql.h,v 1.7 2009/06/11 14:59:25 app Exp $
3 **
4 ** Header file of the QDataSchemaDriver
5 **
6 ** Created : 20031201
7 **
8 ** Copyright (C) 2003-2004 Leader InfoTech. All rights reserved.
9 **
10 ** This file is part of the Library of the Ananas
11 ** automation accounting system.
12 **
13 ** This file may be distributed and/or modified under the terms of the
14 ** GNU General Public License version 2 as published by the Free Software
15 ** Foundation and appearing in the file LICENSE.GPL included in the
16 ** packaging of this file.
17 **
18 ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
19 ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
20 **
21 ** See http://www.leaderit.ru/page=ananas or email sales@leaderit.ru
22 ** See http://www.leaderit.ru/gpl/ for GPL licensing information.
23 **
24 ** Contact org@leaderit.ru if any conditions of this licensing are
25 ** not clear to you.
26 **
27 **********************************************************************/
28 
29 #ifndef QDATASCHEMADRIVER_POSTGRESQL_H
30 #define QDATASCHEMADRIVER_POSTGRESQL_H
31 #include <qobject.h>
32 #include "qdataschemaglobal.h"
33 #include "qdataschemadriver.h"
34 //#include <qdict.h>
35 //#include "config.h"
36 //class QSqlCursor;
37 
46 {
47 Q_OBJECT
48 
49 public:
52 
53  QString sqlDriverName();
54  QString fieldtype( const QString &qdstype,
55  int width, int decimals = 0,
56  bool notnull = false, bool primarykey = false, bool serial = false );
57 
58  int fieldWidth( QSqlFieldInfo *ftypedef );
59  int fieldDecimals( QSqlFieldInfo *ftypedef );
60  QString defaultDatabaseName(){ return "template1";};
61 
62 protected:
63  QString queryCreateDatabase( const QString &name );
64  QString queryAlterTableModifyField( const QString &tname, const QString &field, const QString &oldfield = "" );
65  QString queryDropIndex( const QString &tname, const QString &iname );
66 };
67 
68 #endif
Класс для работы с сервером PostgreSQL.
Definition: qdataschemadriver-postgresql.h:45
Класс для работы с сервером БД.
Definition: qdataschemadriver.h:33