InfoPackage External Data Create Routine

There is a Create Routine option in External Data tab for InfoPackage.
What is this create routine is for? When we can use it. One example and explain how to debug it.
Thanks in advance.

Hi..
InfoPackages provide static and dynamic selection criteria for every selection field for various characteristic types
Date field (due date is actual day):
Get yesterday (00:00 to 24:00h)
Get last week (Monday to Sunday)
Get last month (first to last day of last month)
Get last quarter (first to last day of last quarter)
Get last year (1st of Jan. to 31st of Dec. of previous year)
No date field:
Free boundary (also a period boundary is possible)
All fields:
ABAP Routine
OLAP Variable
When the button on the InfoPackage tab “Data Targets” is grey, there are no functions for deletion defined
When a deletion function is defined the symbol appears
The deletion functionalities are executed after all update rules have run
Multiple deletion conditions are
possible at the same time:
By object types
By time definition
By routine
Exceptions to the deletion conditions can be set for specific days
Should you upload from client workstation or the application server....
It is preferable to use the server path  advantages:
Data load in batch mode is possible
Path is physically equal to all administrators
Scenario in which to use it:
Transaction data is delivered monthly by flat file
The naming convention includes the name of the month within the filename
Directory paths are maintained for every year  Coding:
Concatenate
Directory path
Actual year
Actual month

