salut a vous. depuis deux jours , j'essaie de me connecter a un cube sur sql server 2008 via le Script ci-dessous :

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
 
 
 
 
/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.sobi.test;
 
import com.sobi.Exception.SobiConfigurationException;
import com.sobi.database.SobiFactory;
import java.io.IOException;
import java.io.InputStream;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
import java.util.Properties;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.olap4j.OlapConnection;
import org.olap4j.OlapWrapper;
 
/**
 *
 * @author Bezalel
 */
public class Test {
 private static final String FICHIER_PROPERTIES = "com/sobi/dao/Sobi.properties";
    private static final String PROPERTY_URL = "url";
    private static final String PROPERTY_DRIVER = "driver";
    private static final String PROPERTY_NOM_UTILISATEUR = "nomutilisateur";
    private static final String PROPERTY_MOT_DE_PASSE = "motdepasse";
    private String url;
    private String username;
    private String password;
    /**
     * @param args the command line arguments
     * @throws java.sql.SQLException
     */
    public static void main(String[] args) throws SQLException {
      getInstance() ;
    }
 
 
  public static void getInstance() throws SobiConfigurationException {
        Properties properties = new Properties();
        String url;
        String driver;
        String nomUtilisateur;
        String motDePasse;
        ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
        InputStream fichierProperties = classLoader.getResourceAsStream(FICHIER_PROPERTIES);
        if (fichierProperties == null) {
            throw new SobiConfigurationException("Le fichier properties " + FICHIER_PROPERTIES + " est introuvable.");
        }
        try {
            System.out.println("LOAD FILE");
            properties.load(fichierProperties);
            System.out.println("LOAD FILE OK");
            url = properties.getProperty(PROPERTY_URL);
            driver = properties.getProperty(PROPERTY_DRIVER);
            nomUtilisateur = properties.getProperty(PROPERTY_NOM_UTILISATEUR);
            motDePasse = properties.getProperty(PROPERTY_MOT_DE_PASSE);
 
            System.out.println(url);
            System.out.println(driver);
            System.out.println(nomUtilisateur);
            System.out.println(motDePasse);
        } catch (IOException e) {
            throw new SobiConfigurationException("Impossible de charger le fichier properties " + FICHIER_PROPERTIES, e);
        }
        try {
            Class.forName(driver);
            System.out.println("SUCCESS LOAD DRIVER");
        } catch (ClassNotFoundException e) {
            throw new SobiConfigurationException("Le driver est introuvable dans le classpath.", e);
        }
 
    }   
 
 
 
 
 
      }

mais a chaque fois j'ai l'erreur ci-dessous

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
 
 
run:
LOAD FILE
LOAD FILE OK
"jdbc:xmla:Server=http://WINSERVER/xmla/msxisapi.dll"
"org.jdbc4olap.jdbc.OlapDriver"
sa
bezalel
Exception in thread "main" com.sobi.Exception.SobiConfigurationException: Le driver est introuvable dans le classpath.
	at com.sobi.test.Test.getInstance(Test.java:74)
	at com.sobi.test.Test.main(Test.java:39)
Caused by: java.lang.ClassNotFoundException: "org.jdbc4olap.jdbc.OlapDriver"
	at java.net.URLClassLoader$1.run(URLClassLoader.java:372)	at java.net.URLClassLoader$1.run(URLClassLoader.java:372)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:360)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
	at java.lang.Class.forName0(Native Method)
	at java.lang.Class.forName(Class.java:260)
	at com.sobi.test.Test.getInstance(Test.java:71)
	... 1 more
Java Result: 1
BUILD SUCCESSFUL (total time: 2 seconds)

Que faire pour remédier a la situation ?