This section includes sample client application classes and objects for use in connecting to the Easysoft XML-ODBC Server.
All the files listed are distributed with Easysoft XML-ODBC Server and are located in the corresponding directories within the Clients subdirectory of the chosen installation path.
A generic make file for building the sample C client.
Various other versions of the make file for different platforms (if a make file is not supplied for your platform, then use the generic version and edit it to reflect your required compiler and compiler options).
The xmlodbc_client program C source code.
A header file for xmlodbc_client.c containing various macros (this file may need to be edited if xmlodbc_client.c does not compile successfully on your platform).
The example xmlodbc_client program prebuilt for this platform distribution.
You will need an ANSI C compiler and make (although it is possible to compile the client without make).
The Easysoft XML-ODBC Server distribution includes a generic make file (Makefile), which should suffice for most platforms, and also additional platform-specific make files named Makefile.<platform>.
If you see a make file for your platform use:
Use the generic make file if there is no make file for your platform:
If the code compiles, but fails to link then you may need to specify additional libraries on the link line, of which the most likely to be missing are the socket libraries (see the Makefile.sunos file for an example of a platform requiring additional link libraries).
If the code fails to compile then ensure that:
The xmlodbc_client program supports the following command line arguments:
The name of the server machine where the Easysoft XML-ODBC Server is running. This may be an IP address, host name or a fully qualified domain name, but in each case it is passed to the gethostbyname() function, so your client machine needs to be able to resolve this argument value into an IP address if a host name is specified.
This is the port number on which the Easysoft XML-ODBC Server listens for database requests. This setting is optional and the default port of 8895 is used if it is not specified. Two ports can be configured for the Easysoft XML-ODBC Server, one for database requests and one for configuration requests (usually ports 8895 and 8896). You should send database queries to the database port (8895) and configuration requests/operations to the control port (8896).
The connection string to use on the Easysoft XML-ODBC Server to connect to your database. This is an ODBC connection string i.e. what is passed to the ODBC API SQLDriverconnect() function.
In its simplest form this requires a DSN name only.
For databases with built in authentication you may need to add UID and PWD attributes for the database user name and password.
"DSN=mydsn;UID=database_username;PWD=database_password;"
Data sources may require other attributes too. You should specify all these attributes in the connection string separating each one with a ';'.
"ATTRIBUTE1=value;ATTRIBUTE2=value;"
If you are still getting ODBC driver connection errors at this point, then consult your ODBC driver documentation. |
This is the database query you want to execute on the server machine. This is usually a request for elements of a table.
The result of this query (the result set) will be returned in XML.
then the command line would be either:
-c "DSN=mydsn;UID=dbuser;PWD=dbpass;"
<?xml version="1.0" encoding="UTF-8" ?>
DSN=mydsn;UID=dbuser;PWD=dbpass;
<Sql>select * from mytable</Sql>
The output should be the contents of the "mytable" table in XML. Any error that occurs is also output in XML, rather than as a result set, and both are described in the the "Documentation" subdirectory of the Easysoft XML-ODBC Server distribution.
The return status of the xmlodbc_client program is "0" for success and any other value for an error (see the code for all the possible return codes).
The XML output (including XML output generated for an error occurring on the server) is always directed to stdout and errors occurring at the client end are written to stderr (see the code for examples).
As a result you can redirect the XML output to a file in most shells with something like:
./xmlodbc_client args 1> file.xml
There are many XML parsers available on the net which have C APIs you could use with this example C client, such as Expat(http://expat.sourceforge.net), which requires very straight forward code to parse the XML output of this client, as illustrated in the accompanying examples.
This is a small Perl script which allows a query to be executed on the specified Easysoft XML-ODBC Server with the results returned exactly as the server returns them (i.e. in XML).
You can also issue configuration requests or ask for statistics.
This script uses ESXMLODBC::XMLREQUEST and its methods, so the directory ESXMLODBC needs to be on your Perl INC path.
[-s sql_query | SQL_statements_in_a_transaction]]
-h is the name of machine where the server is running
-p is the server port to connect to (usually 8895)
-c is the ODBC connection string
-t truncates trailing characters in SQL_CHAR columns (cannot be used with the -f option)
-r displays the XML request (cannot be used with the -f option)
-V prints the ESXMLODBC::XMLREQUEST version being used
-c "DSN=test;UID=dbuser;PWD=dbpassword;"
where the Easysoft XML-ODBC Server on myserver.company.co.uk listens on port 8895 to connect to the test data source with a database user name and password of dbuser and dbpassword, executes the select statement and returns the results in XML.
-c "DSN=test;UID=dbuser;PWD=dbpassword;"
"insert into users values (1,'user@domain')"
"insert into mailing values ('user@domain', 'Yes')"
where the Easysoft XML-ODBC Server on myserver.company.co.uk listens on port 8895 to connect to the test data source with a database user name and password of dbuser and dbpassword, and executes the two insert statements. If both inserts work they are committed, but if either insert fails then the transaction is rolled back.
This sends the SQL request in file.xml to the Easysoft XML-ODBC Server on myserver.company.co.uk listening on port 8895 and returns the result in XML. You can also use this method to send configuration requests or instructions (see "Example Configuration XML") and statistics requests (see "Example Statistics XML") to the Easysoft XML-ODBC Server control port.
A directory containing the Perl modules for the Easysoft XML-ODBC Server.
A Perl module containing the methods which query a particular Easysoft XML-ODBC Server (for examples of how to use this module see xmlodbc_client.pl and xmlodbc_example.pl):
You must create a new $h before using any of the other methods.
$h = ESXMLODBC::XMLREQUEST->new();
Creates a connection between the client and server and requires two attributes to achieve this:
The name or IP address of the machine where the Easysoft XML-ODBC Server is listening.
The port on which the Easysoft XML-ODBC Server is listening. Port is optional and defaults to 8895.
You may independently set Port and Server before using Connect or pass a hash reference of connection attributes to Connect.
$h->{Server} = "demo.easysoft.com";
$h->Connect({Server=>"demo.easysoft.com", Port=>"8895"});
Connect returns true on successful connection.
Closes the connection between the client and the Easysoft XML-ODBC Server.
Allows you to pass an XML request residing on the specified file directly to the Easysoft XML-ODBC Server you are connected to.
For more details of the format of these XML requests, see "sql_request.dtd".
a file called "/tmp/request.xml" containing the following data:
<ConnectionString>DSN=demo;UID=demo;PWD=easysoft;
<Sql>select * from oobdist_contact</Sql>
can then be executed as follows:
$h->Execute(/tmp/request.xml);
Allows you to send an SQL request to the Easysoft XML-ODBC Server and requires two attributes:
ConnectionString - an ODBC connection string defining the ODBC driver and database to which you want to connect.
Sql - passed either as the first argument to Execute or set as a reference to array of SQL statements you would like executed as part of a transaction (see Transactions).
You can define ConnectionString and Sql before calling Execute by setting them in the hash reference.
$h->{ConnectionString} = "DSN=demo.easysoft.com";
["insert into table values (1)",
"update table set columna = 2 where columnb = 1"];
Do not set Sql in this way unless you are using transactions.
Instead pass the SQL as the first argument to Execute:
$h->Execute("select * from table");
There are various other execution attributes which may be set in the Execute call by providing a hash reference:
$h->Execute("select * from table", {Parse=>"1"});
See Execution attributes.
These methods may be used after using Execute or ExecuteFile.
All these methods return a reference to a hash containing the column information (with a key consisting of the column name) or undef.
$h->First - return the first row in the result set
$h->Next - return the next row in the result set
$h->Last - return the last row in the result set
Note that these methods may only be used if the Execution attribute <Parse> is set to 1 before the Execute method is used.
Note that you also need Expat and XML::Parser installed (see the XML_Parser.txt file included with the distribution in the Perl section of the Client subdirectory).
$h->Execute("select * from table", {Parse=>"1"});
$hr = $xoh->First() || die "cannot get first row";
print join ("," keys %$hr), "\n"; # print column names
These attributes may be set directly in the hash off $h or by passing a hash reference to the Connect method.
<ConnectionString> (string, read/write)
The ODBC connection string to be passed to the ODBC API SQLDriverConnectW function. It consists of a number of attribute=value pairs separated by semicolons.
At its simplest a <ConnectionString> is:
where the DSN attribute names the System data source name known to the ODBC driver manager.
However, most ODBC drivers define a number of additional attributes
The user name for accessing the database.
The user name password for accessing the database.
The ODBC driver manager also accepts some specific attibutes like "Driver" and "FileDSN", which can be used to specify the ODBC driver or a data source defined in a file.
Consult a good ODBC reference and your ODBC driver's documentation for a list of all the possibilities.
These attributes may be set directly in the hash off $h or by passing a hash reference to the Execute method.
If set to true, causes the resulting XML to be parsed so the First, Next and Last methods may be used. It also sets NumRows, NumColumns and Rows (see Execution results).
If set to true, causes the Truncate Format element to be sent to the Easysoft XML-ODBC Server, requesting the removal of trailing spaces from the end of SQL_CHAR columns.
There are a number of execution result attributes which may be accessed off $h.
The XML result returned from the Easysoft XML-ODBC Server.
The number of rows in the result set. This is undefined unless Parse is set to 1 before execution.
The XML request sent to the Easysoft XML-ODBC Server. This attribute is only defined if the Execute method is used.
The number of columns in a row in the result set. This attribute is undefined unless Parse is set to true before execution.
A reference to an array of hash references.
There is one hash reference for each row in the result set. The keys to the hash reference are the column names.
This attribute is only defined if the Execute method is used.
All methods return undef for error and set ErrorState and ErrorText when an error occurs.
A five character string identifying an error, similar to ODBC states, where the string "00000" represents success and any other error state string is an error.
If Parse is set to false then <ErrorState> will always be "00000" if the request was sent to the server and a response was received, even though the XML response suggests the requested action could not be completed successfully.
In this case you need to actually examine the returned XML to identify the problem.
With Parse set to false and executing this request:
<ConnectionString>DSN=test;</ConnectionString>
<Sql><![CDATA[select * from tabledoesnotexist]]></Sql>
The returned XML is probably something like this:
<Text>[Microsoft][ODBC SQL Server Driver][SQL Server]
Invalid object name 'tabledoesnotexist'.
indicating the table did not exist, but the Execute method will return successfully and ErrorState will be "00000".
To get full ErrorState and ErrorText strings from the returned XML you need to set Parse to true. In this case ErrorState is set to either a client end error state (e.g. socket could not be created) or to the "State" attribute in the <Result> element of the result (this will always be "00000" for success or the State in the first ODBC diagnostic).
In this way you can tell if your SQL execution was successful by testing if ErrorState is equal to "00000".
A small Perl script serving as an example of how to use ESXMLODBC::XMLREQUEST.
This is a working example, but only if the constants defined for server, port, connection string and SQL are modified.
You will need to obtain and install Perl (http://www.perl.com).
If you want to parse the output XML you will also need
If the Perl interpreter is not installed in /usr/bin you will need to either:
On most types of Unix you can find out where your Perl interpreter is installed is by typing:
If, for example, the install directory is returned as
then the first line of each of the Perl sample clients would require amending to read
add the prefix "perl" when running a sample client:
perl sample_client.pl arguments
Install the Easysoft XML-ODBC Server on a machine which has an ODBC driver for your database and create a System data source for your database (User data sources are not seen by the Easysoft XML-ODBC Server, as it runs as a service).
All the example Perl clients are similar in that they need to be passed a server host (where the Easysoft XML-ODBC Server is running), an ODBC connection string (describing the data source on the server you want to connect to), some SQL to execute and a port on which the Easysoft XML-ODBC Server is listening.
For example, if the Easysoft XML-ODBC Server is installed on a Windows machine called "mywinserver.company.com" which has an ODBC driver for Microsoft SQL Server and a SQL Server database called "mydatabase":
1. Create a System DSN to describe the database:
2. Once the data source has been created, test it (there is a test button in the Microsoft SQL Server ODBC driver dialog boxes and you can also test it, once created, with an ODBC application).
3. On your client machine (where you want to issue the SQL and retrieve the results in XML) you need to install the sample Perl clients and (optionally) Expat and XML::Parser.
4. Issue a SQL query using the xmlodbc_client.pl, a database user name and password of "dbuser" and "dbpass" for SQL Server authentication and a table name of "table".
./xmlodbc_client.pl mywinserver.company.com 8895
"DSN=mydatasource;UID=dbuser;PWD=dbpass;"
The result set generated by your query will be returned in XML to stdout, but you can use standard shell redirection to direct stdout to a file if you prefer.
The sample clients do not allow you to choose the format of the returned XML, because some of them are dependent on the default Easysoft XML-ODBC Server XML output format (see the "/Documentation" subdirectory for a description of the different output formats).
Sample PHP code using the XMLODBC class with Expat to parse the XML result set, outputting it as HTML.
A PHP include file containing the XMLODBC class for use with PHP.
The XMLODBC class contains the following methods:
Connects to the Easysoft XML-ODBC Server.
The machine where the Easysoft XML-ODBC Server is located.
The port on which the Easysoft XML-ODBC Server is listening.
Executes either a single SQL statement or a transaction containing one or more SQL statements.
ConnectionString = "connection string";
SQL[0] = "insert/update/delete statement 1 of transaction";
SQL[1] = "insert/update/delete statement 2 of transaction";
Executes statements 1 and 2 together as one transaction.
Disconnects from the Easysoft XML-ODBC Server.
Defaults to false, but if set to true this modifies the request to the Easysoft XML-ODBC Server to request the truncation of all trailing blanks from SQL_CHAR columns.
The XML request issued by XMLODBC to the Easysoft XML-ODBC Server.
The XML returned from the Easysoft XML-ODBC Server.
If set to true causes the returned XML to be parsed with Expat (see http://expat.sourceforge.net).
This makes available the NumRows, NumColumns, First, Next, Last and Rows methods.
If the Parse method is set to true and in an executed state, then this is the number of rows in the result set.
If the Parse method is set to true and in an executed state, then this is the number of columns in each row in the result set.
If the Parse method is set to true and in an executed state, then this is an array of associated arrays. The first dimension is the rows in the result set.
The second dimension contains associative arrays when the column names are the keys.
row 2 - this is an associative array
prints the keys which are column names
If the Parse method is set to true and in an executed state, then this returns the first row of the result set (see Rows).
If the Parse method is set to true and in an executed state, then this returns the next row of the result set (see Rows).
If the Parse method is set to true and in an executed state, then this returns the last row of the result set (see Rows).
You need PHP and optionally Expat and XML support built in to PHP.
1. Copy XMLODBC.inc and include that file into any PHP in which you intend using the class (the example xmlodbc.phtml file contains some sample code using the class).
2. Install the Easysoft XML-ODBC Server on a machine which has an ODBC driver for your database.
3. Create a System data source for your database (User data sources are not seen by the Easysoft XML-ODBC Server, as it runs as a service).
For example, if the Easysoft XML-ODBC Server is installed on a Windows machine called "mywinserver.company.com" which has an ODBC driver for Microsoft SQL Server and a SQL Server database called "mydatabase":
4. Create a System DSN to describe the database:
5. Once the data source has been created, test it (there is a test button in the Microsoft SQL Server ODBC driver dialog boxes and you can also test it, once created, with an ODBC application).
6. On your client machine (where you want to issue the SQL and retrieve the results in XML):
To parse the returned XML you will also need Expat and XML built in to PHP.
Much of this information does not apply if you are running PHP from the command line. |
7. As an example, you may now use xmlodbc.phtml to issue a SQL query with the Easysoft XML-ODBC Server on a machine called "mywinserver.company.com", an ODBC data source called "mydatasource", a database user name and password of "dbuser" and "dbpass" (assuming SQL Server authentication is in use) and a table called "table":
$Test->Connect("mywinserver.company.com", "8895");
$Test->Execute("DSN=mydatasource;UID=dbuser;PWD=dbpass;",
// see xmlodbc.phtml for other methods.
The result set generated by your query will be returned in XML in $Result.
The sample clients do not allow you to choose the format of the returned XML, because some of them are dependent on the default Easysoft XML-ODBC Server XML output format (see "Example SQL XML"). |
http://www.wirelessdevnet.com/channels/wap/features/xmlcast_php.html
http://www.analysisandsolutions.com/code/phpxml.htm
The Java source for the client class
The compiled XmlOdbc.java file
The Java source for the example demo
The compiled XmlOdbcDemo.java file
will produce XmlOdbcDemo.class.
XmlOdbc.class is a basic client which can be used to communicate with the Easysoft XML-ODBC Server and allows SQL statements to be sent to an ODBC driver on the same machine as the Easysoft XML-ODBC Server and results to be retrieved in XML.
The protocol used is simple and documented by the Document Type Definitions distributed with the Easysoft XML-ODBC Server (see "SQL").
It has a basic constructor and six methods as follows:
public void connect(java.lang.String server)
throws java.net.UnknownHostException,
Establishes a socket connection to the Easysoft XML-ODBC Server using a default port of 8895.
server - the Easysoft XML-ODBC Server machine.
public void connect(java.lang.String server,
throws java.net.UnknownHostException,
Establishes a socket connection to the Easysoft XML-ODBC Server.
server - the Easysoft XML-ODBC Server machine.
port - the port on which the Easysoft XML-ODBC Server is listening.
public void sendRequest(java.lang.String sql,
java.lang.String odbcConnectionString)
Constructs a request in XML and sends it to the Easysoft XML-ODBC Server.
Establishes a connection to an ODBC data source on the machine on which the Easysoft XML-ODBC Server is running using the connection string supplied and executes the given query.
The result set generated can be retrieved as a string using getStringResponse() or as an input stream using getStreamResponse().
sql - the SQL query to be sent to the Easysoft XML-ODBC Server.
odbcConnectionString - the connection string.
public java.lang.String getStringResponse()
Gets an XML response from the Easysoft XML-ODBC Server as a string.
public java.io.DataInputStream getStreamResponse()
Gets an XML response from the Easysoft XML-ODBC Server as an input stream that can be passed to a parser.
public void sendXml(java.lang.String xmlrequest)
Sends an XML request to the Easysoft XML-ODBC Server given as a string parameter
xmlrequest - the XML request (see "sql_request.dtd").
1. The Easysoft XML-ODBC Server must have been installed in a location which is accessible from this machine.
2. The name of the installation machine used in [1].
3. The name of a System data source on the installation machine used in [1].
4. The name of a table in the database referenced by the System data source on the installation machine used in [1].
The XmlOdbcDemo program supports the following command line arguments:
The name of the server machine on which the Easysoft XML-ODBC Server is running. This may be an IP address, a host name or a fully qualified domain name. In each case it is passed to gethostbyname(), so your client machine needs to be able to resolve this argument value into an IP address.
Optional. If not specified port 8895 is used. This is the port the XML-ODBC Server is listening on. The Easysoft XML-ODBC Server can be configured to listen on two ports, one for database requests and one for configuration requests (these are usually ports 8895 and 8896). You should obviously send database queries to the database port (8895) and configuration requests/operations to the control port (8896).
The connection string to use on the Easysoft XML-ODBC Server to connect to your database. This is an ODBC connection string i.e. the data passed to the ODBC API SQLDriverconnect() function.
In its simplest form this is a simple DSN name
For databases with built in authentication you may need to add UID and PWD attributes for the database user name and password
"DSN=mydsn;UID=database_username;PWD=database_password;"
Data sources may require other attributes too, which should be specified in the connection string, separating each one with a ';'
"ATTRIBUTE1=value;ATTRIBUTE2=value;"
The database query to be executed on the server machine.
This is usually a request for elements of a table.
The result of this query (the result set) will be returned in XML.
Suppose you have installed the Easysoft XML-ODBC Server on "myserver", running in its default configuration (i.e. listening on ports 8895 for database requests and 8896 for configuration and control requests).
Suppose you have a Microsoft SQL Server database which contains a table called "mytable" on "myserver" with user authentication (a user name of "dbuser" and a password of "dbpass") and a data source called "mydsn" pointing to it:
java XmlOdbcDemo -h myserver -p 8895
-c "DSN=mydsn;UID=dbuser;PWD=dbpass;"
The output should be the contents of the "mytable" table in XML and if an error occurs then the error is output in XML instead of as a result set.
Both are described in the "/Documentation" subdirectory of this distribution.
The return status of the XmlOdbc program is "0" for success and any other value for an error (see the code for all the possible return values).
As the XML output (including XML output generated for an error occurring on the server) is written to stdout and errors occurring at the client end are written to stderr (see the code for examples), XML output can be redirected to a file in most shells. e.g.:
java XmlOdbcDemo args 1> file.xml
There are many XML parsers available on the net for Java that you could use with this example client.
A good parser is Expat (http://expat.sourceforge.net) and James Clark has XP for Java at http://www.jclark.com/xml/xp.
The code for parsing the XML output of this client with XP is very simple, as can be seen by the many examples that XP contains.
An example using xmlodbc.dll in Microsoft Excel.
This Active X DLL contains the following properties, collections and methods:
The number of columns in a row of the result set. Only meaningful if Parse is used.
Contains Count (the number of columns in a row of the result set) and Name (the name of the nth column). Only meaningful if Parse is used.
States whether or not a Connect call succeeded and a connection has been made.
The ODBC connection string to be passed to the Easysoft XML-ODBC Server. It may also be passed to Connect as a parameter.
The index of the current row in the result set. Only meaningful if Parse is used.
The data for the specified column in the specified row. If the value of Row is omitted, it defaults to that of CurrentRow. Only meaningful if Parse is used.
Indicates whether CurrentRow now points past the end of the result set (i.e. Next has been called repeatedly to get to the end of Data). Only meaningful if Parse is used.
The state of the last Execute call. This mirrors ODBC status codes and is always "00000" for success and some other state (e.g. "HY000") for errors. It should be checked after calling Execute to ensure the specified SQL was executed correctly.
Contains descriptive error text if ErrorState is not equal to "00000". This may be the error text for a Winsock error, an internal Easysoft XML-ODBC Server error or an error returned from the ODBC driver.
The port number on which the Easysoft XML-ODBC Server is listening. Set this before calling Connect or pass as a parameter to Connect.
The name of the server machine where the Easysoft XML-ODBC Server is running. Set this before calling Connect or pass as a parameter to Connect.
The XML returned by the Easysoft XML-ODBC Server in response to the last Execute call.
If you do not want the XML parsed, so that you can access some of the xmlodbc.dll properties, you can use this yourself.
See "Document Type Definitions" for descriptions of the XML returned from the Easysoft XML-ODBC Server (note that this Active X DLL requests and receives all result sets using the Easysoft XML-ODBC Server Long format).
The number of rows in the result set. Only meaningful if Parse is used.
Connects to an Easysoft XML-ODBC Server. ServerName and Port are optional, as they may be set using Serveror Port.
This method returns true if successful. If an error occurs use ErrorState or ErrorText to identify the problem.
Once all requests have been issued, use Disconnect.
Disconnects from an Easysoft XML-ODBC Server by closing the connection socket.
Requests the Easysoft XML-ODBC Server to which a connection has been made to access the ODBC data source defined in ConnectionStr and to issue the SQL in SQLStatement.
The value of ConnectionString may be set separately before calling Execute, rather than passing it as a parameter.
The Easysoft XML-ODBC Server will return either a result set or a status in XML to this client.
If Parse is used, ErrorState and ErrorText can be examined to see if the request was successful.
Parses the XML returned from the Easysoft XML-ODBC Server and initialises most of the xmlodbc.dll properties.
Sets CurrentRow to point to the first row in the result set.
Sets CurrentRow to point to the last row in the result set.
Register xmlodbc.dll at a DOS prompt by typing:
regsvr32 C:\WINNT\system32\xmlodbc.dll
To unregister xmlodbc.dll, type: regsvr32 -u full pathname/filename |
A Visual Basic project must be loaded and xmlexample.exe built for each target environment. |
To access a sample table on the Easysoft demonstration database:
1. Enter demo.easysoft.com into Server Name.
This is the name of a server machine at Easysoft.
See Server.
This is the number of the port on demo.easysoft.com which is listening for incoming connections.
See Port.
4. Enter DSN=pubs;UID=demo;PWD=easysoft; into Connection String.
See ConnectionString.
5. Enter select * from information_schema.tables into Query.
If the contents of Server Name, Port, Connection String and Query are not left blank they are saved when the application exits and do not have to be retyped. |
Both the sent and received XML data will be updated, even if the parameters are invalid and the operation fails. |
See Execute.
See Parse.
8. Click Firstto display the first record in the result set.
See FirstRecord, CurrentRow and Data.
9. Click Nextto display the next result set record.
See NextRecord, CurrentRow, Data and Eof.
10. Click Previousto display the previous result set record.
See PreviousRecord, CurrentRow and Data.
11. Click Lastto display the last record in the result set.
See LastRecord, CurrentRow, Data and Eof.
No. Records displays the number of rows in the requested table (see RowCount) and No. Columns displays the number of columns in each row (see ColumnCount).
If the XML is not parsed successfully, an error message is displayed in XML Result-set, State and Error Text (see ErrorState and ErrorText). |
netpipes (http://web.purplefrog.com/~thoth/netpipes/ftp) is a useful program for connecting to the Easysoft XML-ODBC Server, issuing requests and obtaining the results.
The principle benefit of netpipes is the ability to make requests from a shell script.
Once built, the hose command can be used to send a request to the Easysoft XML-ODBC Server.
hose server port -in -out sh -c
"(cat ./request.xml; sockdown) & cat > out.xml"
server is the server machine where the Easysoft XML-ODBC Server is running
port is the port on server where the Easysoft XML-ODBC Server is listening for incoming connections
request.xml is a file containing an XML request