DRBD:
DRBD (Distributed Replicated Block Device) forms the storage redundancy portition of a HA cluster setup. Explained in basic terms DRBD provides a means of achieving RAID 1 behavoir over a network, where whole block devices are mirrored accross the network.
To start off you will need 2 indentically sized raw drives or partitions. Many how-to's on the internet assume the use of whole drives, of course this will be better performance, but if you are simply getting familar with the technology you can repartition existing drives to allow for two eqaully sized raw partitions, one on each of the systems you will be using.
There are 3 DRBD replication modes:
• Protocol A: Write I/O is reported as completed as soon as it reached local disk and local TCP send buffer
• Protocol B: Write I/O is reported as completed as soon as it reached local disk and remote TCP buffer cache
• Protocol C: Write I/O is reported as completed as soon as it reached both local and remote disks.
If we were installing the HA cluster on a slow LAN or if the geogrphical seperation of the systems involved was great, then I recommend you opt for asyncronous mirroring (Protocol A) where the notifcation of a completed write operation occurs as soon as the local disk write is performed. This will greatly improve performance.
As we are setting up our HA cluster connected via a fast LAN, we will be using DRBD in fully syncronous mode, protocol C.
Protocol C involves the file system on the active node only being notified that the write operation was finished when the block is written to both disks of the cluster. Protocol C is the most commonly used mode of DRBD.
/etc/drbd.conf
global { usage-count yes; }
common { syncer { rate 10M; } }
resource r0 {
protocol C;
net {
max-buffers 2048;
ko-count 4;
}
on bailey {
device /dev/drbd0;
disk /dev/sda4;
address 192.168.1.125:7789;
meta-disk internal;
}
on giskard {
device /dev/drbd0;
disk /dev/sda3;
address 192.168.1.127:7789;
meta-disk internal;
}
}
drbd.conf explained:
Global section, usage-count. The DRBD project keeps statistics about the usage of DRBD versions. They do this by contacting a HTTP server each time a new DRBD version is installed on a system. This can be disabled by setting usage-count no;.
The common seciton contains configurations inhereted by all resources defined.
Setting the syncronisation rate, this is accoimplished by going to the syncer section and then assigning a value to the rate setting. The syncronisation rate refers to rate in which the data is being mirrored in the background. The best setting for the syncronsation rate is related to the speed of the network with which the DRBD systems are communicating on. 100Mbps ethernet supports around 12MBps, Giggabit ethernet somewhere around 125MBps.
in the configuration above, we have a resource defined as r0, the nodes are configured in the "on" host subsections.
"Device" configures the path of the logical block device that will be created by DRBD
"Disk" configures the block device that will be used to store the data.
"Address" configures the IP address and port number of the host that will hold this DRBD device.
"Meta-disk" configures the location where the metadata about the DRBD device will be stored.
You can set this to internal and DRBD will use the physical block device to store the information, by recording the metadata within the last sections of the disk.
Once you have created your configuration file, you must conduct the following steps on both the nodes.
Create device metadata.
$ drbdadm create-md r0
v08 Magic number not found
Writing meta data...
initialising activity log
NOT initialized bitmap
New drbd meta data block sucessfully created.
success
Attach the backing device.
$ drbdadm attach r0
Set the syncronisation parameters.
$ drbdadm syncer r0
Connect it to the peer.
$ drbdadm connect r0
Run the service.
$ service drbd start
Heartbeat:
Heartbeat provides the IP redundancy and the service HA functionailty.
On the failure of the primary node the VIP is assigned to the secondary node and the services configured to be HA are started on the secondary node.
Heartbeat configuration:
/etc/ha/ha.conf
## /etc/ha.d/ha.cf on node1
## This configuration is to be the same on both machines
## This example is made for version 2, comment out crm if using version 1
// replace the node variables with the names of your nodes.
crm no
keepalive 1
deadtime 5
warntime 3
initdead 20
bcast eth0
auto_failback yes
node bailey
node giskard
/etc/ha.d/authkeys
// The configuration below set authentication off, and encryption off for the authentication of nodes and their packets.
//Note make sure the authkeys file has the correct permisisions chmod 600
## /etc/ha.d/authkeys
auth 1
1 crc
/etc/ha.d/haresources
//192.168.1.40 is the VIP (Virtual IP) assigned to the cluster.
//the "smb" in the configuration line represents the service we wish to make HA
// /devdrbd0 represents the resource name you configured in the drbd.conf
## /etc/ha.d/haresources
## This configuration is to be the same on both nodes
bailey 192.168.1.40 drbddisk Filesystem::/dev/drbd0::/drbdData::ext3 smb
Some options of hdparm are dangerous and are generally listed as such in the man page.
Hdparm is available from SourceForge and there is even a version for Windows.
This article looks at After Image Journaling and audit trails in Recital using SET JOURNAL and associated commands.
Overview
After Image Journaling, used in conjunction with a structured backup policy is an effective disaster recovery solution. Any transaction that takes place on a table that is being journaled is logged in the journal file. In the event of a disk crash or similar event in which the table is lost, the journaled transactions can be reapplied to the latest backup copy of the table. Alternatively or additionally, the journal can be used to provide an audit trail to all modifications made to the table data.
NOTE: Recital also provides Before Image Journaling via BEGIN TRANSACTION / END TRANSACTION blocks, allowing unsuccessful transactions to be rolled back to a set saved state.
SET JOURNAL and RECOVER
Regular backups are an essential routine for any system, but in high-transaction environments restoration of the latest backup can still mean a major loss of data. After image journaling can successfully be used as part of your disaster recovery strategy to minimize data loss and down time. Recital after image journaling functionality is based on the use of the SET JOURNAL and RECOVER commands.
SET JOURNAL
SET JOURNAL TO [<.dbj filename> | ()] SET JOURNAL ON | OFF | ( )
The SET JOURNAL command is used to enable the After Image Journaling and audit trail for the active table. The TO <.dbj filename> clause associates the specified transaction journal file with the active table. If the journal file does not exist, it will be created. The filename can be substituted with a <expC>, enclosed in round brackets, which returns a valid filename. If no file extension is specified, ‘.dbj’ is used. When specifying a journal file, it is recommended that the journal file is stored on a different disk than that which the table is stored on, so that if a fatal disk error occurs, then the journal file will not be lost along with the table.
//Enable journaling for the southwind!orders table open database southwind use orders set journal to /journals/ord_journ
The <.dbj filename> is a standard table. It contains seven
fields that are specific to a journal file, followed by the first
249 fields of the associated table.
The first seven fields in the journal are:
|
Field |
Type |
Display |
Storage |
Description |
|
AUD_DATE |
Date |
8 | 10 * |
4 |
The date on which the transaction was performed. |
|
AUD_TIME |
Character |
8 |
8 |
The time at which the transaction was performed, in the format HH:MM:SS. |
|
AUD_TERM |
Character |
12 |
12 |
The name of the terminal from which the transaction was performed |
|
AUD_UID |
Short |
5 |
2 |
The ID of the user who performed the transaction. |
|
AUD_GID |
Short |
5 |
2 |
The group ID of the user who performed the transaction. |
|
AUD_CMD |
Short |
4 |
2 |
The command number of the transaction performed from the command table below |
|
AUD_RECNO |
Integer |
7 |
4 |
The record number in the associated table which the transaction was performed on. |
* Dependent on SET CENTURY setting.
The AUD_CMD Command Reference Numbers are as follows:
|
Command |
Number |
|
DELETE |
14 |
|
RECALL |
36 |
|
REPLACE |
41 |
|
BROWSE |
6 |
|
CHANGE |
8 |
|
EDIT |
17 |
|
INSERT |
26 |
|
APPEND |
5 |
|
READ |
35 |
Since journal files are standard Recital tables, you can use standard Recital commands such as the REPORT command to print audit trails, transaction logs, etc.
//Enable journaling for the southwind!orders table open database southwind use orders set journal to /journals/ord_journ //.. transactions close data //View journaled records use /journals/ord_journ.dbj
Click image to display full size
Fig 1: Journal Record Example.
The SET JOURNAL TO command without a <.dbj filename> specified closes the active journal file and no further journaling will take place on the active table until the SET JOURNAL TO <.dbj filename> is reissued.
The journaling features are mainly used with shared tables. It should be noted that there is an overhead in enabling transaction journaling, as records updated in a table are also written to the journal file. When records are appended into a journal file, locking is automatically performed so that multiple users can update the journal concurrently. The associated table must be opened shareable for this to occur. Each table can have a journal file associated with it.
The SET JOURNAL ON | OFF command enables or disables transaction journaling. This command is primarily used in applications where journaling can be disabled for a certain class of operations. By default, SET JOURNAL is ON, but no journal files are set.
NOTE: Only the first 249 fields of a table can be journaled: subsequent fields are ignored. The maximum number of fields in a Recital table is 256.
RECOVER
RECOVER FROM <.dbj filename> | ()
The RECOVER command uses the journal file to reapply lost transactions to a previous backup of the data after a fatal error such as a disk head crash. The FROM clause specifies the journal file to use. The file name can be substituted with an <expC>, enclosed in round brackets, which returns a valid filename. If no file extension is specified, then ‘.dbj’ is assumed.
Regular backups are essential to the successful use of After Image Journaling. It is also very important to reinitialize the journal file after each backup: either open the journal file as you would a normal table and use the ZAP command, or delete the file completely. If a fatal error occurs, such as a disk head crash, the table and index files must be restored from a backup, then the RECOVER command executed. RECOVER will reapply' all of the transactions in the journal file to the table, and update the indexes. After the RECOVER command has completed, you can continue with normal processing.
//Create a backup of the southwind!orders table //...backup table and associated files //Reinitialize the journal file erase /journals/ord_journ.dbj //Enable journaling for the southwind!orders table open database southwind use orders set journal to /journals/ord_journ //.. transactions //Restore the backup of the southwind!orders table //...restore //Open the restored backup open database southwind use orders //Reapply the transactions using the journal recover from /journals/ord_journ.dbj //Now, enable the journal file again or //restart with a new backup
Journaling Memo Fields
By default, memo fields - variable length text fields - are not journaled due to the possible storage overhead of multiple copies of potentially large blocks of text. But, if memo journaling is required, the SET MEMOJOURNAL ON command can be used to enable this.
SET MEMOJOURNAL
SET MEMOJOURNAL ON | OFF | ()
The SET MEMOJOURNAL command causes memo fields to be journaled when journaling is set on a table. This command allows the optional logical expression <expL> to be evaluated. If a value of .T. is returned, MEMOJOURNAL is set ON. If a value of .F. is returned, MEMOJOURNAL is set OFF. By default SET MEMOJOURNAL is OFF.
Like a normal Recital table, the journal holds only a pointer to a data block in an associated memo file, not the actual memo data itself. The journal's memo file has a file extension of .dbm rather than the standard Recital .dbt. Therefore, if the journal is being opened as a table, in order to view the journal's memo data, the SET MEMOEXT command should be used.
//Enable journaling for the southwind!suppliers table open database southwind use suppliers set journal to /journals/sup_journ //.. transactions close data //Set filename extension for memo file set memoext to '.dbm' //View journaled records use /journals/sup_journ.dbj
Summary
The After Image Journaling enabled by the SET JOURNAL and RECOVER commands can be used in conjunction with a strict backup regime to minimize data loss in cases where tables become damaged or irretrievable. Journal files can be accessed like standard Recital tables and provide detailed information about the transactions applied to a table, so can be used for auditing purposes.
In this article Chris Mavin, explains and details how to use the Recital Database Server with the Open Source Servlet Container Apache Tomcat.
Overview
PHP has exploded on the Internet, but its not the only way to create web applications and dynamic websites. Using Java Servlets, JavaServer Pages and Apache Tomcat you can develop web applications in a more powerful full featured Object Oriented Language, that is easier to debug, maintain, and improve.
Tomcat Installation
There are a number of popular Java application servers such as IBM Web Sphere and BEA WebLogic but today we will be talking about the use of Apache Tomcat 5, the Open Source implementation of the Java Servlet and JavaServer Pages technologies developed at the Apache Software Foundation. The Tomcat Servlet engine is the official reference implementation for both the Servlet and JSP specifications, which are developed by Sun under the Java Community Process. What this means is that the Tomcat Server implements the Servlet and JSP specifications as well or better than most commercial application servers.
Apache Tomcat is available for free but offers many of the same features that commercially available Web application containers boast.
Tomcat 5 supports the latest Servlet and JSP specifications, Servlet 2.4, and JSP 2.0, along with features such as:
-
Tomcat can run as a standalone webserver or a Servlet/JSP engine for other Web Servers.
-
Multiple connectors - for enabling multiple protocol handlers to access the same Servlet engine.
-
JNDI - The Java Naming and Domain Interface is supported.
-
Realms - Databases of usernames and passwords that identify valid users of a web application.
-
Virtual hosts - a single server can host applications for multiple domain names. You need to edit server.xml to configure virtual hosts.
-
Valve chains.
-
JDBC - Tomcat can be configured to use any JDBC driver.
-
DBCP - Tomcat can use the Apache commons DBCP for connection pooling.
-
Servlet reloading (Tomcat monitors any changes to the classes deployed within that web server.)
-
HTTP functionality - Tomcat functions as a fully featured Web Server.
-
JMX, JSP and Struts-based administration.
Tomcat Installation
In this next two sections we will walk through the install and setup of Tomcat for use with the Recital database server.
To download Tomcat visit the Apache Tomcat web site is at http://jakarta.apache.org/tomcat.
Follow the download links to the binary for the hardware and operating system you require.
For Tomcat to function fully you need a full Java Development Kit (JDK). If you intend to simply run pre compiled JavaServer pages you can do so using just the Java Runtime Environment(JRE).
The JDK 1.5 is the preferred Java install to work with Tomcat 5, although it is possible to run Tomcat 5 with JDK 1.4 but you will have to download and install the compat archive available from the Tomcat website.
For the purpose of this article we will be downloading and using Tomcat 5 for Linux and JDK 5.0,
you can download the JDK at http://java.sun.com/javase/downloads/index.jsp.
Now we have the JDK, if the JAVA_HOME environment variable isn't set we need to set it to refer to the base JDK install directory.
Linux/Unix:
$ JAVA_HOME= /usr/lib/j2se/1.4/ $ EXPORT $JAVA_HOME
Windows NT/2000/XP:
Follow the following steps:
1. Open Control Panel.
2. Click the System icon.
3. Go to the Advanced tab.
4. Click the Environment Variables button.
5. Add the JAVA_HOME variable into the system environment variables.
The directory structure of a Tomcat installation comprises of the following:
/bin - Contains startup, shutdown and other scripts. /common - Common classes that the container and web applications can use. /conf - Contains Tomcat XML configuration files XML files. /logs - Serlvet container and application logs. /server - Classes used only by the Container. /shared - Classes shared by all web application. /webapps - Directory containing the web applications. /work - Temporary directory for files and directories.
The important files that you should know about are the following:
-
server.xml
The Tomcat Server main configuration file is the [tomcat install path]\conf\server.xml file. This file is mostly setup correctly for general use. It is within this file where you specify the port you wish to be running the server on. Later in this article I show you how to change the default port used from 8080 to port 80.
-
web.xml
The web.xml file provides the configuration for your web applications. There are two locations where the web.xml file is used,
web-inf\web.xml provides individual web application configurations and [tomcat install path]conf\web.xml contains the server wide configuration.
Setting up Tomcat for use
We'll start by changing the port that Tomcat will be listening on to 80.
To do this we need to edit [tomcat install path]/conf/server.xml and change the port attribute of the connector element from 8080 to 80.
After you have made the alteration the entry should read as:
<!-- Define a non-SSL HTTP/1.1 Connector on port 8080 --> <Connector port="80" maxHttpHeaderSize="8192"
Next we want to turn on Servlet reloading, this will cause the web application to be recompiled each time it is accessed, allowing us to make changes to the files without having to worry about if the page is being recompiled or not.
To enable this you need to edit [tomcat install path]/conf/context.xml and change <Context> element to <Context reloadable="true">.
After you have made the alteration the entry should read as:
<Context reloadable="true"> <WatchedResource>WEB-INF/web.xml</WatchedResource> </Context>
Next we want to enable the invoker Servlet.
The "invoker" Servlet executes anonymous Servlet classes that have not been defined in a web.xml file. Traditionally, this Servlet is mapped to the URL pattern "/servlet/*", but you can map it to other patterns as well. The extra path info portion of such a request must be the fully qualified class name of a Java class that implements Servlet, or the Servlet name of an existing Servlet definition.
To enable the invoker Servlet you need to edit the to [tomcat install path]/conf/web.xml and uncomment the Servlet and Servlet-mapping elements that map the invoker /servlet/*.
After you have made the alteration the entry should read as:
<servlet> <servlet-name>invoker</servlet-name> <servlet-class>org.apache.catalina.servlets.InvokerServlet</servlet-class> <init-param> <param-name>debug</param-name> <param-value>0</param-value> </init-param> <load-on-startup>2</load-on-startup> </servlet> <servlet-mapping> <servlet-name>invoker</servlet-name> <url-pattern>/servlet/*</url-pattern> </servlet-mapping>
If you are you not interested in setting up your own install of Tomcat there are prebuilt versions Tomcat that has all of the above changes already made, and has the test HTML, JSP, and Servlet files already bundled. Just unzip the file, set your JAVA_HOME
Next we will give Tomcat and your web applications access to the Recital JDBC driver.
For the purposes of this article we are going to install the Recital JDBC driver in the /[tomcat install path]/common/lib/ this gives Tomcat and your web applications access to the Recital JDBC driver. The driver can be installed in a number of places in the Tomcat tree, giving access to the driver to specific application or just to the web application and not the container. For more information refer to the Tomcat documentation.
Copy the recitalJDBC.jar which is located at /[recital install path]/drivers/recitalJDBC.jar to the /[tomcat install path]/common/lib/ directory.
Linux:
$cp /[recital install path]/drivers/recitalJDBC.jar /[tomcat install path]/common/lib/
Once you have completed all the steps detailed above, fire up the server using the script used by your platform's Tomcat installation.
Linux/Unix:
[tomcat install path]/bin/startup.sh
Windows:
[tomcat install path]/bin/startup
If you are having problems configuring your Tomcat Installation or would like more detail visit the online documentation a the Apache Tomcat site.
Example and Links
Now we have setup our Tomcat installation, lets get down to it with a JSP example which uses the Recital JDBC driver to access the demonstration database (southwind) shipped with the Recital Database Server.
The example provided below is a basic JDBC web application, where the user simply selects a supplier from the listbox and requests the products supplied by that supplier.
To run the example download and extract the tar archive or simple save each of the two jsp pages individually into /[tomcat install path]/webapps/ROOT/ on your server.
By enabling the invoker Servlet earlier we have removed the need to set the example up as a web application in the Tomcat configuration files.
You can now access the example web application at http://[Server Name]/supplier.jsp if the page doesn't display, check you have followed all the Tomcat installation steps detailed earlier in this article and then make sure both Tomcat and a licensed Recital UAS are running.
Downloads:
Archive: jspExample.tar
Right click and save as individual files and rename as .jsp files:
supplier.txt details.txt
Further Reading on JSP and JDBC can be found at http://www-128.ibm.com/developerworks/java/library/j-webdata/
Final Thoughts
Recital and Apache tomcat are a powerful combination, using Java Servlet technology you can separate application logic and the presentation extremely well. Tomcat, JSP, Java Servlets and the Recital database server form a robust platform independent, easily maintained and administered solution with which to unlock the power of your Recital, Foxpro, Foxbase, Clipper, RMS and C-SAM data.
On entry to the .rsp page.
IF type( _session["state"] ) != "U"m_state = _session["state"]RESTORE DATASESSION FROM m_state
ELSE
// open up your tables for the first timeENDIF
SAVE DATASESSION TO m_state_SESSION["state"] = m_state
In this article Barry Mavin, CEO and Chief Software Architect for Recital provides details on how to use the Recital Universal .NET Data Provider with the Recital Database Server.
Overview
A data provider in the .NET Framework serves as a bridge between an application and a data source. A data provider is used to retrieve data from a data source and to reconcile changes to that data back to the data source.
Each .NET Framework data provider has a DataAdapter object: the .NET Framework Data Provider for OLE DB is the OleDbDataAdapter object, the .NET Framework Data Provider for SQL Server is the SqlDataAdapter object, the .NET Framework Data Provider for ODBC is the OdbcDataAdapter object, and the .NET Framework Data Provider for the Recital Database Server is the RecitalDataAdapter object.
The Recital Universal .NET Data Provider can access any data sources supported by the Recital Database Server. It is not restricted to only access Recital data. It can be used to access server-side ODBC, JDBC and OLE DB data sources also.
Core classes of the Data Provider
The Connection, Command, DataReader, and DataAdapter objects represent the core elements of the .NET Framework data provider model. The Recital Universal .NET Data Provider is plug compatible with the .NET Framework Data Provider for SQL Server. All SQL Server classes are prefixed with "Sql" e.g. SqlDataAdaptor. To use the Recital Universal Data Adaptor, simply change the "Sql" prefix to "Recital" e.g. RecitalDataAdaptor.
The following table describes these objects.
| Object | Description |
|---|---|
| RecitalConnection | Establishes a connection to a specific data source. |
| RecitalCommand | Executes a command against a data source. |
| RecitalDataReader | Reads a forward-only, read-only stream of data from a data source. |
| RecitalDataAdapter | Populates a DataSet and resolves updates with the data source. |
Along with the core classes listed in the preceding table, a .NET Framework data provider also contains the classes listed in the following table.
| Object | Description |
|---|---|
| RecitalTransaction | Enables you to enlist commands in transactions at the data source. |
| RecitalCommandBuilder | A helper object that will automatically generate command properties of a DataAdapter or will derive parameter information from a stored procedure and populate the Parameters collection of a Command object. |
| RecitalParameter | Defines input, output, and return value parameters for commands and stored procedures. |
The Recital Universal .NET Data Provider provides connectivity to the Recital Database Server running on any supported platform (Windows, Linux, Unix, OpenVMS) using the RecitalConnection object. The Recital Universal .NET Data Provider supports a connection string format that is similar to the SQL Server connection string format.
The basic format of a connection string consists of a series of keyword/value pairs separated by semicolons. The equal sign (=) connects each keyword and its value.
The following table lists the valid names for keyword values within the ConnectionString property of the RecitalConnection class.
| Name | Default | Description |
|---|---|---|
| Data Source -or- Server -or- Servername -or- Nodename |
The name or network address of the instance of the Recital Database Server which to connect to. | |
| Directory | The target directory on the remote server where data to be accessed resides. This is ignored when a Database is specified. | |
| Encrypt -or- Encryption |
false | When true, DES3 encryption is used for all data sent between the client and server. |
| Initial Catalog -or- Database |
The name of the database on the remote server. | |
| Password -or- Pwd |
The password used to authenticate access to the remote server. | |
| User ID -or- uid -or- User -or- Username |
The user name used to authenticate access to the remote server. | |
| Connection Pooling -or- Pool |
false | Enable connection pooling to the server. This provides for one connection to be shared. |
| Logging | false | Provides for the ability to log all server requests for debugging purposes |
| Rowid | true | When Rowid is true (the default) a column will be post-fixed to each SELECT query that is a unique row identifier. This is used to provide optimised UPDATE and DELETE operations. If you use the RecitalSqlGrid, RecitalSqlForm, or RecitalSqlGridForm components then this column is not visible but is used to handle updates to the underlying data source. |
| Logfile | The name of the logfile for logging | |
| Gateway |
Opens an SQL gateway(Connection) to a foreign SQL data source on the remote server.
The gateway can be specified in several formats: |
Populating a DataSet from a DataAdaptor
The ADO.NET DataSet is a memory-resident representation of data that provides a consistent relational programming model independent of the data source. The DataSet represents a complete set of data including tables, constraints, and relationships among the tables. Because the DataSet is independent of the data source, a DataSet can include data local to the application, as well as data from multiple data sources. Interaction with existing data sources is controlled through the DataAdapter.
A DataAdapter is used to retrieve data from a data source and populate tables within a DataSet. The DataAdapter also resolves changes made to the DataSet back to the data source. The DataAdapter uses the Connection object of the .NET Framework data provider to connect to a data source and Command objects to retrieve data from and resolve changes to the data source.
The SelectCommand property of the DataAdapter is a Command object that retrieves data from the data source. The InsertCommand, UpdateCommand, and DeleteCommand properties of the DataAdapter are Command objects that manage updates to the data in the data source according to modifications made to the data in the DataSet.
The Fill method of the DataAdapter is used to populate a DataSet with the results of the SelectCommand of the DataAdapter. Fill takes as its arguments a DataSet to be populated, and a DataTable object, or the name of the DataTable to be filled with the rows returned from the SelectCommand.
The Fill method uses the DataReader object implicitly to return the column names and types used to create the tables in the DataSet, as well as the data to populate the rows of the tables in the DataSet. Tables and columns are only created if they do not already exist; otherwise Fill uses the existing DataSet schema.
Examples in C#:
////////////////////////////////////////////////////////////////////////
// include the references below
using System.Data;
using Recital.Data;
////////////////////////////////////////////////////////////////////////
// The following code example creates an instance of a DataAdapter that
// uses a Connection to the Recital Database Server Southwind database
// and populates a DataTable in a DataSet with the list of customers.
// The SQL statement and Connection arguments passed to the DataAdapter
// constructor are used to create the SelectCommand property of the DataAdapter.
public DataSet SelectCustomers()
{
RecitalConnection swindConn = new
RecitalConnection("Data Source=localhost;Initial Catalog=southwind");
RecitalCommand selectCMD = new
RecitalCommand("SELECT CustomerID, CompanyName FROM Customers", swindConn);
selectCMD.CommandTimeout = 30;
RecitalDataAdapter custDA = new RecitalDataAdapter();
custDA.SelectCommand = selectCMD;
swindConn.Open();
DataSet custDS = new DataSet();
custDA.Fill(custDS, "Customers");
swindConn.Close();
return custDS;
}
////////////////////////////////////////////////////////////////////////
// The following example uses the RecitalCommand, RecitalDataAdapter and
// RecitalConnection, to select records from a database, and populate a
// DataSet with the selected rows. The filled DataSet is then returned.
// To accomplish this, the method is passed an initialized DataSet, a
// connection string, and a query string that is a SQL SELECT statement
public DataSet SelectRecitalRows(DataSet dataset, string connection, string query)
{
RecitalConnection conn = new RecitalConnection(connection);
SqlDataAdapter adapter = new RecitalDataAdapter();
adapter.SelectCommand = new RecitalCommand(query, conn);
adapter.Fill(dataset);
return dataset;
} After an extended period of intense software development, we are pleased to announce the release of Recital 10 which is a milestone in our development efforts.
The Recital 10 release notes can be found here.
- Recital
A powerful scripting language with an embedded database used for developing desktop database applications on Linux and Unix.
- Recital Server
A cross-platform SQL database and application server.
- Recital Web
A server-side scripting language with an embedded SQL database for creating web 2.0 web applications.
- Warnings
- Headers
- Icon set 1
- Icon set 2
- Icon set 3
- Tooltips
- Highlights
- Code
- Unordered lists
- Ordered lists
- Abbrs and acronyms
- Definition lists
- Legends
- Dropcaps
- Floated blocks
- Other span blocks
- Blockquotes
- Tables
Warnings
This is a sample info message. Use <p class="gkInfo1">Your info message goes here!</p>.
This is a sample tips message. Use <p class="gkTips1">Your tips goes here!</p>.
This is a sample warning message. Use <p class="gkWarning1">Your warning message goes here!</p>.
This is a sample info message. Use <p class="gkInfo2">Your info message goes here!</p>.
This is a sample tips message. Use <p class="gkTips2">Your tips goes here!</p>.
This is a sample warning message. Use <p class="gkWarning2">Your warning message goes here!</p>.
This is a sample info message. Use <p class="gkInfo3">Your info message goes here!</p>.
This is a sample tips message. Use <p class="gkTips3">Your tips goes here!</p>.
This is a sample warning message. Use <p class="gkWarning3">Your warning message goes here!</p>.
This is a sample info message. Use <p class="gkInfo4">Your info message goes here!</p>.
This is a sample tips message. Use <p class="gkTips4">Your tips goes here!</p>.
This is a sample warning message. Use <p class="gkWarning4">Your warning message goes here!</p>.
This is a sample info message. Use <p class="gkInfo5">Your info message goes here!</p>.
This is a sample tips message. Use <p class="gkTips5">Your tips goes here!</p>.
This is a sample warning message. Use <p class="gkWarning5">Your warning message goes here!</p>.
Headers
This is heading 1
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer semper egestas nunc in volutpat. Fusce adipiscing velit ac eros tempor iaculis. Phasellus venenatis mollis augue, non posuere odio placerat in. Etiam volutpat ultrices lectus. Fusce eu felis erat. Donec congue interdum elit, sed ornare magna convallis lacinia. In hac habitasse platea dictumst. Mauris volutpat consectetur accumsan.
This is heading 2
Cras diam justo, sodales quis lobortis sed, lobortis vel mauris. Sed a mollis nunc. Quisque semper condimentum lectus, eget laoreet ipsum auctor et. Quisque sagittis luctus augue, id fringilla enim euismod quis. Nullam blandit, elit at euismod rutrum, tortor nibh posuere mauris, in volutpat diam ante ac dui. Sed velit massa, imperdiet placerat tristique et, consectetur a lorem. Praesent aliquet turpis in quam tempor eu pulvinar nibh luctus.
This is heading 3
Vivamus rhoncus arcu sit amet est tristique convallis nec vel eros. Vestibulum euismod luctus velit quis porta. Aliquam varius placerat mauris sed vehicula. Integer porta facilisis sapien, in tempus lorem mattis molestie. Suspendisse potenti. Praesent quis diam non dolor convallis mattis eu id nulla.
This is heading 4
Proin urna erat, egestas vel consectetur at, accumsan at purus. Donec est risus, facilisis dignissim placerat nec, euismod lacinia nisi. Nam ac sem sed quam sollicitudin condimentum et eu neque. Nunc enim urna, ultricies ac mollis pretium, imperdiet hendrerit massa. Sed eleifend felis sed tellus cursus lacinia. Aenean venenatis aliquet euismod. Nam quis turpis tellus, vitae malesuada neque.
This is a headline.
This is a subheadline.
Use <p class="gkHeadling">for headline</p>.Use <p class="gkSubHeadline">for subheadline</p>.Proin urna erat, egestas vel consectetur at, accumsan at purus. Donec est risus, facilisis dignissim placerat nec, euismod lacinia nisi. Nam ac sem sed quam sollicitudin condimentum et eu neque. Nunc enim urna, ultricies ac mollis pretium, imperdiet hendrerit massa. Sed eleifend felis sed tellus cursus lacinia. Aenean venenatis aliquet euismod. Nam quis turpis tellus, vitae malesuada neque.
This is a small headline
This is a large headline
Use <p class="gkHeadling">for headline</p>.Use <p class="gkSubHeadline">for subheadline</p>.Proin urna erat, egestas vel consectetur at, accumsan at purus. Donec est risus, facilisis dignissim placerat nec, euismod lacinia nisi. Nam ac sem sed quam sollicitudin condimentum et eu neque. Nunc enim urna, ultricies ac mollis pretium, imperdiet hendrerit massa. Sed eleifend felis sed tellus cursus lacinia. Aenean venenatis aliquet euismod. Nam quis turpis tellus, vitae malesuada neque.
Icon set 1
This is a sample audio message. Use <p class="gkAudio">Your audio message goes here!</p>.
This is a sample webcam message. Use <p class="gkWebcam">Your webcam goes here!</p>.
This is a sample email message. Use <p class="gkEmail">Your email message goes here!</p>.
This is a sample creditcard message. Use <p class="gkCreditcard">Your creditcart message goes here!</p>.
This is a sample feed message. Use <p class="gkFeed">Your feed goes here!</p>.
This is a sample help message. Use <p class="gkHelp">Your help message goes here!</p>.
This is a sample images message. Use <p class="gkImages">Your images message goes here!</p>.
This is a sample lock message. Use <p class="gkLock">Your webcam goes here!</p>.
This is a sample printer message. Use <p class="gkPrinter">Your printer message goes here!</p>.
This is a sample report message. Use <p class="gkReport">Your report message goes here!</p>.
This is a sample script message. Use <p class="gkScript">Your script goes here!</p>.
This is a sample time message. Use <p class="gkTime">Your time message goes here!</p>.
This is a sample user message. Use <p class="gkUser">Your user message goes here!</p>.
This is a sample world message. Use <p class="gkWorld">Your world goes here!</p>.
This is a sample cart message. Use <p class="gkCart">Your cart message goes here!</p>.
This is a sample cd message. Use <p class="gkCd">Your cd message goes here!</p>.
This is a sample chart_bar message. Use <p class="gkChartBar">Your chart_bar goes here!</p>.
This is a sample chart_line message. Use <p class="gkChartLine">Your chart_line message goes here!</p>.
This is a sample chart_pie message. Use <p class="gkChartPie">Your chart_pie message goes here!</p>.
This is a sample clock message. Use <p class="gkClock">Your clock goes here!</p>.
This is a sample cog message. Use <p class="gkCog">Your cog message goes here!</p>.
This is a sample coins message. Use <p class="gkCoins">Your coins message goes here!</p>.
This is a sample compress message. Use <p class="gkCompress">Your compress goes here!</p>.
This is a sample computer message. Use <p class="gkComputer">Your computer message goes here!</p>.
This is a sample cross message. Use <p class="gkCross">Your cross message goes here!</p>.
This is a sample disk message. Use <p class="gkDisk">Your disk goes here!</p>.
This is a sample error message. Use <p class="gkError">Your error message goes here!</p>.
This is a sample exclamation message. Use <p class="gkExclamation">Your exclamation message goes here!</p>.
This is a sample film message. Use <p class="gkFilm">Your film goes here!</p>.
This is a sample folder message. Use <p class="gkFolder">Your folder message goes here!</p>.
This is a sample group message. Use <p class="gkGroup">Your group message goes here!</p>.
This is a sample heart message. Use <p class="gkHeart">Your heart goes here!</p>.
This is a sample house message. Use <p class="gkHouse">Your house message goes here!</p>.
This is a sample image message. Use <p class="gkImage">Your image message goes here!</p>.
This is a sample information message. Use <p class="gkInformation">Your information message goes here!</p>.
This is a sample magnifier message. Use <p class="gkMagnifier">Your magnifier message goes here!</p>.
This is a sample money message. Use <p class="gkMoney">Your money goes here!</p>.
This is a sample new message. Use <p class="gkNew">Your new message goes here!</p>.
This is a sample note message. Use <p class="gkNote">Your note message goes here!</p>.
This is a sample page message. Use <p class="gkPage">Your page goes here!</p>.
This is a sample page_white message. Use <p class="gkPage_white">Your page_white message goes here!</p>.
This is a sample plugin message. Use <p class="gkPlugin">Your plugin message goes here!</p>.
This is a sample accept message. Use <p class="gkAccept">Your accept goes here!</p>.
This is a sample add message. Use <p class="gkAdd">Your add message goes here!</p>.
This is a sample camera message. Use <p class="gkCamera">Your camera message goes here!</p>.
This is a sample brick message. Use <p class="gkBrick">Your brick goes here!</p>.
This is a sample box message. Use <p class="gkBox">Your box message goes here!</p>.
This is a sample calendar message. Use <p class="gkCalendar">Your calendar message goes here!</p>.
Icon set 2
This is a sample audio message. Use <p class="gkAudioIs2">Your audio message goes here!</p>.
This is a sample email message. Use <p class="gkEmailIs2">Your email message goes here!</p>.
This is a sample feed message. Use <p class="gkFeedIs2">Your feed message goes here!</p>.
This is a sample images message. Use <p class="gkImagesIs2">Your images message goes here!</p>.
This is a sample lock message. Use <p class="gkLockIs2">Your lock message goes here!</p>.
This is a sample printer message. Use <p class="gkPrinterIs2">Your printer message goes here!</p>.
This is a sample time message. Use <p class="gkTimeIs2">Your time message goes here!</p>.
This is a sample user message. Use <p class="gkUserIs2">Your calendar message goes here!</p>.
This is a sample world message. Use <p class="gkWorldIs2">Your world message goes here!</p>.
YThis is a sample cart message. Use <p class="gkCartIs2">Your cart message goes here!</p>.
This is a sample cd message. Use <p class="gkCdIs2">Your cd message goes here!</p>.
This is a sample chart line message. Use <p class="gkChartLineIs2">Your chart line message goes here!</p>.
This is a sample chart pie message. Use <p class="gkChartPieIs2">Your calendar message goes here!</p>.
This is a sample clock message. Use <p class="gkClockIs2">Your clock message goes here!</p>.
This is a sample config message. Use <p class="gkCogIs2">Your config message goes here!</p>.
This is a sample computer message. Use <p class="gkComputerIs2">Your computer message goes here!</p>.
This is a sample error message. Use <p class="gkErrorIs2">Your error message goes here!</p>.
This is a sample exclamation message. Use <p class="gkExclamationIs2">Your exclamation message goes here!</p>.
This is a sample movie message. Use <p class="gkFilmIs2">Your movie message goes here!</p>.
This is a sample folder message. Use <p class="gkFolderIs2">Your folder message goes here!</p>.
This is a group calendar message. Use <p class="gkGroupIs2">Your group message goes here!</p>.
This is a sample house message. Use <p class="gkHouseIs2">Your house message goes here!</p>.
This is a sample image message. Use <p class="gkImageIs2">Your image message goes here!</p>.
This is a sample information message. Use <p class="gkInfromationIs2">Your information message goes here!</p>.
This is a sample magnifier message. Use <p class="gkMagnifierIs2">Your magnifier message goes here!</p>.
This is a sample money message. Use <p class="gkMoneyIs2">Your money message goes here!</p>.
This is a sample page message. Use <p class="gkPageIs2">Your page message goes here!</p>.
This is a sample camera message. Use <p class="gkCameraIs2">Your camera message goes here!</p>.
This is a calendar feed message. Use <p class="gkCalendarIs2">Your calendar message goes here!</p>.
This is a sample contact message. Use <p class="gkContactIs2">Your contact message goes here!</p>.
This is a sample facebook message. Use <p class="gkFacebookIs2">Your facebook message goes here!</p>.
This is a sample like it message. Use <p class="gkLikeItIs2">Your like it message goes here!</p>.
This is a sample twitter message. Use <p class="gkTwitterIs2">Your twitter message goes here!</p>.
This is a sample video message. Use <p class="gkVideoIs2">Your video message goes here!</p>.
This is a sample youtube message. Use <p class="gkYoutubeIs2">Your youtube message goes here!</p>.
Icon set 3
This is a sample audio message. Use <p class="gkAudioIs3">Your audio message goes here!</p>.
This is a sample camera message. Use <p class="gkCameraIs3">Your camera message goes here!</p>.
This is a sample lock message. Use <p class="gkLockIs3">Your lock message goes here!</p>.
This is a sample user message. Use <p class="gkUserIs3">Your user message goes here!</p>.
This is a sample cart message. Use <p class="gkCartIs3">Your cart message goes here!</p>.
This is a sample chart bar message. Use <p class="gkChartBarIs3">Your chart bar message goes here!</p>.
This is a sample config message. Use <p class="gkConfigIs3">Your config message goes here!</p>.
This is a sample configuration message. Use <p class="gkConfig2Is3">Your configuration message goes here!</p>.
This is a sample computer message. Use <p class="gkComputerIs3">Your computer message goes here!</p>.
This is a sample coffe message. Use <p class="gkCoffeIs3">Your coffe message goes here!</p>.
This is a sample cross message. Use <p class="gkCrossIs3">Your cross message goes here!</p>.
This is a sample error message. Use <p class="gkErrorIs3">Your error message goes here!</p>.
This is a sample house message. Use <p class="gkHouseIs3">Your house message goes here!</p>.
This is a sample information message. Use <p class="gkInformationIs3">Your inforation message goes here!</p>.
This is a sample magnifier message. Use <p class="gkMagnifierIs3">Your magnifier message goes here!</p>.
This is a sample page message. Use <p class="gkPageIs3">Your page message goes here!</p>.
This is a sample lock message. Use <p class="gkLockIs3">Your lock message goes here!</p>.
This is a sample camera message. Use <p class="gkCameraIs3">Your camera message goes here!</p>.
This is a sample star message. Use <p class="gkStarIs3">Your star message goes here!</p>.
This is a sample telephone message. Use <p class="gkTelephoneIs3">Your telephone message goes here!</p>.
Tooltips
Here are some examples of a ClassicThis is just an example of what you can do using a CSS tooltip, feel free to get creative and produce your own!, CriticalCriticalThis is just an example of what you can do using a CSS tooltip, feel free to get creative and produce your own!, HelpHelpThis is just an example of what you can do using a CSS tooltip, feel free to get creative and produce your own!, InformationInformationThis is just an example of what you can do using a CSS tooltip, feel free to get creative and produce your own! and WarningWarningThis is just an example of what you can do using a CSS tooltip, feel free to get creative and produce your own! CSS powered tooltip. This is just an example of what you can do so feel free to get creative and produce your own!
Highlights
This is a highlight phrase. Use <span class="gkHighlight1">Your highlight phrase goes here!</span>.
This is a highlight phrase. Use <span class="gkHighlight2">Your highlight phrase goes here!</span>.
This is a highlight phrase. Use <span class="gkHighlight3">Your highlight phrase goes here!</span>.
This is a highlight phrase. Use <span class="gkHighlight4">Your highlight phrase goes here!</span>.
Code
Below is a sample of <pre> or <div class="gkCode1">
#wrapper {
position: relative;
float: left;
display: block;
}
Below is a sample of <div class="gkCode2">
position: relative;
float: left;
display: block;
}
Below is a sample of <div class="gkCode3"><h4>Name of your file</h4>Here goes your code</div>
File
#wrapper {position: relative;
float: left;
display: block;
}
Unordered lists
Types of unordered lists
|
<ul class="gkBullet1">
|
<ul class="gkBullet2">
|
<ul class="gkBullet3">
|
|
<ul class="gkBullet4">
|
<ul class="gkCircle1">
|
<ul class="gkCircle2">
|
|
<ul class="gkSquare1">
|
<ul class="gkSquare2">
|
<ul class="gkSquare3">
|
Ordered lists
Types of ordered list:
|
<ol class="gkRoman">
|
<ol class="gkDec">
|
<ol class="gkAlpha">
|
<ol class="gkDecimalLeadingZero">
|
<div class="gkNumber1"><p><span>here goes a number</span>and here text of element</p>
01 Element
02 Element
<div class="gkNumber2"><p><span>here goes a number</span>and here text of element</p>
01 Element
02 Element
Abbrs and acronyms
This is a sample of an abbreviation Dr. Use <abbr title="Here goes full word or phrase">here goes an abbreviation</abbr>
This is a sample of an acronym NATO. Use <acronym title="Here goes full phrase">here goes an acronym</abbr>
Definition lists
Below are samples of definition lists
<dl class="gkDef1"><dt>Here goes the word you're about to define</dt><dd>Here goes definition</dd></dl>
- Butter
- it is a dairy product made by churning fresh or fermented cream or milk. It is generally used as a spread and a condiment, as well as in cooking applications such as baking, sauce making, and frying. Butter consists of butterfat, water and milk proteins.
- Dairy milk
- is an opaque white liquid produced by the mammary glands of mammals (including monotremes). It provides the primary source of nutrition for newborn mammals before they are able to digest other types of food.
<dl class="gkDef2"><dt>Here goes the word you're about to define</dt><dd>Here goes definition</dd></dl>
- Butter
- it is a dairy product made by churning fresh or fermented cream or milk. It is generally used as a spread and a condiment, as well as in cooking applications such as baking, sauce making, and frying. Butter consists of butterfat, water and milk proteins.
- Dairy milk
- is an opaque white liquid produced by the mammary glands of mammals (including monotremes). It provides the primary source of nutrition for newborn mammals before they are able to digest other types of food.
<dl class="gkDef3"><dt>Here goes the word you're about to define</dt><dd>Here goes definition</dd></dl>
- Butter
- it is a dairy product made by churning fresh or fermented cream or milk. It is generally used as a spread and a condiment, as well as in cooking applications such as baking, sauce making, and frying. Butter consists of butterfat, water and milk proteins.
- Dairy milk
- is an opaque white liquid produced by the mammary glands of mammals (including monotremes). It provides the primary source of nutrition for newborn mammals before they are able to digest other types of food.
Legends
Legend
This is a sample legend note. Use <div class="gkLegend1"> <h4> Title </h4> <p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</p> </div>.
Legend
This is a sample legend note. Use <div class="gkLegend2"> <h4> Title </h4> <p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</p> </div>.
Legend
This is a sample legend note. Use <div class="gkLegend3"> <h4> Title </h4> <p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</p> </div>.
Legend
This is a sample legend note. Use <div class="gkLegend4"> <h4> Title </h4> <p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</p> </div>.
Legend
This is a sample legend note. Use <div class="gkLegend5"> <h4> Title </h4> <p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</p> </div>.
Legend
This is a sample legend note. Use <div class="gkLegend6"> <h4> Title </h4> <p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</p> </div>.
Legend
This is a sample legend note. Use <div class="gkLegend7"> <h4> Title </h4> <p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</p> </div>.
Dropcaps
This is a sample text with Dropcap. Use <p> <span class="gkDropcap1">t</span> to make the first letter larger. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum condimentum pulvinar justo, sed faucibus ligula feugiat ac. Morbi quis enim nulla, vel congue augue. Duis quis quam sed purus porta eleifend. Vivamus ullamcorper est id libero aliquam ullamcorper. Donec eget dignissim augue. Donec ante felis, aliquam ut consequat eget, lobortis dapibus risus. Aliquam laoreet enim et lectus ornare hendrerit. Aliquam rhoncus enim libero. Morbi aliquam, nibh mattis feugiat dapibus, nisi massa adipiscing justo, sit amet condimentum urna ipsum et lacus. Nam fermentum, eros quis ullamcorper convallis, libero mauris lacinia eros, sed tempus leo lorem vitae purus. Nunc a malesuada felis. Cras ultrices sapien eu nisi elementum non blandit urna sodales. Duis accumsan cursus massa, eu facilisis diam porta ut..</p>.
This is a sample text with Dropcap. Use <p> <span class="gkDropcap2">t</span> to make the first letter larger. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum condimentum pulvinar justo, sed faucibus ligula feugiat ac. Morbi quis enim nulla, vel congue augue. Duis quis quam sed purus porta eleifend. Vivamus ullamcorper est id libero aliquam ullamcorper. Donec eget dignissim augue. Donec ante felis, aliquam ut consequat eget, lobortis dapibus risus. Aliquam laoreet enim et lectus ornare hendrerit. Aliquam rhoncus enim libero. Morbi aliquam, nibh mattis feugiat dapibus, nisi massa adipiscing justo, sit amet condimentum urna ipsum et lacus. Nam fermentum, eros quis ullamcorper convallis, libero mauris lacinia eros, sed tempus leo lorem vitae purus. Nunc a malesuada felis. Cras ultrices sapien eu nisi elementum non blandit urna sodales. Duis accumsan cursus massa, eu facilisis diam porta ut..</p>.
This is a sample text with Dropcap. Use <p class="gkDropcap3"> <span class="gkDropcap3">t</span> to make the first letter larger. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum condimentum pulvinar justo, sed faucibus ligula feugiat ac. Morbi quis enim nulla, vel congue augue. Duis quis quam sed purus porta eleifend. Vivamus ullamcorper est id libero aliquam ullamcorper. Donec eget dignissim augue. Donec ante felis, aliquam ut consequat eget, lobortis dapibus risus. Aliquam laoreet enim et lectus ornare hendrerit. Aliquam rhoncus enim libero. Morbi aliquam, nibh mattis feugiat dapibus, nisi massa adipiscing justo, sit amet condimentum urna ipsum et lacus. Nam fermentum, eros quis ullamcorper convallis, libero mauris lacinia eros, sed tempus leo lorem vitae purus. Nunc a malesuada felis. Cras ultrices sapien eu nisi elementum non blandit urna sodales. Duis accumsan cursus massa, eu facilisis diam porta ut..</p>.
Floated blocks
Below are samples of text in which part of it is displayed in a separate block
<p> Here goes main part of the text <span class="gkBlockTextLeft">Block of text</span>rest of the text</p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum condimentum pulvinar justo, sed faucibus ligula feugiat ac. Morbi quis enim nulla, vel congue augue. Duis quis quam sed purus porta eleifend.Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum condimentum pulvinar justo, sed faucibus ligula feugiat ac. Morbi quis enim nulla, vel congue augue.Donec eget dignissim augue. Donec ante felis, aliquam ut consequat eget, lobortis dapibus risus. Aliquam laoreet enim et lectus ornare hendrerit. Aliquam rhoncus enim libero. Morbi aliquam, nibh mattis feugiat dapibus, nisi massa adipiscing justo, sit amet condimentum urna ipsum et lacus. Nam fermentum, eros quis ullamcorper convallis, libero mauris lacinia eros, sed tempus leo lorem vitae purus. Nunc a malesuada felis. Cras ultrices sapien eu nisi elementum non blandit urna sodales. Duis accumsan cursus massa, eu facilisis diam porta ut. Morbi cursus est vel velit hendrerit dictum.
<p> Here goes main part of the text <span class="gkBlockTextRight">Block of text</span>rest of the text</p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum condimentum pulvinar justo, sed faucibus ligula feugiat ac. Morbi quis enim nulla, vel congue augue. Duis quis quam sed purus porta eleifend.Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum condimentum pulvinar justo, sed faucibus ligula feugiat ac. Morbi quis enim nulla, vel congue augue.Donec eget dignissim augue. Donec ante felis, aliquam ut consequat eget, lobortis dapibus risus. Aliquam laoreet enim et lectus ornare hendrerit. Aliquam rhoncus enim libero. Morbi aliquam, nibh mattis feugiat dapibus, nisi massa adipiscing justo, sit amet condimentum urna ipsum et lacus. Nam fermentum, eros quis ullamcorper convallis, libero mauris lacinia eros, sed tempus leo lorem vitae purus. Nunc a malesuada felis. Cras ultrices sapien eu nisi elementum non blandit urna sodales. Duis accumsan cursus massa, eu facilisis diam porta ut. Morbi cursus est vel velit hendrerit dictum.
<p> Here goes main part of the text <span class="gkBlockTextCenter">Block of text</span>rest of the text</p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum condimentum pulvinar justo, sed faucibus ligula feugiat ac. Morbi quis enim nulla, vel congue augue. Duis quis quam sed purus porta eleifend.Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum condimentum pulvinar justo, sed faucibus ligula feugiat ac. Morbi quis enim nulla, vel congue augue.Donec eget dignissim augue. Donec ante felis, aliquam ut consequat eget, lobortis dapibus risus. Aliquam laoreet enim et lectus ornare hendrerit. Aliquam rhoncus enim libero. Morbi aliquam, nibh mattis feugiat dapibus, nisi massa adipiscing justo, sit amet condimentum urna ipsum et lacus. Nam fermentum, eros quis ullamcorper convallis, libero mauris lacinia eros, sed tempus leo lorem vitae purus. Nunc a malesuada felis. Cras ultrices sapien eu nisi elementum non blandit urna sodales. Duis accumsan cursus massa, eu facilisis diam porta ut. Morbi cursus est vel velit hendrerit dictum.
Other span blocks
This is a sample pin note. Use <span class="gkClear">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. </span>
This is a sample pin note. Use <span class="gkClear-1">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. </span>
This is a sample pin note. Use <span class="gkClear-2">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. </span>
This is a sample pin note. Use <span class="gkColor">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. </span>
This is a sample pin note. Use <span class="gkColor-1">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. </span>
This is a sample pin note. Use <span class="gkColor-2">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. </span>
This is a sample pin note. Use <span class="gkColor-3">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. </span>
This is a sample pin note. Use <span class="gkColor-4">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. </span>
This is a sample pin note. Use <span class="gkColor-5">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. </span>
This is a sample pin note. Use <span class="gkColor-6">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. </span>
This is a sample pin note. Use <span class="gkColor-7">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer urna. Aenean tristique. Fusce a neque. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. </span>
Blockquotes
This is a sample quote text. Use < blockquote > Your quoted text goes here!< /blockquote >
This is a sample quote text. Use< blockquote><div class="gkBlockquote1"><div> Your quoted text goes here!< /div>< /div>< /blockquote >
This is a sample quote text. Use< blockquote><div class="gkBlockquote2"><div> Your quoted text goes here!< /div>< /div>< /blockquote >
This is a sample quote text. Use< blockquote><div class="gkBlockquote3"><div> Your quoted text goes here!< /div>< /div>< /blockquote >
This is a sample quote text. Use< blockquote><div class="gkBlockquote4"><div> Your quoted text goes here!< /div>< /div>< /blockquote >Tables
Table Header (thead) Table Footer (tfoot) Column 1 Column 2 Cell 3 - part of tbody Cell 4 - part of tbody Cell 5 - part of tbody Cell 6 - part of tbody Cell 7 - part of tbody Cell 8 - part of tbody
Table Header (thead) Table Footer (tfoot) Column 1 Column 2 Cell 1 - part of tbody Cell 2 - part of tbody Cell 3 - part of tbody Cell 4 - part of tbody Cell 5 - part of tbody Cell 6 - part of tbody
Template additional styles
In order to get the video you have to use code like this:
<a class="gk_video_frame" href="http://www.vimeo.com/16274294" rel="mediabox[720 410]">
<img src="/images/stories/demo/demo_video_1.png" border="0" alt="Video 1" />
<span class="gk_vframe">Frame</span>
<span class="gk_voverlay">Overlay</span>
Watch the video
</a>
As a href attribute you set the video address. In the rel attribute you can specify the video size. Image element is the thumbnail in the frame.
You can also create a blocks with icons. The structure is always similar - you have to change only second class near gk_block:
<div class="gk_block tablet">
<h3><a href="#">Mobile Ready</a></h3>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum</p>
</div>
Available blocks styles with classes:
android
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
blackberry
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
calendar
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
chat
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
clock
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
cog
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
firefox
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
info
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
mac
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
mobilephone
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
phone
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
recycledbag
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
shoppingcart
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
tablet
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
user
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras quis erat elit. Donec pretium condimentum
In this article Barry Mavin, CEO and Chief Software Architect for Recital, details how to use the Client Drivers provided with the Recital Database Server to work with local or remote server-side OLE DB data sources.
Overview
The Recital Universal .NET Data Provider provides connectivity to the Recital Database Server running on any supported platform (Windows, Linux, Unix, OpenVMS) using the RecitalConnection object.
The Recital Universal JDBC Driver provides the same functionality for java applications.
The Recital Universal ODBC Driver provides the same functionality for applications that use ODBC.
Each of the above Client Drivers use a connection string to describe connections parameters.
The basic format of a connection string consists of a series of keyword/value pairs separated by semicolons. The equal sign (=) connects each keyword and its value.
The following table lists the valid names for keyword/values.
| Name | Default | Description |
|---|---|---|
|
Data Source
|
The name or network address of the instance of the Recital Database Server which to connect to. | |
| Directory | The target directory on the remote server where data to be accessed resides. This is ignored when a Database is specified. | |
|
Encrypt |
false | When true, DES3 encryption is used for all data sent between the client and server. |
| Initial Catalog -or- Database |
The name of the database on the remote server. | |
| Password -or- Pwd |
The password used to authenticate access to the remote server. | |
| User ID | The user name used to authenticate access to the remote server. | |
|
Connection Pooling |
false | Enable connection pooling to the server. This provides for one connection to be shared. |
| Logging | false | Provides for the ability to log all server requests for debugging purposes |
| Rowid | true | When Rowid is true (the default) a column will be post-fixed to each SELECT query that is a unique row identifier. This is used to provide optimised UPDATE and DELETE operations. If you use the RecitalSqlGrid, RecitalSqlForm, or RecitalSqlGridForm components then this column is not visible but is used to handle updates to the underlying data source. |
| Logfile | The name of the logfile for logging | |
| Gateway |
Opens an SQL gateway(Connection) to a foreign SQL data source on the remote server. Using Gateways, you can transparently access the following local or remote data sources:
The gateway can be specified in several formats: servertype@nodename:username/password-database e.g. oracle@nodename:username/password-database mysql@nodename:username/password-database postgresql@nodename:username/password-database -or- odbc:odbc_data_source_name_on_server oledb:oledb_connection_string_on_server jdbc:jdbc_driver_path_on_server;jdbc:Recital:args |
To connect to a server-side OLE DB data source, you use the gateway=value key/value pair in the following way.
gateway=oledb:oledb_connection_string_on_server
ImportantWhen specifying the connection string be sure to quote the gateway= with "...".
You can find examples of connection strings for most ODBC and OLE DB data sources by clicking here.
Example in C# using the Recital Universal .NET Data Provider:
////////////////////////////////////////////////////////////////////////
// include the references below
using System.Data;
using Recital.Data;
////////////////////////////////////////////////////////////////////////
// The following code example creates an instance of a DataAdapter that
// uses a Connection to the Recital Database Server, and a gateway to
// the SQL server Northwind database. It then populates a DataTable
// in a DataSet with the list of customers. The SQL statement and
// Connection arguments passed to the DataAdapter constructor are used
// to create the SelectCommand property of the DataAdapter.
public DataSet SelectCustomers()
{
string gateway = "oledb:Provider=sqloledb;Initial Catalog=Northwind;
Data Source=localhost;Integrated Security=SSPI";
RecitalConnection swindConn = new
RecitalConnection("Data Source=localhost;gateway=\""+gateway+"\");
RecitalCommand selectCMD = new
RecitalCommand("SELECT CustomerID, CompanyName FROM Customers", swindConn);
selectCMD.CommandTimeout = 30;
RecitalDataAdapter custDA = new RecitalDataAdapter();
custDA.SelectCommand = selectCMD;
swindConn.Open();
DataSet custDS = new DataSet();
custDA.Fill(custDS, "Customers");
swindConn.Close();
return custDS;
}
Example in Java using the Recital Universal JDBC Driver:
////////////////////////////////////////////////////////////////////////
// standard imports required by the JDBC driver
import java.sql.*;
import java.io.*;
import java.net.URL;
import java.math.BigDecimal;
import Recital.sql.*;
////////////////////////////////////////////////////////////////////////
// The following code example creates a Connection to the Recital
// Database Server, and a gateway to the SQL server Northwind database.
// It then retrieves all the customers.
public void SelectCustomers()
{
// setup the Connection URL for JDBC
String gateway = "oledb:Provider=sqloledb;Initial Catalog=Northwind;
Data Source=localhost;Integrated Security=SSPI";
String url = "jdbc:Recital:Data Source=localhost;gateway=\""+gateway+"\";
// load the Recital Universal JDBC Driver
new RecitalDriver();
// create the connection
Connection con = DriverManager.getConnection(url);
// create the statement
Statement stmt = con.createStatement();
// perform the SQL query
ResultSet rs = stmt.executeQuery("SELECT CustomerID, CompanyName FROM Customers");
// fetch the data
while (rs.next())
{
String CompanyID = rs.getString("CustomerID");
String CompanyName = rs.getString("CompanyName");
// do something with the data...
}
// Release the statement
stmt.close();
// Disconnect from the server
con.close();
}