Connecting through Data Source using JNDI

I would like to connect my application to sql server database through data
source using JNDI. But when i try to bind the data source object with the
logical name, i am getting following exception. How can i ger rid of this
error ? How can i provide the initial context ? I thought Java would create the default initial context by itself. But it doesn't seem to be true. Any type of help would be appreciated.
-Prashant
Exception :
Naming Exception :Need to specify class name in environment or system
property, or as an applet parameter, or in an application resource file:
java.naming.factory.initial
javax.naming.NoInitialContextException: Need to specify class name in
environment or system property, or as an applet parameter, or in an
application resource file: java.naming.factory.initial
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:651)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:246)
at
javax.naming.InitialContext.getURLOrDefaultInitCtx(InitialContext.java:283)
at javax.naming.InitialContext.bind(InitialContext.java:358)
at RegDataSource.regDataSource(RegDataSource.java:30)
at RegDataSource.main(RegDataSource.java:52)
Source code :
public class RegDataSource
public RegDataSource()
private void regDataSource()
try
com.microsoft.jdbcx.sqlserver.SQLServerDataSource sds =
new
com.microsoft.jdbcx.sqlserver.SQLServerDataSource();
sds.setServerName("servername13");
sds.setDatabaseName("test");
Context ctx = new InitialContext();
ctx.bind("jdbc/EmployeeDB", sds);
catch(NamingException e)
System.out.println("Naming Exception :" + e.getMessage()
//+ "\n" + e.getExplanation()
//+ "\n" + e.getResolvedObj()
//+ "\n" + e.getResolvedName()
e.printStackTrace();
catch(Exception e)
System.out.println("Exception :" + e.getMessage());
public static void main(String[] args)
RegDataSource regDataSource1 = new RegDataSource();
regDataSource1.regDataSource();

Thanks you very very much for your prompt reply and helping me out. I have following questions.
1) Now i am able to bind data source object to the logical name. But the problem is that whenever i try to look up the data source object by providing logical name (i.e. DataSource ds = (DataSource)ctx.lookup("jdbc/EmployeeDB") ), it returns always null. I don't know why it doesn't return the correct data source object ?
Following is the code used to bind datasource with the logical name
Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY,
"com.sun.jndi.fscontext.RefFSContextFactory");
env.put(Context.PROVIDER_URL, "file:/TEMP/jndi");
Context ctx = new InitialContext(env);
//Properties p = new Properties();
//p.put(Context.INITIAL_CONTEXT_FACTORY,
// "com.sun.jndi.fscontext.RefFSContextFactory");
//Context ctx = new InitialContext(p);
ctx.bind("jdbc/EmployeeDB", sds);
Following is the code used to look up for the bound object
Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY,
"com.sun.jndi.fscontext.RefFSContextFactory");
env.put(Context.PROVIDER_URL, "file:/TEMP/jndi");
Context ctx = new InitialContext(env);
DataSource ds = (DataSource)ctx.lookup("jdbc/EmployeeDB");
2) I am writing client server application in which my client is going to access the SQL Server 2000 to read/write database related data. The reason behind using the JNDI is that i don't want my client application to kwon which driver (sql) and database i am using. It is going to provide the great flexibility whenever i can make my application to use other database like Oracel, sybase, etc. without changing any code most probably. In this situation, which JNDI service provider to use ? I am not sure about "File System" service provider be the ideal choice for this type of situation. so please let me know which JNDI service provider is the ideal for this situation.
Any type of help would be appreacited.

