2010-04-16 Sebastien Pouliot <sebastien@ximian.com>
[mono/afaerber.git] / web / firebird
blob6d3bc0b33f32c63411cae8580a7aa00349afd31f
1 * Firebird and Interbase Data Provider
3 <ul>
4         <li>ADO.NET Data Provider for Firebird and Interbase databases</li>
6         <li>Does not exist in Mono, but is a separate project</li>
7         
8         <li>The <a href="http://firebird.sourceforge.net/index.php">Firebird Relational Database</a> is 
9         is an independent project which uses source code based on the Interbase source code released
10         by Borland under the Interbase Public License</li>
11         
12         <li>Both the Firebird Relational Database and the Firebird .NET Data Provider can be
13         downloaded from <a href="http://sourceforge.net/projects/firebird/">here</a></li>
14         
15         <li>The Firebird .NET Data provider has been made
16     available by Carlos Guzmán Álvarez (aka "Carlos G.A."), who has also made a
17     number of contributions to the OdbcJdbc code</li>
19         <li>Bugs with Mono or the data provider should be reported 
20         in Mono's Bugzilla <a href="http://bugzilla.ximian.com/">here</a>.  If you
21         do not have Bugzilla user account, it is free 
22         and easy to create one <a href="http://bugzilla.ximian.com/createaccount.cgi">here</a>.</li>
23         
24 </ul>
26 ** Current Status
28 <ul>  
29         <li>Current stable version: 1.5.1</li>
30         
31         <li>Current developement version: 1.6</li>
32         
33         <li>The new data provider/driver is written in C# and provides a high-performance native
34         implementation of the GDS32/API functions. This means that .Net developers
35         will be able to access Firebird databases without the need of Firebird
36         client install</li>
38     <li>In support of the new module, a new mailing list
39         <a href="http://lists.sourceforge.net/lists/listinfo/firebird-net-provider">firebird-net-provider</a> has 
40         been created. Please use this list for any 
41         questions that you may have about the provider</li>           
42 </ul>   
44 ** New features & enhancements in 1.6 version
46 <ul>
47         <li>Firebird Embedded Server support.</li>
48         <li>New FbScript class implementation.</li>
49         <li>Improved connection pooling.</li>
50         <li>Improved array datatype support.</li>
51 </ul>
52    
53 ** Testing
55 <ul>
56         
57         <li>Need a working mono and mcs</li>
58         
59         <li>Need access to a Firebird Relational Database or you can download
60         it from <a href="http://firebird.sourceforge.net">here</a></li>
61         
62         <li>Get the Firebird .NET data provider from here as 
63         <a href="http://lists.sourceforge.net/lists/listinfo/firebird-net-provider">firebird-net-provider</a>.  Make
64         sure the Firebird .NET data provider binary assembly FirebirdSql.Data.Firebird.dll is
65         installed in the same place as the mono class libraries.</li>
66         
67         <li>Has a ConnectionString format:
68 <pre>
69  "Database=databasefile.gdb;User=user;Password=pass;Dialect=3;Server=hostname"
70 </pre>
71         
72         </li>
73         
74         <li>C# Example:
75         
76 <pre>
77  using System;
78  using System.Data;
79  using FirebirdSql.Data.Firebird;
81  public class Test 
82  {
83     public static void Main(string[] args)
84     {
85         string connectionString = 
86                "Database=C:\\PROGRAM FILES\\FIREBIRD\\EXAMPLES\\EMPLOYEE.GDB;" +
87                "User=SYSDBA;" +
88                "Password=masterkey;" +
89                "Dialect=3;" +
90                "Server=localhost";
91                
92        IDbConnection dbcon = new FbConnection(connectionString);
93        dbcon.Open();
94        IDbCommand dbcmd = dbcon.CreateCommand();
95        string sql = "SELECT * FROM employee";
96        dbcmd.CommandText = sql;
97        IDataReader reader = dbcmd.ExecuteReader();
98        while(reader.Read()) {
99             object dataValue = reader.GetValue(0);
100             string sValue = dataValue.ToString();
101             Console.WriteLine("Value: " + sValue);
102        }
103        // clean up
104        reader.Close();
105        reader = null;
106        dbcmd.Dispose();
107        dbcmd = null;
108        dbcon.Close();
109        dbcon = null;
110     }
112 </pre>
113         </li>
114         <li>Building C# Example:
115         <ul>
116                 <li>Save the example to a file, such as, TestExample.cs</li>
117                 <li>Build on Linux:
118 <pre>
119         mcs TestExample.cs -r System.Data.dll \
120             -r FirebirdSql.Data.Firebird.dll
121 </pre>
122                 </li>
123                 <li>Build on Windows via Cygwin:
124 <pre>
125         mono C:/cygwin/home/MyHome/mono/install/bin/mcs.exe \
126              TestExample.cs \
127              -lib:C:/cygwin/home/MyHome/mono/install/lib \
128              -r System.Data.dll -r FirebirdSql.Data.Firebird.dll
129 </pre>
130                 </li>
131         </ul>
132         </li>
133         <li>Running the Example:
134 <pre>
135 mono TestExample.exe
136 </pre>
137 </li>
139 </ul>