cancel
Showing results for 
Search instead for 
Did you mean: 

Problems using RecordSet Object in SBO 2004

Former Member
0 Kudos

Hi,

When of one of our testers runs any code that uses the RecordSet object, they always get a null object when reading the record results. The code is:

string Query = string.Format("SELECT COUNT(TABLE_NAME) TOTAL FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_TYPE = 'BASE TABLE' " +

"AND TABLE_NAME = ''", TableName);

int result = 0;

IRecordset RS = (IRecordset)BaseUI.oCompany.GetBusinessObject(BoObjectTypes.BoRecordset);

RS.DoQuery(Query);

if (RS.RecordCount > 0)

{

RS.MoveFirst();

result = (int)RS.Fields.Item("TOTAL").Value; //problem is here, it is always null for our tester

}

The returned results in the RS object are always null.

However I can run the code on my computer without any problems. We are not running the add-on as a registerd add-on as we are still in the midst of testing.

Has anyone else experienced similar problems or know of the cause or a solution?

Lita

Message was edited by: Lita Teng

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Are you using the same user? The access mode, in sqlserver, is the same as your machine?

Ribeiro Santos

Former Member
0 Kudos

Yes, we're using the same SAP user, "manager" and the same Sql Server access mode, mixed mode.

Answers (0)