cancel
Showing results for 
Search instead for 
Did you mean: 

How to overwrite a report in SAP BI 4.1

Former Member
0 Kudos

Good Day,

I'm trying to replace an old report from SAP BI server (without re-scheduling), but when I try to do it through Crystal Report (Desktop, v11) show me the error "Another Crystal Reports document with the same name exist in this folder", so I can't.

I can't recreate the schedules because there are a lot, so, was figuring out if I can do this through the SDK, I know programming but I'm really new on SAP BI SDK, only want to know which methods should I use and things like that, if you have a sample code that would be awesome!.

Thanks in advance for any help.

Accepted Solutions (0)

Answers (1)

Answers (1)

DellSC
Active Contributor
0 Kudos

This is totally unsupported by SAP, but this is the logic that works.

1.  Get the InfoObject for the report that you want to replace.

2.  Cast the InfoObject as a Report.

3.  Get the path to the physical file from the Report.  NOTE:  You'll have to translate "InputFRS" to the actual path to the FileStore.

4.  Copy the new .rpt file over the top of the old one - this is a FileIO call, not an SDK call.

5.  Call .Refresh() on the Report.

6.  Set the password for the report's data connections.

NOTE:  If you're using BO XI through BO XI 3.1 (versions 11.0, 11.5, 12.0 or 12.5), you WILL have to manually schedule your reports in order to pick up the new version.  For BI 4.0 and newer, any schedules will automatically pick up the new report unless you have made changes to the parameters, in which case you'll have to manually schedule it.

I'm trying to track down some sample code for you.  To get you started with the SDK, there are links to sample code at the top of this forum space.  I also have some sample code on my website:  http://www.dellstinnett.com/sample_code.html

-Dell

Former Member
0 Kudos

Good day Dell, and thanks for the fast answer.

I was developing an small windows form program to go with your approach but when I do login, show me the error:

I've research this error and could be a firewall issue but, the system guys opened for me the ports 6400-6490 and still the same error, here the piece of code that make the connection:


//Log in into CMS

                using (SessionMgr sessionMgr = new SessionMgr())

                {

                    try

                    {

                        string serverCon = string.Concat(txt_server.Text, ":", txt_serverport.Text);                     

                         groupBox_login.Text = "Login Information - Connecting to CMS...";

                        groupBox_login.Refresh();

                        //login

                        _BOSession = sessionMgr.Logon(txt_userid.Text, txt_pwd.Text, serverCon, "secWinAD");

                        //Get the InfoStore Service??

                        _BOService = _BOSession.GetService("InfoStore");

                        //Cast from an EnterpriseService to an InfoStore so we can use it

                        _BOInfoStore = (InfoStore)_BOService;

                        _initialized = true;

                        groupBox_login.Text = "Login Information - Connected to " + txt_server.Text +

                            " User: " + txt_userid.Text;

                        groupBox_login.Refresh();

                        //Disabling text inputs

                        txt_server.Enabled.Equals(false);

                        txt_serverport.Enabled.Equals(false);

                        txt_userid.Enabled.Equals(false);

                        txt_pwd.Enabled.Equals(false);

                        btn_login.Enabled.Equals(false);

                    }

                    catch (Exception ex)

                    {

                        MessageBox.Show(ex.Message, "Login Error", MessageBoxButtons.OK);

                        groupBox_login.Text = "Login Information - Not Connected";

                        groupBox_login.Refresh();

                    }

                }

Our authentication method it's Windows AD, so I researched that I need to use "secWinAD" but not sure.

Also one more doubt: Is there any way to log the connection? I mean maybe a way to catch all the messages in the log in process.

Thanks in advance for any help that you could provide me, your website it's awesome!!

DellSC
Active Contributor
0 Kudos

Hi Sergio,

Sorry it has taken me so long to get back to you - I've been out of the office for several days.

That particular error message indicates that the computer where you're running the app cannot talk to the computer where the CMS is running.  If you're using a cluster name instead of a server name, you'll need to use one of the server names first in order for the registry entries for communicating with the cluster to be set.  After that  you can use the cluster name.

I would also try using the fully qualified name of the server instead of just the server name to see whether that works.  If the server is on a different domain or sub-net, then you must use the fully qualified name (server.domain.com).

Additionally, I would do this using the Administrator id and password with secEnterprise to make sure it's working correctly before you try configuring for AD authentication.  Then you'll have to have the krb5.ini and bsclogin.conf files in c:\windows in order for AD authentication to work correctly.

-Dell