Similar Messages

  • How to connect to weblogic data source using jndi name?

    I am trying to connect to database using data source look up from weblogic as below:
    factory = "weblogic.jndi.WLInitialContextFactory"
    conn = zxJDBC.lookup('ApplicationDB',INITIAL_CONTEXT_FACTORY=factory)
    this is throwing DatabaseError:
    however i can connect to the db using uname, pwd and url. its working fine using zxJDBC in jython.
    any clue why the first one is failing?

    import java.sql.*;
    import javax.sql.*;
    import javax.naming.*;
    import java.util.*;
    public class MyDataSourceLookupClient
         public final static String JNDI_FACTORY = "weblogic.jndi.WLInitialContextFactory";
         private static String serverUrl ="t3://localhost:7001";
    public static void main(String ar[])throws Exception
    InitialContext ic=null;
    try{
              Hashtable env = new Hashtable();
              env.put(Context.INITIAL_CONTEXT_FACTORY, JNDI_FACTORY);
              env.put(Context.PROVIDER_URL, serverUrl);
              ic = new InitialContext(env);
    catch(Exception e){}
    try{
    DataSource ds=ic.lookup("YourDataSourceJNDIName");
    Connection con=ds.getConnection();
    System.out.println("\n\t Got Connection: "+con);
    con.close();
    catch(Exception e)
    System.out.println("\n\n\t jack Exception => "+e);
    e.printStackTrace();
    Thanks
    Jay SenSharma
    http://jaysensharma.wordpress.com (WebLogic Wonders Are Here)

  • Spring fails to lookup Data Source using JNDI

    Hi all I am now for configure jndi in tomcat5.5 .. my integration is like spring+hybernate+jpa
    I am getting the error is
    ERROR - ContextLoader.initWebApplicationContext(219) | Context initialization failed
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in ServletContext resource [WEB-INF/xaconfig/daoJPAConfig.xml]: Invocation of init method failed; nested exception is javax.naming.NamingException: Cannot create resource instance
         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1412)
         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
         at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:291)
         at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
         at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:288)
         at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:190)
         at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:546)
         at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:871)
         at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:423)
         at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:272)
         Caused by: javax.naming.NamingException: Cannot create resource instance
    my tomcat 5.5/context.xml is
    <?xml version="1.0" encoding="UTF-8"?>
    <!-- The contents of this file will be loaded for each web application --><Context>
    <!-- Default set of monitored resources -->
    <WatchedResource>WEB-INF/web.xml</WatchedResource>
         <Transaction factory="com.atomikos.icatch.jta.UserTransactionFactory"/>
    <!-- Uncomment this to disable session persistence across Tomcat restarts -->
    <!--
    <Manager pathname="" />
    -->
    <ResourceLink global="jdbc/Paymentsdb" name="jdbc/Paymentsdb" type="com.atomikos.jdbc.AtomikosDataSourceBean"/>
    </Context>
    and my tomcat5.5/server.xml is
    <?xml version="1.0" encoding="UTF-8"?>
    <Server port="8005" shutdown="SHUTDOWN">
    <Listener className="org.apache.catalina.mbeans.ServerLifecycleListener"/>
    <Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener"/>
    <Listener className="org.apache.catalina.storeconfig.StoreConfigLifecycleListener"/>
    <Listener className="com.atomikos.tomcat.AtomikosLifecycleListener"/>
    <GlobalNamingResources>
    <Environment name="simpleValue" type="java.lang.Integer" value="30"/>
    <Resource auth="Container" description="User database that can be updated and saved" factory="org.apache.catalina.users.MemoryUserDatabaseFactory" name="UserDatabase" pathname="conf/tomcat-users.xml" type="org.apache.catalina.UserDatabase"/>
    </GlobalNamingResources>
    <Service name="Catalina">
    <Connector acceptCount="100" connectionTimeout="20000" disableUploadTimeout="true" enableLookups="false" maxHttpHeaderSize="8192" maxSpareThreads="75" maxThreads="150" minSpareThreads="25" port="8080" redirectPort="8443"/>
    <Connector enableLookups="false" port="8009" protocol="AJP/1.3" redirectPort="8443"/>
    <Engine defaultHost="localhost" name="Catalina">
         <Realm className="org.apache.catalina.realm.UserDatabaseRealm" resourceName="UserDatabase"/>
         <Host appBase="webapps" autoDeploy="true" name="localhost" unpackWARs="true" xmlNamespaceAware="false" xmlValidation="false">
    <Context docBase="com.evolvus.payments.web" path="/com.evolvus.payments.web" reloadable="true" source="org.eclipse.jst.j2ee.server:com.evolvus.payments.web">
    <Resource name="jdbc/Paymentsdb" auth="Container"
    type="com.atomikos.jdbc.AtomikosDataSourceBean"
    driverClassName="com.mysql.jdbc.jdbc2.optional.MysqlXADataSource"
    url="jdbc\:mysql\://devserver\:3306/payhub"
    username="root"
    password="root"
    maxActive="20"
    maxIdle="10"
    maxWait="20000"
    />
    </Context></Host>
    </Engine>
    </Service>
    </Server>
    and my web.xml is
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app version="2.5"
         xmlns="http://java.sun.com/xml/ns/javaee"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
         <display-name>Payments</display-name>
         <context-param>
              <param-name>contextConfigLocation</param-name>
              <param-value>/WEB-INF/xaconfig/daoJPAConfig.xml</param-value>
         </context-param>
         <context-param>
         <param-name>javax.faces.CONFIG_FILES</param-name>
         <param-value>/WEB-INF/faces-config.xml</param-value>
         </context-param>
         <filter>
              <filter-name>PrimeFaces FileUpload Filter</filter-name>
              <filter-class>org.primefaces.webapp.filter.FileUploadFilter</filter-class>
         </filter>
         <filter-mapping>
              <filter-name>PrimeFaces FileUpload Filter</filter-name>
              <servlet-name>Faces Servlet</servlet-name>
         </filter-mapping>
         <context-param>
    <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
    <param-value>.xhtml</param-value>
    </context-param>
         <servlet>
              <servlet-name>Faces Servlet</servlet-name>
              <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
              <load-on-startup>1</load-on-startup>
         </servlet>
         <servlet-mapping>
              <servlet-name>Faces Servlet</servlet-name>
              <url-pattern>*.jsf</url-pattern>
         </servlet-mapping>
    <resource-ref>
    <description>PaymentsDatabase</description>
    <res-ref-name>jdbc/Paymentsdb</res-ref-name>
    <res-type>com.atomikos.jdbc.AtomikosDataSourceBean</res-type>
    <res-auth>Container</res-auth>
    </resource-ref>
    </web-app>
    and my daoJpaConfig i did like this
    <beans:bean id="dataSource"
              class="org.springframework.jndi.JndiObjectFactoryBean">
              <beans:property name="jndiName">
                   <beans:value>java:comp/env/jdbc/Paymentsdb</beans:value>
              </beans:property>
              </beans:bean>
                        what are the jar file i have to add in my tomcat 5.5 and webapplication ??
    plz help me i am struggling alot ..where i did mistakes      
    i am using transaction type as transaction-type="JTA" <persistence-unit name="payhub" transaction-type="JTA">

    import java.sql.*;
    import javax.sql.*;
    import javax.naming.*;
    import java.util.*;
    public class MyDataSourceLookupClient
         public final static String JNDI_FACTORY = "weblogic.jndi.WLInitialContextFactory";
         private static String serverUrl ="t3://localhost:7001";
    public static void main(String ar[])throws Exception
    InitialContext ic=null;
    try{
              Hashtable env = new Hashtable();
              env.put(Context.INITIAL_CONTEXT_FACTORY, JNDI_FACTORY);
              env.put(Context.PROVIDER_URL, serverUrl);
              ic = new InitialContext(env);
    catch(Exception e){}
    try{
    DataSource ds=ic.lookup("YourDataSourceJNDIName");
    Connection con=ds.getConnection();
    System.out.println("\n\t Got Connection: "+con);
    con.close();
    catch(Exception e)
    System.out.println("\n\n\t jack Exception => "+e);
    e.printStackTrace();
    Thanks
    Jay SenSharma
    http://jaysensharma.wordpress.com (WebLogic Wonders Are Here)

  • Error / fails to connect Oracle data source using deploy tool

    Hi,
    I want to deploy SAP AS on my company's J2EE application. I deployed the application using Deploy Tool successfully. The application is started without error.
    When I tried connecting the log on page.  I got error in LogViewer:
    Error while accessing porting layer for ORACLE database via getDatabaseHost().
    Relatives : com.sap.sql.jdbc.direct.DirectConnectionFactory
    Resource Bundlename : com.sap.sql.log.OpenSQLResourceBundle
    Source : /System/Database/sql/jdbc/direct
    Argument Objs : ORACLE,getDatabaseHost(),
    Where to look for debugging errors?
    -- Joe

    Hi Markus,
    I changed to Vendor SQL and set Initial Connection to 1.
    On Monitor tab, I see a green line running across the screen. 
    I believe this proves that the connection has been established.
    Thanks a lot!
    -- Joe

  • Connecting to Oracle Data Source using SSIS

    Hi Guys,
    Please I am working on a BI Project that requires me to connect to an oracle data source using SSIS.
    Can someone assist me with the required steps to achieve that. 
    I dont want to use a third party tool.
    Thanks
    me

    Hi lilutchay,
    If the SQL Server Integration Services is Enterprise or Developer edition of SQL Server 2008, we can use
    Microsoft Connector Version 1.2 for Oracle to connect Oracle databases with version Oracle 9.2.0.4 or higher, Oracle 10.x or Oracle 11.x. If the SQL Server Integration Services is Enterprise or Developer edition of SQL Server 2012, we can use
    Microsoft Connector Version 2.0 for Oracle to connect Oracle databases with version Oracle 9.2.0.4 or higher, Oracle 10.x or Oracle 11.x.
    While if we want to connect to other Oracle version databases, we can use
    OLE DB provider for Oracle which has been tested in SSIS labs and is recommended by Microsoft.
    For the detail steps for Microsoft Connector for Oracle, we can refer to the first blog suggested by Deric. For more details about the use of connecting to oracle using Oracle Provider for OLEDB from SSIS, please refer to the blog below:
    http://www.databasefun.com/archives/591
    Reference:
    SSIS with Oracle Connectors
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • Cannot create data source using custom third-party driver

    Hi,
    I've just installed Weblogic Server 10.3.6 and I'm getting problems creating a generic data source using my own third party jdbc driver which I had no problems doing in Weblogic Server 10.0; this is what I did in 10.0;
    before starting server i put my driver jar file (and any jar files it needed) in the lib folder of the domain user project which weblogic appends to the classpath during server startup
    inside weblogic console -
    1. first page - provided a data source name and jndi name and selected 'other' for database type
    2. second page - selected 'other' for jdbc driver
    3. third page - deselected the global transactions
    4. fourth page - provided database name, username, host name, port, and password.
    5. fifth page - provided driver class, url, database user name and password (didn't bother with the test)
    6. Selected target server
    I then saved and activated changed and was done.
    This what I did for 10.3.6
    did the same thing I did for 10.0 before server start up
    inside weblogic console -
    1. first page - provided data source name and jndi name and selected 'other' for database type
    2. second page - selected 'other' for jdbc driver
    3. third page - deselected the support global transactions
    4. fourth page - here's where things are different - page only asked for database username and password, which I give.
    One this page I get a criptic error saying 'errors must be corrected before proceeding' - no other message as to what these errors might be either in the console or the cmd window of the server. I tried making changes to the provider authenticiation of the security realm but no luck. I tried following password creation requirements, I even tried proceeding to the next page without entering anything on this page, all no luck. I have no idea what's going on.
    Hope someone can help.
    Sam.

    I've fixed the class issue but am struggling a bit with SQL Server authentication. I'm running in mixed mode (originally set to Windows authentication but I've modified the security setting), I've enabled TCP/IP and Named Pipes, I've created a user (who I can log in to SQL Server Mgmt Studio successfully with), but still get a connection refused error.
    Any insight? Thanks.

  • Progress Reporter - Failed to connect to data source

    Installed Progress Reporter and successfully call up the configuration page (http://WLS_server_name:7001/pr/admin/configuration) fill out the Database URL with the URL I use in SQL Developer (jdbc:oracle:thin:@db_Server_Name:1521:primavera) Public Group ID: 1 username: pubuser and password: pubuser. I put nothing in the Application Server section. When I click on save I get the message "Failed to connect to data source, please verify your settings and try again." I know the URL is correct as it connects using SLQ Developer. I have also created a datasource and pool using the same parameters just to validate the connection URL in different products.
    Now I do get errors when starting up WebLogic
    1) java.io.FileNotFoundException: C:\prhome\primavera-configuration.properties ...
    2) Local Exception Stack: Exception [EclipseLink-7042] (Eclipse Persistence Services - 1.1.0.r3639-SNAPSHOT): org.eclipse.persistence.exceptions.ValidationException Exception Description: Database platform class [${databasePlatform}] not found...
    3) Exception in thread "timerFactory" org.springframework.transaction.CannotCreateTransactionException: Could not open JPA EntityManager for transaction; ...
    4) A number of these: Exception Description: Database platform class [${databasePlatform}] not found....
    I am running on Windows 2008-r2 using WebLogic (64bit) and Java 1.6.0_27 (64bit); Progress Reporter installed in its own domain on a standalone (not managed) weblogic server
    I've checked the configuration steps in the documentation (especially for the setDomainEnv.cmd and the PRE_CLASSPATH settings)
    Any suggestions appreciated.
    Are any of the errors (1 through 4) causing the issue of being unable to connect to the data source?

    I have tried both privuser and pubuser. Both username/password combinations work when using sql-developer but not through the database section on the P6 Progress Reporter configuration web page.
    I don't login as admin. When I enter the URL http://WLS_server_name:7001/pr/admin it comes up with the configuration screen that has the database and application server configuration sections.
    The file primavera-configuration.properties is not created. If I create a blank file that removes the "java.io.FileNotFoundException: C:\prhome\primavera-configuration.properties ..." message but it doesn't get any content.
    Thanks,
    Greg

  • Power View error: Cannot create a connection to data source 'EntityDataSource'

    I have Power View on SharePoint 2013. I have both Multidimentional and Tabular model in use.
    I have several Report.drlx file in Report libary in SharePoint.
    My colleague is getting following error when building report by dragging Facts and Dimentions to report.
    On the hand, I'm not receiving error.
    Error is cannot create a connection to data source 'EntityDataSource'
    <detail><ErrorCode xmlns="rsErrorOpeningConnection</ErrorCode><HttpStatus">http://www.microsoft.com/sql/reportingservices">rsErrorOpeningConnection</ErrorCode><HttpStatus
    xmlns="400</HttpStatus><Message">http://www.microsoft.com/sql/reportingservices">400</HttpStatus><Message xmlns="Cannot">http://www.microsoft.com/sql/reportingservices">Cannot
    create a connection to data source 'EntityDataSource'.</Message><HelpLink xmlns="http://go.microsoft.com/fwlink/?LinkId=20476&EvtSrc=Microsoft.ReportingServices.Diagnostics.Utilities.ErrorStrings&EvtID=rsErrorOpeningConnection&ProdName=Microsoft%20SQL%20Server%20Reporting%20Services&ProdVer=12.0.2000.8</HelpLink><ProductName">http://www.microsoft.com/sql/reportingservices">http://go.microsoft.com/fwlink/?LinkId=20476&amp;EvtSrc=Microsoft.ReportingServices.Diagnostics.Utilities.ErrorStrings&amp;EvtID=rsErrorOpeningConnection&amp;ProdName=Microsoft%20SQL%20Server%20Reporting%20Services&amp;ProdVer=12.0.2000.8</HelpLink><ProductName
    xmlns="Microsoft">http://www.microsoft.com/sql/reportingservices">Microsoft SQL Server Reporting Services</ProductName><ProductVersion xmlns="12.0.2000.8</ProductVersion><ProductLocaleId">http://www.microsoft.com/sql/reportingservices">12.0.2000.8</ProductVersion><ProductLocaleId
    xmlns="1033</ProductLocaleId><OperatingSystem">http://www.microsoft.com/sql/reportingservices">1033</ProductLocaleId><OperatingSystem xmlns="OsIndependent</OperatingSystem><CountryLocaleId">http://www.microsoft.com/sql/reportingservices">OsIndependent</OperatingSystem><CountryLocaleId
    xmlns="1033</CountryLocaleId><MoreInformation">http://www.microsoft.com/sql/reportingservices">1033</CountryLocaleId><MoreInformation xmlns="<Source>Microsoft.ReportingServices.ProcessingCore</Source><Message">http://www.microsoft.com/sql/reportingservices"><Source>Microsoft.ReportingServices.ProcessingCore</Source><Message
    msrs:ErrorCode="rsErrorOpeningConnection" msrs:HelpLink="http://go.microsoft.com/fwlink/?LinkId=20476&amp;EvtSrc=Microsoft.ReportingServices.Diagnostics.Utilities.ErrorStrings&amp;EvtID=rsErrorOpeningConnection&amp;ProdName=Microsoft%20SQL%20Server%20Reporting%20Services&amp;ProdVer=12.0.2000.8"
    xmlns:msrs="Cannot">http://www.microsoft.com/sql/reportingservices">Cannot create a connection to data source 'EntityDataSource'.</Message><MoreInformation><Source>Microsoft.AnalysisServices.AdomdClient</Source><Message></Message><MoreInformation><Source>Microsoft.SharePoint</Source><Message>Could
    not retrieve a valid Windows identity.</Message><MoreInformation><Source>mscorlib</Source><Message>WTS0003: The caller is not authorized to access the service.</Message></MoreInformation></MoreInformation></MoreInformation></MoreInformation><Warnings
    xmlns="http://www.microsoft.com/sql/reportingservices" /></detail>
    Kenny_I

    Hi Kenny_I,
    As per my understanding, I think this issue may be caused by your colleague has no permission to access to data source 'EntityDataSource', it is a Kerberos issue. When report server uses ‘Windows authentication (integrated) or SharePoint user’ as the credentials
    to access the data source 'EntityDataSource', the authentication would be failed.  So we should try to check if the issue is in this scenario. If in this case, we should change the credentials to stored credentials.
    Besides, if we don’t configure C2WTS Service Account to use Local System, it needs the following local policy rights:
    Act as part of the operating system.
    Impersonate a client after authentication.
    Log on as a service.
    For more details, please refer to the following blog:
    http://www.codeovereasy.com/2014/01/powerview-report-fails-no-credentials-are-available-in-the-security-package/
    Hope this helps.
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • Helpdesk Report Group Users - Cannot create a connection to data source 'DataSource1'

    Getting the following error for a User accessing the report who is a member of the reporting group. If I add them as a sysadmin in SQL they can get access. What permissions need changing for this user group?
    Cannot create a connection to data source 'DataSource1'. ---> System.Data.SqlClient.SqlException: Login failed for user

    Dave,
    For a complete understanding of the permission and groups, I would rather suggest you to do the installation of the MBAM components in a single server infrastructure in a test environment.
    Create the following domain security groups and use it during the configuration of the MBAM roles:-
    1) MBAM Advanced Helpdesk Users
    2) MBAM Helpdesk Users
    3) MBAM Report Users
    4) MBAM Read and Write Access
    5) MBAM Read Only Access.
    Create an application pool account and create a login in SQL for it. Use it only during:-
    1) Configuration of "Compliance and Audit Database connection"
    2) Configuration for All Web Applications.
    If your application pool account is not a domain administrator, the run the following powershell command to set the service principal name :-
    Setspn
    -s http//<FQDN of MBAM Web Server> domain\<Application pool account>
    Make sure the application pool account must be trusted for delegation.
    That's all you need to do. Then after the installation you can check the properties of each group in SQL to verify the rights and permission assigned during the installation.
    Regards, "Gaurav Ranjan" =========== NOTE: Mark as Answer and Vote as Helpful if it helps =======

  • Help needed on to write a program on connecting to data source

    I would to program a class that connect to data source without any manually configure.
    Is there other way that i could use intsead of using
    db = DriverManager.getConnection("jdbc:odbc:Driver={SQL Server};Server=MyServerName;Database=MyDataBase","","");
    My project requires me to use JDBC-ODBC Bridge on connecting to data source on client machine
    Is there any other way?

    Oh, oh,
    why???
    It's so simple to do a JDBC connection using the same connection params, which you use for your VB program's connnection.
    If your VB prog uses a system or user DSN configured via control panel, then use the same DSN in your Java prog.
    Dear karentan,
    you have just the same question now active in 4 or 5 different topics. And I and others have not been able to understand what really is your problem, I fear.
    Would you please do two things:
    1) Start a new topic (yes, another one!) and tell us there what exactly is your problem. What do you want to do?
    Not: is it possible ... but: I want ...
    2) Go to all the other topics you spreaded here and post the link of your new topic there, so that the poor people who try to answer your 5 (always the same) questions know that they can spare their time.
    Please, hold this forum useful!
    And let us come to the point that you are helped and we are glad!

  • Processing data base failed: Cannot connect to data source

    Hi,
    I have deployed my SSAS project to an Analysis services database on a SQL 2014 server instance using the "Development" build configration in Visual Studio. In order to avoid users accessing the development instance of the cube, I've created
    an additional "Release" build configuration and deployed my project to a different database on the same server. I've also created a production copy of the data source and changed the data source configuration of the production cube to point to this
    one.
    I've provided the same domain service account on the "Impersonation information" tab of the data source for both the development as well as the production instance of the cube. This account has also been granted identical permissions for both data
    sources. While everything works fine with the development database, processing the production database fails with an error message saying that it cannot connect to its respective data source.
    I'm using VS Ultimate 2013.4, SSDT 12.0.50318.0. Any hints pointing me in the right direction are appreciated.
    Many thanks
    Andreas

    Hi Andreas,
    According to your description, your production cube can't connect to data source when processing. Right?
    In this scenario, if both cube data sources are pointing to same source databases, both connection should work proerly. Since you created a copy of data source for your production cube, please make sure your type the right server name and test connection
    in your project. If you can connect successfully, I suggest you only keep this data source for your production project. If the issue still persists, I suggest you import the development database into a new project and save this one as your production database.
    If you still have any question, plesse provide some more information and share some screenshots.
    Best Regards, 
    Simon Hou
    TechNet Community Support

  • What is an ageing report? What are the data sources used to develop an agin

    Hello BW gurus,
    I was going thru some of the BW resumes. I could not understand some of the points mentioned below. Kindly go thru them and please explain each of it.
    Thank you.
    TR.
    •     Developed AR ageing report, created invoice layout and processed invoices.
    What is an ageing report? What are the data sources used to develop an aging report
    •     Worked on month-end and year end processes such as Balance Sheet Statements and Profit and Loss Accounts. 
    What data sources does one use to get Balance sheet and P&L accounts tables and fields.
    •     Involved in the end to end implementation of BW at Reliance Group as a team member.
    What are the tasks a BW consultant normally performs when he is involved in an end to end implementation project or
    a full life cycle project?
    •     Extensively worked on BW Statistics to optimize the performance of Info Cubes and to create Aggregates.
    What do you mean when you say worked on BW statistics to optimize the performance of Info Cubes.
    What are aggregates why do you need them?
    •     Prepared design documents from the Business Requirement documents and identified the
    relevant data targets for satisfying the customer requirements.
    What are the design documents does one prepare, please give an example. 
    Is cube a data target?

    What is an ageing report? What are the data sources used to develop an aging report
    Aging refers to values in different time period ranges. Example, the customer (credit) aging report can look like this.
    customer (credit)  for current period, 0 to 30 days, 30 to 90 days, 90 to 120 days. This is the way aging is classified.
    What data sources does one use to get Balance sheet and P&L accounts tables and fields.
    For P&L information, you may use 0FI_GL_6 datasource (or 0FI_GL_10 if you use ERP 5.0 version). This datasource reads the same information used in R/3 transaction f.01 (table glt0).
    What are the tasks a BW consultant normally performs when he is involved in an end to end implementation project or a full life cycle project?
    Requirement gathering, blueprint creation, development etc
    Refer to posts on Sap Methodology  and Sap lifecyle
    What do you mean when you say worked on BW statistics to optimize the performance of Info Cubes. What are aggregates why do you need them?
    Please check these links
    http://help.sap.com/saphelp_nw04/helpdata/en/8c/131e3b9f10b904e10000000a114084/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/f0/3c8c3bc6b84239e10000000a114084/plain.htm
    What are the design documents does one prepare, please give an example.
    Design document is basically a document to say  how the design is to be developed for a particular solution ex: FI it says what is the data fow and what are the data targets  to be used and how data shld be stored  for providing the client a solution they need.
    Is cube a data target?
    Yes cube is a data target.
    Hope this Helps
    Anand Raj

  • Error  while creating Generic data source using FM

    Hi Experts,
    I try to create a generic data source using the Function Module via the  transaction RSO2. I got the following error messages.
    " Das Einheitenfeld CURR des Feldes ZPKZA1 der DataSource ZBWN_DS_POLPOSP ist ausgeblendet"
    " Das Einheitenfeld CURR des Feldes ZPKZA2 der DataSource ZBWN_DS_POLPOSP ist ausgeblendet"
    " Das Einheitenfeld CURR des Feldes ZPKZA10 der DataSource ZBWN_DS_POLPOSP ist ausgeblendet"
    "The unit field CURR of the field ZPKZA1 of the DATA SOURCE ZBWN_DS_POLPOSP is not visible/ stopped/ hide".
    for all 10  fields of type CURR.
    How shall i handle this issue..........any suggestions please........
    thanks in advance
    cheers
    sailekha

    Hi,
    Are your CURR fields refereded to a currency field of your structure?? Maybe the problem is that the field containing the currency is refered to other table/structure and it has to be one of your structure fields.
    Hope this helps,
    Regards,
    Carlos.

  • PowerView error -Cannot create a connection to data source 'TemporaryDataSource'.

    Hello and thanks for the time.
    I am getting the following error when trying to create a powerview report.  I don't get where is this TemporaryDataSource is and how do I check the permissions on it?  that is what this error is pointing to, no?  I tried re-installing the
    SQL reporting add-in and no go there.  SQL Browser services are running.  I can see the file in Excel just can't create a powerview report.  any and all help is appreciated.  thanks.
    <detail><ErrorCode xmlns="http://www.microsoft.com/sql/reportingservices">rsCannotRetrieveModel</ErrorCode><HttpStatus xmlns="http://www.microsoft.com/sql/reportingservices">400</HttpStatus><Message xmlns="http://www.microsoft.com/sql/reportingservices">An
    error occurred while loading the model for the item or data source 'https://teamsite.domain.com/POWERPIVOT/PowerPivot%20Gallery/Test.xlsx'. Verify that the connection information is correct and that you have permissions to access the data source.</Message><HelpLink
    xmlns="http://www.microsoft.com/sql/reportingservices">http://go.microsoft.com/fwlink/?LinkId=20476&amp;EvtSrc=Microsoft.ReportingServices.Diagnostics.Utilities.ErrorStrings&amp;EvtID=rsCannotRetrieveModel&amp;ProdName=Microsoft%20SQL%20Server%20Reporting%20Services&amp;ProdVer=11.0.3128.0</HelpLink><ProductName
    xmlns="http://www.microsoft.com/sql/reportingservices">Microsoft SQL Server Reporting Services</ProductName><ProductVersion xmlns="http://www.microsoft.com/sql/reportingservices">11.0.3128.0</ProductVersion><ProductLocaleId
    xmlns="http://www.microsoft.com/sql/reportingservices">127</ProductLocaleId><OperatingSystem xmlns="http://www.microsoft.com/sql/reportingservices">OsIndependent</OperatingSystem><CountryLocaleId xmlns="http://www.microsoft.com/sql/reportingservices">1033</CountryLocaleId><MoreInformation
    xmlns="http://www.microsoft.com/sql/reportingservices"><Source>ReportingServicesLibrary</Source><Message msrs:ErrorCode="rsCannotRetrieveModel" msrs:HelpLink="http://go.microsoft.com/fwlink/?LinkId=20476&amp;EvtSrc=Microsoft.ReportingServices.Diagnostics.Utilities.ErrorStrings&amp;EvtID=rsCannotRetrieveModel&amp;ProdName=Microsoft%20SQL%20Server%20Reporting%20Services&amp;ProdVer=11.0.3128.0"
    xmlns:msrs="http://www.microsoft.com/sql/reportingservices">An error occurred while loading the model for the item or data source 'https://teamsite.domain.com/POWERPIVOT/PowerPivot%20Gallery/Test.xlsx'. Verify that the connection information is
    correct and that you have permissions to access the data source.</Message><MoreInformation><Source>Microsoft.ReportingServices.ProcessingCore</Source><Message msrs:ErrorCode="rsErrorOpeningConnection" msrs:HelpLink="http://go.microsoft.com/fwlink/?LinkId=20476&amp;EvtSrc=Microsoft.ReportingServices.Diagnostics.Utilities.ErrorStrings&amp;EvtID=rsErrorOpeningConnection&amp;ProdName=Microsoft%20SQL%20Server%20Reporting%20Services&amp;ProdVer=11.0.3128.0"
    xmlns:msrs="http://www.microsoft.com/sql/reportingservices">Cannot create a connection to data source 'TemporaryDataSource'.</Message><MoreInformation><Source></Source><Message>For more information about this error
    navigate to the report server on the local server machine, or enable remote errors</Message></MoreInformation></MoreInformation></MoreInformation><Warnings xmlns="http://www.microsoft.com/sql/reportingservices" /></detail>

    Hi,
    Issue not supported in sharepoint on-premise team.
    In addition, as this issue is related to Powerview, I suggest you create a new thread on for Powerview forum, more experts will assist you.
    https://social.technet.microsoft.com/Forums/en-US/home?forum=powerview
    Best Regards,
    Lisa Chen
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • Failed to close connection for data source "EntityDataSource"

    Hi All,
    I have deployed some PowerView reports on SharePoint 2013.
    I have open it on sharepoint, wait for 5 mins & then I try to change any filter then I am getting following error as
    Failed to close connection for data source "EntityDataSource"
    Error Text:
    <detail>
    <ErrorCode xmlns="http://www.microsoft.com/sql/reportingservices">rsErrorClosingConnection</ErrorCode>
    <HttpStatus xmlns="http://www.microsoft.com/sql/reportingservices">400</HttpStatus>
    <Message xmlns="http://www.microsoft.com/sql/reportingservices">Failed to close connection for data source 'EntityDataSource'.</Message>
    <HelpLink xmlns="http://www.microsoft.com/sql/reportingservices">http://go.microsoft.com/fwlink/?LinkId=20476&amp;EvtSrc=Microsoft.ReportingServices.Diagnostics.Utilities.ErrorStrings&amp;EvtID=rsErrorClosingConnection&amp;ProdName=Microsoft%20SQL%20Server%20Reporting%20Services&amp;ProdVer=11.0.3128.0</HelpLink>
    <ProductName xmlns="http://www.microsoft.com/sql/reportingservices">Microsoft SQL Server Reporting Services</ProductName>
    <ProductVersion xmlns="http://www.microsoft.com/sql/reportingservices">11.0.3128.0</ProductVersion>
    <ProductLocaleId xmlns="http://www.microsoft.com/sql/reportingservices">1033</ProductLocaleId>
    <OperatingSystem xmlns="http://www.microsoft.com/sql/reportingservices">OsIndependent</OperatingSystem>
    <CountryLocaleId xmlns="http://www.microsoft.com/sql/reportingservices">1033</CountryLocaleId>
    <MoreInformation xmlns="http://www.microsoft.com/sql/reportingservices">
    <Source>Microsoft.ReportingServices.ProcessingCore</Source>
    <Message msrs:ErrorCode="rsErrorClosingConnection" msrs:HelpLink="http://go.microsoft.com/fwlink/?LinkId=20476&amp;EvtSrc=Microsoft.ReportingServices.Diagnostics.Utilities.ErrorStrings&amp;EvtID=rsErrorClosingConnection&amp;ProdName=Microsoft%20SQL%20Server%20Reporting%20Services&amp;ProdVer=11.0.3128.0"
    xmlns:msrs="http://www.microsoft.com/sql/reportingservices">Failed to close connection for data source 'EntityDataSource'.</Message>
    <MoreInformation><Source></Source><Message>For more information about this error navigate to the report server on the local server machine, or enable remote errors</Message></MoreInformation></MoreInformation><Warnings
    xmlns="http://www.microsoft.com/sql/reportingservices" /></detail>
    Is it because of Session Timeout?or may be something else
    Thanks in advance.

    Hi Rameshwar,
    Pleaese help to collect SharePoint ULS Log related to this issue for further investigation, please see:
    Configure and View SharePoint Log Files and Diagnostic Logging (PowerPivot for SharePoint):
    http://technet.microsoft.com/en-us/library/ee210652.aspx
    In addition, could you please elaborate this issue with more deail how this issue happened? Are you encountered this issue while you view the Power View report on SharePoint site?
    Regards,
    Elvis Long
    TechNet Community Support

Maybe you are looking for