Results 1 to 5 of 5

Thread: Teradata Data access through Datasource

  1. #1

    Default Teradata Data access through Datasource

    Hi,

    I am getting an error while connecting to Teradata database from a Spring based application that I am working on. I use JDBCTemplate class to set the datasource using one of the Spring's datasource configuration files.
    The error is 'Single Sign-On NOT supported for Mechanism TD2'.

    I have created a datasource and jndi name in the EAR file application descriptor under user-defined datasource category. I have also given the userid/password under JAAS authentication list. I am using websphere server.
    ------
    Detail error message -
    Caused by: org.springframework.jdbc.CannotGetJdbcConnectionEx ception: Could not get JDBC Connection; nested exception is java.sql.SQLException: [NCR] [Teradata JDBC Driver] : Single Sign-On NOT supported for Mechanism TD2.DSRA0010E: SQL State = HY000, Error Code = 1,032
    at org.springframework.jdbc.datasource.DataSourceUtil s.getConnection(DataSourceUtils.java:82)
    at org.springframework.jdbc.core.JdbcTemplate.execute (JdbcTemplate.java:327)
    at org.springframework.jdbc.core.JdbcTemplate.update( JdbcTemplate.java:467)
    at com.hcsc.tpa.integration.daoimpl.jdbc.UserAccountD aoJdbcImpl.changePassword(UserAccountDaoJdbcImpl.j ava:35)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Nativ e Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Native MethodAccessorImpl.java(Compiled Code))
    at sun.reflect.NativeMethodAccessorImpl.invoke(Native MethodAccessorImpl.java(Compiled Code))
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(De legatingMethodAccessorImpl.java(Compiled Code))
    at java.lang.reflect.Method.invoke(Method.java(Compil ed Code))
    .....

    Appreciate your help!

    Thanks,
    Suresh

  2. #2
    Join Date
    Feb 2005
    Location
    Boston, MA
    Posts
    1,142

    Default

    Do you have more information from the Teradata documentation about that error? It looks more like a teradata issue than a Spring issue.

    Do you have a simple non-Spring example that works with Teradata? That might shed some light about what you need to do different with Spring.
    Bill

  3. #3

    Default

    I am able to connect to teradata using DriverManagerDataSource class as
    mentioned in the code below. This I tried in one of the DAO classes which extends JdbcTemplate class.

    ---
    DriverManagerDataSource ds = new DriverManagerDataSource();
    ds.setDriverClassName("com.ncr.teradata.TeraDriver ");
    ds.setUrl("jdbc:teradata://EDWP/DATABASE=DBC");
    ds.setUsername("******");
    ds.setPassword("*****");
    setDataSource(ds); // Overridden this method of JdbcTemplate class to set the Datasource...
    ----

    But when tried to access from the datasource which is configured in the ear file in websphere, it doesn't work. Not sure if this is really a spring issue or am making some mistake in the datasource configuration in the application descriptor file. But I mentioned username/password in JAAS authentication list. But still not working

    Need help!

    Thanks,
    Suresh

  4. #4
    Join Date
    Feb 2005
    Location
    Boston, MA
    Posts
    1,142

    Default

    Sounds like a datasource configuration issue in the application server, since JdbcTemplate works fine with a DriverManagerDataSource.
    Bill

  5. #5
    Join Date
    May 2011
    Posts
    9

    Default

    hi could you let me know what is the data source class name that you have mentioned in the application context.xml to establish the connection

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •