ErrorsError IdSeverityDescription70000OkNo Error70001ErrorCan not open GDA connection70002ErrorGDA connection does not exist70003ErrorError processing query70004ErrorData Model does not exist70005ErrorInvalid value RowId70006ErrorOther transaction already in progress70007ErrorNo transaction in progress70008WarningUNDEFINED70009WarningInvalid Session ID70010ErrorUNDEFINED70011ErrorError parsing file70012ErrorUNDEFINED70013ErrorInvalid Build Option70014WarningGDA connection already open
Multiple Data CommandsIt is possible to combine DCs in one single request. There will be
one response file, but with results for every command, unless an error has
been encountered before the end of processing. The format is as follows:
]]>Combining multiple DCs will result in better performance.Storage TypesThe the following storage types are defined in libgda:nullbigintbiguintbinaryblobbooleandatedoublegeometric_point (point)gobjectintegerlistmoneynumericsinglesmallintsmalluintstringtimetimestamptinyinttinyuinttypeuintegerunknownNot all storage types are implemented (yet) and/or supported in all
the various providers libgda can link with.Within the ProLinga 4GL environment, only the basic data storage types are defined:CharacterIntegerLong (Integer)Single (Precision Number)Double (Precision Number)Date
libgda -> ProLinga 4GL mappingLibGDA Storage TypeProLinga Storage TypenullCharacterbigintLong Integerbiguint (not implemented yet in libgda)--binaryCharacterblobCharacterbooleanCharacterdateDatedoubleDouble Precision Numbergeometric_point (point)N/Agobject (not implemented yet in libgda)--listN/Amoney (not implemented yet in libgda)--numericDouble Precision NumbersingleSingle Precision NumbersmallintIntegersmalluint (not implemented yet in libgda)--stringCharactertimeCharactertimestampCharactertinyintIntegertinyuint (not implemented yet in libgda)--type (not implemented yet in libgda)--uinteger (not implemented yet in libgda)--unknown (not implemented yet in libgda)--
For libgda <-> data provider mappings, please look at provider specific
documentation at
http://www.gnome-db.org.ProLinga-Data Programming NotesTo test ProLinga-Data, the best and easiest way is to
use the binaries that come with the product. Configure so the product is
running as a Web Service and use the client binary to send and
receive Data Commands. See the
user guide section for more
details.To access the Data engine from a C++ application,
either network (SOAP) calls to send and receive Data
Commands over the network or the C++ API to
link with the Data library can be used.Network ClientTo be able to send and receive Data commands over
the network as SOAP calls from
a C++ application, the application must link with the ProLinga-Soap
Client Library (libprolingasoapclient). Details of how to do so are
in the section "Programming Notes" of the ProLinga-Soap Project
documentation. In the example you have to change the example
XML request document with a valid Data Command. Alternatively,
have a look at the source code file DataClient.cpp
in the src directory of
ProLinga-Data.When using this method, ProLinga-Data must be running as
a Web Service.Data LibraryTo be able to link directly with Data from a C++
application, the Data Library (C++ API) can be used.A very basic example program using the Data Library
looks like this:
int main(int argc, char **argv)
{
/*Init */
xmlDocPtr docReq, docRes;
xmlNodePtr curReq, curRes;
xmlBufferPtr bufRes;
PlData dat;
/* Open Data Environment */
dat.dataOpen("./prolingadatcfg.xml", argc, argv);
/* Create Data Command */
docReq = xmlNewDoc((const xmlChar *)"1.0");
docReq->children = xmlNewDocNode(docReq, NULL, (const xmlChar *)"ProLinga", NULL);
curReq = xmlDocGetRootElement(docReq);
curReq = xmlNewTextChild (curReq, NULL, (const xmlChar *)"Data", (const xmlChar *)"");
xmlNewProp (curReq, (const xmlChar *)"Version", (const xmlChar *)"1.0");
curReq = xmlNewTextChild (curReq, NULL, (const xmlChar *)"Command", (const xmlChar *)"");
xmlNewProp (curReq, (const xmlChar *)"Name", (const xmlChar *)"Connect");
xmlNewProp (curReq, (const xmlChar *)"Mode", (const xmlChar *)"Request");
/* Process Data Command */
docRes = dat.executeCommand(docReq);
/* Print Response */
bufRes = xmlBufferCreate();
curRes = xmlDocGetRootElement(docRes);
xmlNodeDump(bufRes, docRes, curRes, 0, 1);
printf("%s\n", (char *)xmlBufferContent(bufRes));
/* Close Data Environment */
dat.dataClose();
/* Free */
xmlBufferFree(bufRes);
xmlFreeDoc(docRes);
xmlFreeDoc(docReq);
/* Return */
return 0;
}
]]>When running this application, a connection is made to the
Data environment. When opening this connection an argument with the path
and name of the data configuration file can be passed as
an argument. The system then knows environment details.
The configuration file has
to be in a certain format, which is explained further on. The Data
Command is then presented to the Data process engine and a response
is returned. This response is printed to to stdout (screen). The connection
to Data is closed and the program exits.After creating a connection using the openData class function, more
than one VC can be executed without the need to close and open the Data
environment for every call. In fact performance wise this is the
prefered method.The C API of the libxml2 toolkit has been used in this example,
while it is probably better
to use a C++ implementation of this toolkit as
libxml++.
Internal Data code will
be changed as the project progresses.To compile the program
use the following command:
g++ data_test.cpp -o data_test `pkg-config --cflags --libs prolinga-data`
ProLinga-Data Library libprolingarepository has to be available
for this option as well as the libgda libraries.You may need to set the environment variable PKG_CONFIG_PATH to
point to the directories where prolinga-data.pc is located.
This can be directory /usr/lib/pkgconfig or
directory /usr/local/lib/pkgconfig on Linux for
example.
ProLinga-Data is built using various 3rd party open source packages.
These packages need to be available at compile time for a sucessful result. See
the
dependencies and
prerequisites section for more details.Download ProLinga-DataThere are two types of product versions available for download:Production VersionDevelopment VersionProduction VersionThe production version is an official product release. This is a
stable completed version which should be used in production environments. At this
stage the product is only available as a source archive. Binary packages for a wide
range of platforms will be available for download as the project progresses.
Please visit the
download page for the latest details.Development VersionThe development version is a snapshot of the latest source files. Since
it can contain bugs as part of "work in progress", this version should not
be used in production environments. Only developers who want to help with
further development of the ProLinga Projects should download this version. Please
read the details at the Subversion section
of how to obtain the latest development version.Build ProLinga-DataPrerequisitesProLinga-Data &version; has been built and tested
on various popular GNU/Linux platforms as RedHat Fedora, Mandriva Linux,
Debian, Ubuntu and openSUSE. The product
should compile and run successfully on
other Linux distributions as well as UNIX.
GNU gcc/g++ >= 3.3 compilers/tools are required
for a successful build.Required 3rd party package(s) for a successful build:libxml2.
This product provides XML libraries.libgda
This product provides a data abstraction layer.ProLinga-Soap
This product provides a SOAP/XML engine.Optional 3rd party package(s) for a successful run-time/test environment:Data providers like PostgreSQL
or MySQLxsltproc. Command line processor.
This package
is only required to re-generate the HTML pages after making changes to the documentation.General Download and Installation Instructions 3rd Party Products.Assuming the directory /opt/builds will be used for 3rd party products,
then in general the following steps need to be taken to download and extract
a 3rd party product source archive.Download source tar/gz archive to /opt/builds/[product] Example:
place libxml2-x.x.x.tar.gz in /opt/builds/libxml2Use 'gunzip' to unzip the archiveUse 'tar xvf [product.tar] to extract the archive. Example:
tar xvf libxml2-x.x.x.tar.A new sub directory will be created with the new version of
the product. Example: /opt/builds/libxml2/libxml2-x.x.x
This way several versions of the same products can be installed next to
each other.For product specific installation instructions see following sections.Libxml2:Product root dir: /opt/builds/libxml2Current version: 2.7.3Download:
ftp://xmlsoft.org/libxml2/libxml2-2.7.3.tar.gzBuild Instructions:
cd /opt/builds/libxml2/libxml2-2.7.3
./configure --prefix=/opt/builds/libxml2/libxml2-2.7.3 --disable-gtk-doc
make
make install
LibGDA:Product root dir: /opt/builds/libgdaCurrent version: 4.1.4Download:
ftp://ftp.gnome.org/pub/GNOME/sources/libgda/4.1/libgda-4.1.4.tar.gzBuild Instructions:
cd /opt/builds/libgda/libgda-4.1.4
./configure --prefix=/opt/builds/libgda-4.1.4
make
make install
ProLinga-Soap:Product root dir: /opt/builds/prolingaCurrent version: 0.0.2Download:
http://download.prolinga.orgBuild Instructions:
cd /opt/builds/prolinga/prolinga-soap-0.0.2
./configure --prefix=/opt/builds/prolinga/prolinga-soap-0.0.2
make
make install
See the ProLinga-Soap Project documentation for more installation
information.Build InstructionsExtracting archiveThe product archive can be extracted to any desired directory
using unzip (.zip file extension) or
gunzip (.gz file extension)/
bunzip2 (.bz2 file extension) and
tar. After extracting, the following directories
will be created:
Directory Structure.DirectoryDescription&PRODUCT;-&version;Product version root directory.&PRODUCT;-&version;/configConfig build information.&PRODUCT;-&version;/docDocumentation.&PRODUCT;-&version;/srcAll source and internal header files.&PRODUCT;-&version;/testsSelf tests.&PRODUCT;-&version;/prolingaExternal (API) header files.
Compiling and LinkingTo build the product go to the product root directory and run the
configure script. For default installation in /usr/local type:
./configure
To install into another directory type:
./configure --prefix=/any/dirname/For all other configure options, type:
./configure --help
After running the configure script, the product can be build with:
make
To run the optional self-test type:
make check
After compilation, the binaries, libraries and header files can be
installed with:
make install
You may need root access for this last option.By default, HTML documentation pages are available in
the doc/html directory. These pages are generated from
DocBook XML file format
files in /doc. To re-generate the HTML pages from these files type:
make html
The command line XSLT processor xsltproc must be
available from $PATH to be able to generate the HTML documentation.DependenciesMany of the ProLinga Projects are dependent on 3rd party libraries.
These (non system) dependencies of ProLinga-Data are outlined below.
If these 3rd party
products are not installed in either /usr/bin, /usr/lib, /usr/include
or /usr/local/bin, /usr/local/lib, /usr/local/include, the additional
configure option needs to be provided when building.
Choosing the right type of buildThe default configuration options provide libraries which
can be used both to develop/debug as to run the product. However better builds
are possible for a dedicated development or production environment.In production environments, builds are needed which contain minimal (debug)
overhead, so they are fast and small. To build such binaries/libraries, the
--enable-final options can be used. Example:
./configure --enable-final
The enable-final flag is configured to be used with GCC environments only.
If access to more compilers become available over time, the enable-flag will be
ported to those compilers as well.In development environments, builds are needed producing warnings, enabling
maximum debugging info etc. Several options are available here.--enable-warnings : Set all compiler warning flags--enable-debug : Enable all debug messages--enable-gprof : Enables profiling with gprof (GCC only)Further development of ProLinga-DataAll ProLinga Projects are under constant active development. This includes
issues related to fixing bugs, increasing performance etc, as well as expanding
the various projects with new features. This chapter provides information of
all these types of tasks as well as details of how to join the development team.To-do ListThis section contains a list of work that needs to be done on the product.
A more detailed and up to date list is available on the
ProLinga Bugzilla Server.
Implement XML Schemas for validation. Libxml2 is finishing up XML schemas.
If it is still too far away, start with DTD.ProLinga-Data is written in C++. Libxml2 however is C only. There is a C++ wrapper
for this XML parser library. Details at http://libxmlplusplus.sourceforge.net/.
Some strings/paths are hardcoded in the product. This all should be
reviewed and be removed or made all configurable using a config file.Code review and cleanup. Make it more C++ Object Oriented.Logging. A simple logging mechanism has been implemented.Self-tests need to be developed for quality control.Porting to other platforms. (Windows/Solaris?), so we can make a distribution
available on a specific port if we need to.Look into XML Queries (XQL). Locking???Look into SQL 92 and SQL 99. Need a independent flavour of SQL if user want to in
combination with XML Queries. Will always need to support native SQL for data provider. Add command line options to the binaries.
SubversionA Subversion tree containing the latest project sources is available at
http://svn.prolinga.org.
For access please contact the ProLinga Development team.BugzillaBugzilla software development and bug tracking system to manage the ProLinga
projects is available at
http://bugzilla.prolinga.org.
For access please contact the ProLinga Development team.Help to DevelopAre you ready to join the ProLinga development team? There are several ways you
can help:Use the product. Tell us what you think, ideas, bugs etc.Fixing bugs. Visit the development section on the ProLinga Web Site,
choose a
bug, fix it and send us the code changes.
Enhancements. Have a look at the enhancement section of the
to-do list
and let us know which new feature you
want to help to develop.Porting. To be successful it is essential that the ProLinga Projects
are available on a wide range of platforms. We need help in porting and
testing as well as providing binary releases for many different platforms.
Let us know if and how you can help out.
Real world examples. Are you using ProLinga products or do you know people
who are happily using it. Tell us the story and provide some screenshots.
ProLinga-Data C++ APIThis section contains the API reference for ProLinga-Data. All
the public interfaces are documented here.
&prolinga-data-API;
ProLinga-Data User GuideThis section contains the user guide for the ProLinga-Data. All
the binaries are documented here.
&prolinga-data-userguide;
&fdl;