cancel
Showing results for 
Search instead for 
Did you mean: 

Database server type not supported

Former Member
0 Kudos

Hi experts,

I'm having problem with a Web Service which execute DI API commands.

During the initial company.connect I'm using the following basic code:

oCompany = New SAPbobsCOM.Company

oCompany.DbServerType = SAPbobsCOM.BoDataServerTypes.dst_MSSQL2008

oCompany.LicenseServer = "ServerName:30000"

oCompany.Server = "ServerName:30000"

oCompany.CompanyDB = "DBName"

oCompany.DbUserName = "SA"

oCompany.DbPassword = "password"

oCompany.UserName = "manager"

oCompany.Password = "password"

oCompany.UseTrusted = False

dConnInt = oCompany.Connect

If dConnInt <> 0 Then

  oCompany.GetLastError(errcode, erMsg)

End If

It is working just fine in one server.

However when I try to migrate to another server, it always returns ErMsg 'Database server type not supported'.

I have tried to install SQL 2008 R2 Native Client and the DIAPI, but the error remains.

I also have compared the installed "program and features" between the existing and the new server, all identically the same.

Have anyone encounter the same issue? Please advise what should I do to resolve this.

Thanks

Best Regards,

Krisma

Accepted Solutions (1)

Accepted Solutions (1)

maik_delly
Active Contributor
0 Kudos

Hi Krisma,

which DI API Version are you using ( old & new server ) ? My first idea would be, that you have an older version on the new machine, which doesn't support MSSQL 2008 yet.

regards,

Maik

Former Member
0 Kudos

Hi Maik,

DI API that I'm using is SAP 9.0 PL09. I tried to re-install the DI API in the new server, even tried to install the SAP Client. The SAP Client can connect to the Company, but the DI API connection from the web service keep prompting the same issue.

Best regards,

Krisma

maik_delly
Active Contributor
0 Kudos

Hi Krisma,

can you please try the connect without sending DbUserName+DbPassword

oCompany = New SAPbobsCOM.Company

oCompany.Server = "ServerName"

oCompany.DbServerType = SAPbobsCOM.BoDataServerTypes.dst_MSSQL2008

oCompany.CompanyDB = "DBName"

oCompany.LicenseServer = "ServerName:30000"

oCompany.UserName = "manager"

oCompany.Password = "password"

dConnInt = oCompany.Connect

regards,

Maik

edy_simon
Active Contributor
0 Kudos

Hi Krisma,

Not sure if this is related to your problem.

When installing DI API 32 bit, you will get a folder called \SAP\SAP Business One DI API\DI API 89

When referencing this SAPbobsCOM89.dll, and connecting using the stand alone DI API, I always get this error 'Database Server type not supported.'

Just make sure you are not referencing this SAPbobsCOM89.dll

Regards

Edy

Former Member
0 Kudos

Hi Edy,

In my case, the reference is not being taken from that folder, but it is taken from the Development PC.

Some update to the issue, I have tested to do the following and they are working:

-. SQL connection (not DIAPI connection) via Web Service.

-. DI API connection using the same code, but compile the program as .exe instead of web service.

-. DTW can do the connection.

I believe it indicates that the issue lies with DIAPI connection via Web Service.

Any idea, anyone? I have been checking lot of reference but cannot find anything useful yet.

Best regards,

Krisma

Former Member
0 Kudos

Hi Krisma,

I had a similar case like you and the solution was related to IIS. Like in your case, everything works fine in case when I used a console application to connect to DI API, but through web service I had always the error - "Database server type is not supported".

This is the solution that works in our case:

1. Go to IIS->Application pools

2. Rigth click on your service->Advanced settings

3. Go to Identity->Choose a custom account->add an administrator account

4. Go to Load User Profile-> set True

5. Restart IIS

Regards,

Ion Gritco

Former Member
0 Kudos

Thank you! You solved my problem too!

Former Member
0 Kudos

Thank you.

You are a life saver

ANKIT_CHAUHAN
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi All,

Refer to SAP Note 2207964 which describes the same.

Kind regards,

ANKIT CHAUHAN

SAP Business One Global Support

Answers (3)

Answers (3)

Former Member
0 Kudos

oCompany = New SAPbobsCOM.Company

oCompany.DbServerType = SAPbobsCOM.BoDataServerTypes.dst_MSSQL2008

oCompany.LicenseServer = "ServerName:30000"

oCompany.Server = "ServerName:30000" <--- You don't need to put the PORT 30000. Ex : "localhost"

oCompany.CompanyDB = "DBName"

oCompany.DbUserName = "SA"

oCompany.DbPassword = "password"

oCompany.UserName = "manager"

oCompany.Password = "password"

oCompany.UseTrusted = False <--- "By default this method is set to false"

dConnInt = oCompany.Connect

If dConnInt <> 0 Then

  oCompany.GetLastError(errcode, erMsg)

End If

Regards,

Former Member
0 Kudos

Hi Bryan,

Sorry for the misdirection, I did put the source code only to highlight how common is my company.connect method. However this code works fine in the existing server, the issue only happens when I try to deploy the web service to a new server.

Any clue?

Thanks,

Krisma

ANKIT_CHAUHAN
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Krisma,

Check the SQL Server Versions on both the servers. I hope there is some version mismatch thats why you are getting the error.

Hope it helps.

Thanks & Regards

Ankit Chauhan

Former Member
0 Kudos

Hi Ankit,

Seems like you suggest the same idea with Johan to install SQL Server, actually I did not install SQL Server in the old server and I never had this issue.

Thanks and regards,

Krisma

Johan_H
Active Contributor
0 Kudos

Hi Krisma,

The error refers to the actual database version, not the sql native client.

Please check that the SQL Server version is 2008 on both servers.

Regards,

Johan

Former Member
0 Kudos

Hi Johan,

Do you suggest to install SQL Server 2008 in the Web Server?

Actually I did not install the SQL Server in the old/existing server but this error never come out. It only happen when I try to deploy the Web Service in this new server.

Regards,

Krisma

Johan_H
Active Contributor
0 Kudos

Hi Krisma,

Okay, I misunderstood your question.

Do you mean that there is a third server containing the B1 database, and that you are only trying to migrate the web service ?

Regards,

Johan

Former Member
0 Kudos

Hi Johan,

Let me elaborate more on the situation.

Server A : SAP Server and Database Server

Server B : Existing Web Server where the web service is working properly.

Server C : New Web Server where I'm trying to deploy the same web service from Server B.

The issue only happen in Server C, while as far as I checked, the IIS setting and the 'Program and Features' are identical between server B and C.

Best regards,

Krisma

Johan_H
Active Contributor
0 Kudos

Okay, I see. In that case the error does appear to refer to the SQL client version on server C.