Similar Messages

  • What is the significance of create routines found in infopackage?

    hi all,
    Can anyone explain me with an example the significance of create routines found in infopackage - external data tab.
    And as well as writing an abap routine in the data selection tab of the info package.
    regds
    hari

    hi,
    if u want to load only particular values to the particular field... let s say example
    material colour = 'Red'
    by writing routine at infopackge in data selection tab u can achive this
    its just one example
    Check this thread...
    Flatfile renaming logic and upload date logic!
    thanks
    Message was edited by:

  • Routines for File name at External Data in Info Package level.

    Hi All,
    Can any one give the example codes of how to write the routine for Files at External Data in Info Package level.
    Regards
    srinivas

    Hi Srinivas
    Here iam attaching a sample code in the infopackage level this code is used to select the Current version from TVARV table ..based on the version from variable the data is loaded into the ods..
    data: l_idx like sy-tabix.
              read table l_t_range with key
                   fieldname = 'FISCPER'.
              l_idx = sy-tabix.
    tables tvarv.
    data: v_prever(6)   type c,
          v_fiscper(7)  type n.
      clear tvarv.
      select single low
       from tvarv
       into v_prever
      where name = 'ZBSK_PREVIOUS_RELEASED_VERSION' and
            type = 'P' and
            numb = '0000'.
    concatenate v_prever(4) '0' v_prever+4(2) into v_fiscper.
       concatenate  '0' v_prever+4(2) v_prever(4) into v_fiscper.
            l_t_range-low = v_fiscper .
              modify l_t_range index l_idx.
    Hope the above code helps you..
    let me know in case of any concerns.. and further help needed..
    bye
    Shu Moh..

  • ABAP ROUTINE AT INFOPACKAGE FOR DATE RANGE

    hi all,
    I want to Schedule my infopackge with selection options 
    0DATE  infoobject with First date of current month( 01.02.2008)  to last date of current month ( 29.02.2008).
    this i have to get automatically bcoz i have to use this in process chain.
    so I want to write a routine for this at the infopackage level with ABAP Routine -6 option.
    So please suggest me how to write the code for this case.
    thanks,
    kiran manyam.

    Hi Kiran,
    Please paste the following code there and also check for syntax error.
    data first_date type d.
    data last_date type d.
    first_date = sy_datum.
    first_dat+6(2) = '01'.
    CALL FUNCTION 'SLS_MISC_GET_LAST_DAY_OF_MONTH'
    Exporting
    DAY_IN = first_date
    Importing
    LAST_DAY_OF_MONTH = last_date.
              read table l_t_range with key
                   fieldname = 'DATE'.
               if sy-subrc = 0.
                   l_idx = sy-tabix.
                   l_t_range-sign = 'I'.
                   l_t_range-option = 'BT'.
                   l_t_range-low = first_date.
                   l_t_range-high = last_date.
                   modify l_t_range index l_idx.
                else.
                   move 'DATE' to l_t_range-fieldname.
                   l_t_range-sign = 'I'.
                   l_t_range-option = 'BT'.
                   l_t_range-low = first_date.
                   l_t_range-high = last_date.
                   append l_t_range.
                   endloop.
                endif.
              p_subrc = 0.

  • Creating Sql Server 2005 External Data Source

    Hey guys, I'm trying to connect to an SQL Server 2005 database directly from the BAM external Data Source.
    I have the driver name and the connection string, login and password. I also have the driver, but BAM doesn't seem to have a "drivers" folder. So when I try to connect, I get:
    BAM-00008: Invalid Oracle driver name
    Source: "java.lang.ClasssNotFoundException: com.microsoft.sqlserver.jdbc.SQLServerDriver" ID: "InvalidOracleDriverName"
    Has anyone done this before? Am I only allowed to connect to an Oracle Database from BAM? Thanx!

    Hi,
    I use BAM with SQL Server External Data Source and works fine.
    In the Architect set this parameters on conection with SQL Server (EXTERNAL DATA SOURCE):
    Driver: SQL Server
    Connection string / URL: SERVER=<host>;DATABASE=<name_db>;
    <host> = ip or name of the server
    <name_db> = name of the database on the SQL Server
    I use BAM 10.1.3.3.0 with SQL Server 2005
    Regards

  • Determining File Name in Info Package under External Data

    Determining File Name in Info Package under External Data
    I am on SAP BW 3.0. A System is sending a flat file every few days
    With a date time stamp, e.g., d:\loaddar\file_20080212_122300.csv
    I know in Info Package one can create routine under external data to determine the file name. I have seen
    Examples where people determine file name based on date. Since my file has a time stamp, what code  I write a  to pick the file. Is there a way to read one or more files and
    Determine file name.
    I am new to SAP BW and ABAP. However, I have lot of experience with Oracle and Java.
    Can someone point me how this will be done. I am looking for some sample code as well.
    Thanks in advance. I will really appreciate your help.

    Hello Prem,
    Even i used to get the file suffix with date & time, and i found very difficult to pick up the file from application server using routine in infopackge. Then i asked to change to date only and it was easy to pick the file using routine. But i think in your case files are coming more than once, in such a case you should write a small unix script to add these files and then convert into single file with date only and execute the infopackage to load it.
    Cheers!
    Sanjiv

  • Creating routine

    hi,
       i need to have a routine in the external data tab -> infopackage , so that the routine takes changes the file in the external data tab with respect to the month. can any body help me with this as i have no idea about the routines. the file naems are similar to each other in all ways except that the month on the file name is different.
    please some body help me by giving the entire program. help needed immidiately.
    points will be fully rewarded.
    Thanx,
    Ravi.
    Message was edited by: ravi kalidindi

    Ravi , check if this code is useful for you.
      IF NOT i_itab[] IS INITIAL.
        CALL FUNCTION 'MONTH_NAMES_GET'
    EXPORTING
      LANGUAGE                    = SY-LANGU
    IMPORTING
      RETURN_CODE                 =
      TABLES
        MONTH_NAMES                 = itab_month
    EXCEPTIONS
      MONTH_NAMES_NOT_FOUND       = 1
      OTHERS                      = 2
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    READ TABLE itab_month
    WITH KEY MNR = sy-datum+4(2).
      CONCATENATE p_file itab_month-ltx '.TXT' INTO p_file.
      OPEN DATASET p_file FOR OUTPUT IN TEXT MODE.
      IF NOT i_itab[] IS INITIAL.
        LOOP AT itab_out.
          TRANSFER itab_out TO p_file.
        ENDLOOP.
    IF sy-subrc = 0.
          MESSAGE s398(00) WITH p_file(25) 'created on Unix server'.
          ELSE.
          MESSAGE e398(00) WITH p_file(25) 'cannot be created'.
        ENDIF.
      ENDIF.

  • Data deletion routine in the info package

    Hi All,
    I am writting an data deletion routine in the info package.
    it is working fine...
    but when we are transporting the info package, that routine is not getting transported.
    we have tried sending ths info package through a transport connection.
    but still it is not taking the routine to next system.
    please let me know if any one has a solution for this.
    Thanks,
    Mugdha

    Hi Mughda,
    Collect the infopackage using transport connection, While collecting the infopackage make sure that Routines are also collected in the same request.
    Else most of systems will have authorizations to create infopackages, so try to create one IP and use the routine in IP.
    Hope this helps.
    Rgs,
    I.R.K

  • External Data Refresh failed - Unable to refresh list data in Excel Web Access WebPart

    Hi,
    I have created a PivotChart in Excel workbook that fetches data from a SharePoint list using "OData Data Feed". When refreshing the connection in Excel 2013, the updated data is displayed in PivotChart. But when i upload the same to a SharePoint
    Library and refresh it through Excel Web Access WebPart, it throws an error.
    After configuring PowerPivot for SharePoint, i am getting a "We cannot locate a server to load the Data Model" error.
    Note -
    SQL Analysis Service(PowerPivot) is in running state.
    PowerPivot Server has been under Data Model in Excel Service setting.
    The library location is added in trusted zone.
    Using secure store didn't fix the issue.
    Stack Exception
    SSPM: Initialization failed on server : Microsoft.AnalysisServices.ConnectionException: A connection cannot be made. Ensure that the server is running. ---> System.Net.Sockets.SocketException: No connection could be made because the target machine actively
    refused it 127.0.0.1:2383 
        at System.Net.Sockets.TcpClient..ctor(String hostname, Int32 port) 
        at Microsoft.AnalysisServices.XmlaClient.GetTcpClient(ConnectionInfo connectionInfo)     --- End of inner exception stack trace --- 
        at Microsoft.AnalysisServices.XmlaClient.GetTcpClient(ConnectionInfo connectionInfo) 
        at Microsoft.AnalysisServices.XmlaClient.OpenTcpConnection(ConnectionInfo connectionInfo) 
        at Microsoft.AnalysisServices.XmlaClient.OpenConnection(ConnectionInfo connectionInfo, Boolean& isSessionTokenNeeded) 
        at Microsoft.AnalysisServices.XmlaClient.Connect(ConnectionInfo connectionInfo, Boolean beginSession) 
        at Microsoft.AnalysisServices.Server.Connect(String connectionString, String sessionId, ObjectExpansion expansionType) 
        at Microsoft.AnalysisServices.Streaming.OnPremise.Server.Connect(Nullable`1 ctx, Boolean schedulePingTaskOnFailure) 
        at Microsoft.AnalysisServices.Streaming.OnPremise.Server.Initialize(Guid serviceId, CancellationToken ctx) 
        at Microsoft.AnalysisServices.Streaming.OnPremise.Tasks.InitializationTask.Run(CancellationToken ctx)
    Check Server Version (ServerName\POWERPIVOT): Fail (Expected:
        =11.0.2800.0, Actual: 11.0.2100.60).
        --> Check Deployment Mode (ServerName\POWERPIVOT): Pass.
        Monitorable Check Server Configuration (ServerName\POWERPIVOT): Fail (Uninitialized, ConfigurationError, WrongVersion).
        SSPM: Initialization failed on server ServerName\POWERPIVOT: Microsoft.AnalysisServices.Streaming.ServerConfigurationException: Server ServerName\POWERPIVOT failed configuration checks (Status = Uninitialized, ConfigurationError, WrongVersion).
    at Microsoft.AnalysisServices.Streaming.OnPremise.Server.AssertServerConfiguration(Server amoServer, CancellationToken ctx) at Microsoft.AnalysisServices.Streaming.OnPremise.Server.Initialize(Guid serviceId, CancellationToken ctx) at Microsoft.AnalysisServices.Streaming.OnPremise.Tasks.InitializationTask.Run(CancellationToken
    ctx)
    Thanks,
    Thomas Mathew

    Hi,
    For your issue, the possible reason is that the SharePoint environment does not have a PowerPivot for SharePoint server, or the SQL Server Analysis Services (PowerPivot) service is stopped.
    Install PowerPivot for SharePoint or move the PowerPivot workbook to a SharePoint environment that has PowerPivot for SharePoint installed.
    If the software is installed, verify that the SQL Server Analysis Services (PowerPivot) instance is running. Check Manage services on server in Central Administration. Also check the Services console application in Administrative Tools.
    Refer to the following link:
    http://msdn.microsoft.com/en-us/library/ff487858.aspx
    Besides, here is a similar post, you can use as a reference:
    https://social.technet.microsoft.com/Forums/en-US/2e728b3e-6d3d-497b-b0ce-57f2699710e5/access-was-denied-by-the-external-data-source-the-following-connections-failed-to?forum=sharepointadminprevious
    Best Regards,
    Lisa Chen
    Lisa Chen
    TechNet Community Support

  • Unable to add external data source in BAM : Error ORA-12505

    Hi,
    In BAM,
    Im trying to add an external data source for creating a data object.
    But when i try to test the connection i get the following error:
    Listener refused the connection with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
    Source: "java.sql.SQLException: Listener refused the connection with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor "
    Listener refused the connection with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
    Source: "oracle.net.ns.NetException: Listener refused the connection with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor "
    As mentioned in another post ((Listener does not currently know of SID given in connection descriptor
    i tried
    lsnrctl stop.
    delete listener.ora
    lsnrctl start
    lsnrctl reload
    But still get the same error;
    Im able to access the database with the specified username and password using sqlplus.
    Your help will be appreciated.
    Regards
    Vignesh Ramanathan

    For #5, not Windows, ConfigMgr 2012 R2. Anything before ConfigMgr 2012 R2 is not supported for the 8.1 ADK.
    For the permissions, what accounts are you setting this for. In general, if the share is on the same server, Everyone Full or Read on the Share and System Full or Read on the NTFS should work.
    For the error message, it looks like you are trying to import an OS Image and not an OS Install Package. OS images use a WIM file and OS Install Packages use the entire set of source files from the media. For OS images, you must thus explicitly point it
    to a specific WIM file.
    Jason | http://blog.configmgrftw.com

  • Cannot add hub-managed content type with external list lookup columns to a list -- Error:Id field is not set on the external data field

    This is a variation on the issue mentioned in this
    post
    We are using SP 2010 Content Hub to manage our content types.  On the content hub we've created a couple of exteranl lists, and then created some site columns as lookups against these lists.  We then added the columns to one of our content types
    and set it to publish.
    After the publishing job executed, I tried adding the content type (which now appears on the subscriber sites) to one of the document libraries on one of the subscriber sites.  When I did that it threw the following error:
    Microsoft.SharePoint.WebControls.BusinessDataListConfigurationException: Id field is not set on the external data field    
    at Microsoft.SharePoint.SPBusinessDataField.CreateIdField(SPAddFieldOptions op)     
    at Microsoft.SharePoint.SPBusinessDataField.OnAdded(SPAddFieldOptions op)     
    at Microsoft.SharePoint.SPFieldCollection.AddFieldAsXmlInternal(String schemaXml, Boolean addToDefaultView, SPAddFieldOptions op, Boolean isMigration, Boolean fResetCTCol)     
    at Microsoft.SharePoint.SPContentType.ProvisionFieldOnList(SPField field, Boolean bRecurAllowed)     
    at Microsoft.SharePoint.SPContentType.ProvisionFieldsOnList()     
    at Microsoft.SharePoint.SPContentType.DeriveContentType(SPContentTypeCollection cts, SPContentType& ctNew)     
    at Microsoft.SharePoint.SPContentTypeCollection.AddContentTypeToList(SPContentType contentType)     
    at Microsoft.SharePoint.SPContentTypeCollection.AddContentType(SPContentType contentType, Boolean updateResourceFileProperty, Boolean checkName, Boolean setNextChildByte)     
    at Microsoft.SharePoint.SPContentTypeCollection.Add(SPContentType contentType)     
    at Microsoft.SharePoint.ApplicationPages.AddContentTypeToListPage.Update(Object o, EventArgs e)     
    at System.Web.UI.WebControls.Button.OnClick(EventArgs e)     
    at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument)     
    at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)     
    at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)    b55297ed-717f-466d-8bdc-297b20344d3f
    I checked the external  content type configuration and it did specify an "id column".  Anyone know if what I am attempting to do is possible and if so, what special configurations are required?
    Thanks

    The issue is not External Content type or external list but the look up column.
    It's not possible to publish a look up column via the Content Type Hub.
    If you need to do this then an alternate way is to use a Managed Metadata column instead, otherwise you will have to implement this via a feature.
    Varun Malhotra
    =================
    If my post solves your problem could you mark the post as Answered or Vote As Helpful if my post has been helpful for you.

  • Excel SSAS Tabular error: An error occurred during an attempt to establish a connection to the external data source

    Hello there,
    I have an Excel report I created which works perfectly fine on my dev environment, but fails on my test environment when I try to do a data refresh.
    The key difference between both dev and test environments is that in dev, everything is installed in one server:
    SharePoint 2013
    SQL 2012: Database Instance, SSAS Instance, SSRS for SharePoint, SSAS POWERPIVOT instance (Powerpivot for SharePoint).
    In my test and production environments, the architecture is different:
    SQL DB Servers in High Availability (irrelevant for this report since it is connecting to the tabular model, just FYI)
    SQL SSAS Tabular server (contains a tabular model that processes data from the SQL DBs).
    2x SharePoint Application Servers (we installed both SSRS and PowerPivot for SharePoint on these servers)
    2x SharePoint FrontEnd Servers (contain the SSRS and PowerPivot add-ins).
    Now in dev, test and production, I can run PowerPivot reports that have been created in SharePoint without any issues. Those reports can access the SSAS Tabular model without any issues, and perform data refresh and OLAP functions (slicing, dicing, etc).
    The problem is with Excel reports (i.e. .xlsx files) uploaded to SharePoint. While I can open them, I am having a hard time performing a data refresh. The error I get is:
    "An error occurred during an attempt to establish a connection to the external data source [...]"
    I ran SQL Profiler on my SSAS Server where the Tabular instance is and I noticed that every time I try to perform a data refresh, I get the following entries:
    Every time I try to perform a data refresh, two entries under the user name ANONYMOUS LOGON.
    Since things work without any issues on my single-server dev environment, I tried running SQL Server Profiler there as well to see what I get.
    As you can see from the above, in the dev environment the query runs without any issues and the user name logged is in fact my username from the dev environment domain. I also have a separated user for the test domain, and another for the production domain.
    Now upon some preliminary investigation I believe this has something to do with the data connection settings in Excel and the usage (or no usage) of secure store. This is what I can vouch for so far:
    Library containing reports is configured as trusted in SharePoint Central Admin.
    Library containing data connections is configured as trusted in SharePoint Central Admin.
    The Data Provider referenced in the Excel report (MSOLAP.5) is configured as trusted in SharePoint Central Admin.
    In the Excel report, the Excel Services authentication settings is set as "use authenticated user's account". This wortks fine in the DEV environment.
    Concerning SecureStore, PowerPivot Configurator has configured it the PowerPivotUnnattendedAccount application ID in all the environments. There is
    NO configuration of an Application ID for Excel Services in any of the environments (Dev, test or production). Altough I reckon this is where the solution lies, I am not 100% sure as to why it fails in test and prod. But as I read what I am
    writing, I reckon this is because of the authentication "hops" through servers. Am I right in my assumption?
    Could someone please advise what am I doing wrong in this case? If it is the fact that I am missing an Secure Store entry for Excel Services, I am wondering if someone could advise me on how to set ip up? My confusion is around the "Target Application
    Type" setting.
    Thank you for your time.
    Regards,
    P.

    Hi Rameshwar,
    PowerPivot workbooks contain embedded data connections. To support workbook interaction through slicers and filters, Excel Services must be configured to allow external data access through embedded connection information. External data access is required
    for retrieving PowerPivot data that is loaded on PowerPivot servers in the farm. Please refer to the steps below to solve this issue:
    In Central Administration, in Application Management, click Manage service applications.
    Click Excel Services Application.
    Click Trusted File Location.
    Click http:// or the location you want to configure.
    In External Data, in Allow External Data, click Trusted data connection libraries and embedded.
    Click OK.
    For more information, please see:
    Create a trusted location for PowerPivot sites in Central Administration:
    http://msdn.microsoft.com/en-us/library/ee637428.aspx
    Another reason is Excel Services returns this error when you query PowerPivot data in an Excel workbook that is published to SharePoint, and the SharePoint environment does not have a PowerPivot for SharePoint server, or the SQL Server Analysis
    Services (PowerPivot) service is stopped. Please check this document:
    http://technet.microsoft.com/en-us/library/ff487858(v=sql.110).aspx
    Finally, here is a good article regarding how to troubleshoot PowerPivot data refresh for your reference. Please see:
    Troubleshooting PowerPivot Data Refresh:
    http://social.technet.microsoft.com/wiki/contents/articles/3870.troubleshooting-powerpivot-data-refresh.aspx
    Hope this helps.
    Elvis Long
    TechNet Community Support

  • Sharepoint 2013 Excel External Data Source Refresh Issue

    I have been facing this issue for quite some time now.. i have created an Excel sheet in Excel-13 and have imported data from an external data source [SQL server 2012]. 
    Everything is working fine, with the excel sheet on the desktop. Data refreshes, every-time i open the excel file and also at regular intervals that i have configured in the data source properties.
    The problem begins when i save that excel sheet on my sharepoint server. the issues that i am facing are :
    1. Changes made into the original data source, are not reflected immediately inside the excel sheet inside the browser. after 5-10 minutes, it reflects the changes..
    2. The data doesn't refreshes automatically. After i update my data inside the sql server table, i have to manually trigger the refresh of the data connection when viewing the excel sheet inside the browser, even though i have marked "Refresh when opening
    the file", and refresh every 1 minute inside the excel sheet. Any solutions ??
    I have been troubled a lot by this issue, and seek for some quick solution.. Any help here ??

    I found the solution finally, my self ..
    Issue - 1 : It's going to take atleat 5-minutes to refresh the data connection, that is generally not a big time span.
    Issue - 2 : 
    --> Set Your connection to refresh everytime the file is opened. go to internet explorer -> file -> internet options -> general -> Browsing History -> Settings -> Check for newer versions of stored pages... Check 'Every time I visit the
    webpage'. 
    Now everytime i update your original data source, wait for 5-10 minutes and refresh my web page containing the excel sheet.. The Contents of the excel sheet are updated as desired..

  • External Data Refresh Failed. We cannot locate a server to load the workbook Data Model. ThisWorkBookDataModel

    Hi All,
    I have been trying to fix this for days now. I have tried solutions in many articles but to no avail. So while the error message is something you may have seen may times, I just can't find a solution in my case.
    This is the error:
    And in text just in case the image isn't viewable:
    "External Data Refresh Failed. We cannot locate a server to load the workbook Data Model. We were unable to refresh one or more data connections in this workbook. The following connections failed to refresh: ThisWorkBookDataModel."
    What is worse is I have checked the ULS (SharePoint Trace Logs), the Event Viewer Logs and the OWA Logs and I cannot find a specific error that would help pin point the problem.
    Excel Workbook
    So what am I doing? I have an Excel 2013 workbook and I create an "SQL Server" connection to the AdventureWorksDW database, add a pivot table and a pivot chart, test in in Excel and all works fine.
    I save the Excel workbook to SharePoint 2013 and then select "Data" then "Refresh All Connections" and then I get the error in the picture above.
    Even more puzzling is I have another Excel workbook that also has pivot tables and pivot charts in the AdventureWorksDW2012Multidimensional cube database in "SQL Analysis Services" and this works fine. Hmmm.
    My Environment
    My environment is Windows 2008 R2 Server, SharePoint 2013 with the April Service Pack1 and a separate server with OWA2013 SP1. It has an SQL Server 2008 R2 database which has been upgraded to SQL Server 2012.
    Data Model Settings
    In Excel Services this is set to my server name which is "server-name". As I do not have instances all I can enter is the server name. As this works everywhere else including the workbook outside of SharePoint I do not think this is the problem.
    But I could be wrong.
    Unattended Account
    I have set this up for the PowerPivot Services App and Excel Services App.
    ODC Connections in Excel
    I have tried all 3 authentication modes, Windows, Secure Store ID and "None" which is the unattended account. I have not tried the other connection types, should I?
    Not in WOPI
    I am not in WOPI mode.
    AD Accounts
    I have added permissions in the SharePoint Services and SQL Server, and as they work in Excel outside of SharePoint, I do not think it is a permissions issue. I could be wrong of course, but the problem is in one of SharePoint, OWA, AD,
    SQL Server, Excel, and Windows Server.
    Isolate the Error
    Below is a list of errors I think are relevant but they do not tell me much. The SharePoint logs are not really giving me an error that tells me what to do and where to do it, or even why it cannot refresh, (perhaps not noticeable by the untrained eye).
    Problem with SQL Server Not Analysis Services
    So my cube database in analysis services works fine in SharePoint/OWA but not the databases in sql server. This is my best clue but I have no idea what it means. Why would it work with an Analysis Services connection but not an "SQL Server" connection?
    It Works Outside of SharePoint
    If I run the excel worksheet outside of SharePoint all works fine. When inside OWA this is where the refresh error occurs.
    Errors from Event Viewer on SharePoint Server using ULS Viewer
    "Failed to create an external connection or execute a query. Provider message: There are no servers available or actively being initialized., ConnectionName: , Workbook:"
    "Refresh failed for 'ThisWorkbookDataModel' in the workbook 'http://server...'. [Session: 1.V22.26itT0lx8piNFeqtuGVhN214.5.en-US5.en-US36.98c0e158-9113-46e9-850e-edda81d9ed1c1.A1.N User: 0#.w|ad\testuser1]"
    And an error in the ULS under the "Data Model" category:
    "--> Check Deployment Mode (server-name): Fail (Expected: SharePoint, Actual: Multidimensional)."
    This last error, as it turned out, defined the problem concisely, although I was yet to work out what it meant in some detail.

    I finally solved this myself (or should I say with the help of several key articles).
    The refresh did not work because the database was not in "SharePoint Mode". Yes, SQL Server has modes, 3 of them in fact.
    If you installed SharePoint to the default SQL instance which would be called <servername> then you cannot use this default instance for Excel 2013 workbooks in OWA 2013 because the refresh only works if the database is in SharePoint mode.
    So what are these 3 modes? The Deployment Mode property in the msmdsrv.ini file has them as:
    0 = Multidimensional mode (the default whenever you install SQL Server normally)
    1 = PowerPivot for SharePoint mode
    2 = Tabular mode mode
    How do you know what mode you are in? That's easy, open SQL Studio Manager and connect to all your SQL database engine instances (ignore Analysis Services or SSRS as they are not database engines). If you only have the default instance then that is almost
    definately in Multidimensional mode which is the default and what SharePoint installs its databases to.
    You must have an instance called <servername>\POWERPIVOT. This instance is the "sharepoint mode" needed, and the default instance name when you install an SQL instance in this mode.
    If you don't see <servername>\POWERPIVOT in SQL server then you are not in "sharepoint mode". It is more accurate to say, you do not have an instance that is in sharepoint mode. This is because you cannot simply switch modes on an SQL server.
    You have to install a new instance in the required mode, thats the only way.
    That's easy enough. Load up the SQL Server setup CD and run setup. Install a brand new instance and select "SQL Server PowerPivot for SharePoint" when you get there in the wizard.
    Now you will have the default instance that stores all the SharePoint databases and that is in mode 0, and a new instance called <servername>\POWERPIVOT that is in mode 1. The "<servername>\POWERPIVOT" instance connection is what you
    will use for Excel 2013 when rendering in OWA 2013.
    You also need to ensure OWA 2013 is not in WOPI mode for Excel worksheets. See the last link below for more information about WOPI.
    Next you should go to the Excel Service App in CA and click Data Model Settings and add the <servername>\POWERPIVOT instance.
    Then you have to either turn off the firewall on the SQL server machine, or create an inbound rule on the Windows firewall to open the TCP port for the <servername>\POWERPIVOT instance:
    1. Start Task Manager and then click Services to get the PID of the MSOLAP$InstanceName.
    2. Run netstat –ao –p TCP from the command line to view the TCP port information for that PID.
    Finally, you can now create Excel 2013 workbooks that run in OWA without refresh errors, as long as you are connecting to the <servername>\POWERPIVOT instance. Hooray.
    REFERENCES
    Look for the string "There are no servers available or actively being initialized" in this article:
    http://blogs.msdn.com/b/analysisservices/archive/2012/08/02/verifying-the-excel-services-configuration-for-powerpivot-in-sharepoint-2013.aspx
    Determine the server mode:
    http://msdn.microsoft.com/en-au/library/gg471594(v=sql.110).aspx
    Install the SharePoint PowerPivot instance (aka SharePoint mode)
    http://msdn.microsoft.com/en-au/library/eec38696-5e26-46fa-bc83-aa776f470ce8(v=sql.110)
    Open the port for the new SQL instance:
    http://msdn.microsoft.com/en-us/library/ms174937(v=sql.110).aspx
    Turn Off WOPI for Excel OWA
    http://blogs.technet.com/b/excel_services__powerpivot_for_sharepoint_support_blog/archive/2013/01/31/powerpivot-for-sharepoint-browser-refresh-fails-data-refresh-not-supported-in-office-web-apps.aspx

  • Is it possible to display external data in SAP B1 Grid?

    Hi,
    If the data reside in SAP B1 DB, it is normal. But if I have some data outside of SAP B1, for example in our old ERP system which is also a MS SQL db. Can I display it a SAP B1's grid? Reading external data shouldn't be a problem, but can I display it in a standard SAP B1 grid? I checked Grid object all method or properties, seems no way to load an external data source or manually create column and rows. Any idea?
    Thanks,
    Lan

    Hi Gordon,
    Thanks for your reply. Can you describe more detail about how to map an UDF to other DB? I check the UDF management menu, I didn't see any menu which allows me to link to external DB. The only similar option is you can set a linked table for the UDF, but that only applies to the UDO table inside SAP B1 DB.  Also, UDF is just a field and usually my external data is a query which returns me rows with mutiple columns. I tried the UDO table, nothing can be found to allow me connecting to an external DB.
    Thanks,
    Lan

Maybe you are looking for

  • Error message when opening a Pages Document

    I unintentionally added a .doc extension to a pages document. I erased the .doc extension, and now when I try to open it I get an error message "Import Error, Unknown Error". What shoudl I do to be able to open my document? Thanks in advance

  • XK03 - Error in attachment creation

    In XK03 when i try to create a attachment it is giving an error message in SAP ECC 6.0 "Error occurred during import" Error occurred during import Message no. SO424 Diagnosis An error occured during the import of a file. System Response The import wa

  • Profit Center Balances

    Hi How to reverse profit center balances. Regds, Sannari Moderator: Please, read the rules of this forum

  • Set mandatory fields for MSC2N, MSC3N

    Hi, I have done the configurations in Edit Field Selection Control in Batch Management. I've set the mandatory selection for all msc*. But seems it only works for MSC1N, not the others. Can someone tell me why and how correct it. Thank you.

  • Guaranteed Crash – Adding page via Pages panel

    Hiya, When I try to add a page to my document or organise existing pages – via the Pages panel – InDesign freezes and I end up force quitting. Its with this one specific document for some reason... Anyone has the same issue? Thanks,