On Mon, Sep 09, 2002 at 12:01:57PM +0200, Lars Martinsen wrote:
> Does anyone have a step-by-step on how to connect to a MS SQL Server and do
> SQL commands on it? I have tried to do it by reading all the help and
> how-tos that is bundeled with Cocoon, but I didn't manage.
For my development I'm using two drviers: Izmado (an ADO wrapper from
www.infozoom.de - quite slow for larger queries) and InetOpta
(www.inetsoftware.de)

to install the mssql server datasource:
1. download one of the drivers and put them into cocoon's web-xml/lib directory 
( for izmado you also have to copy a .dll file from driver zip file in to 
%WINDIR%/system32

2. in cocoon's web.xml file preload appropriate driver class:
 <init-param>
      <param-name>load-class</param-name>
      <param-value>
        <!-- For IBM WebSphere:
        com.ibm.servlet.classloader.Handler -->

        <!-- For Database Driver: -->
        org.hsqldb.jdbcDriver
                com.inzoom.jdbcado.Driver
                com.inet.tds.TdsDriver
        <!-- For parent ComponentManager sample:
        org.apache.cocoon.samples.parentcm.Configurator
        -->
      </param-value>
    </init-param>

3. Add a datasource:
3a. for izmado it is:
        <jdbc name="cdn-izmado" logger="core.datasources.cdn-izmado">
                <pool-controoller min="1" max="10"/>
                <auto-commit>false</auto-commit>
                <dburl>jdbc:izmado:Provider=MSDASQL;Driver={Sql 
Server};Server=OUZO\CDN_OPTIMA;Database=CDN_Full;USER ID=SA;</dburl>
                <user>sa</user>
                <password></password>
        </jdbc>
3b. for opta it is:
        <jdbc name="cdn" logger="core.datasources.cdn-opta">
                <pool-controoller min="1" max="10"/>
                <auto-commit>false</auto-commit>
                
<dburl>jdbc:inetdae7:localhost:1134?database=CDN_Full&amp;charset=Cp1250</dburl>
                <user>sa</user>
                <password></password>
        </jdbc>

tweak dburl for your needs and it will surely work 

I advice to use Inet Opta, but you'll have to pay ( 50 redistributable driver
licenses cost 3200$)

you can get trial versions of both drivers (with time and connection limit)
        ouzo
-- 
            __
         | /  \ |        Leszek Gawron            //  \\
        \_\\  //_/      [EMAIL PROTECTED]          _\\()//_
         .'/()\'.     Phone: +48(600)341118     / //  \\ \
          \\  //  recursive: adj; see recursive  | \__/ |


---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <[EMAIL PROTECTED]>
For additional commands, e-mail:   <[EMAIL PROTECTED]>

Reply via email to