Navision SQL Option and MSDE

Has anyone had Navision working with MSDE ? I have tried and keep getting a CODEPAGE error. Any hints would be appreciated. Chris.

Navision Financials uses OEM code pages internaly (i.e. the OEM code page set up for your client computer). When communicating character data with SQL Server it must perform OEM/ANSI conversions if the SQL Server database is using a sort order based on an ANSI code page. It is therefore important that client computers are using a code page that match SQL Server’s; either the OEM code page or ANSI code page. If they do not match, these conversions will not work. (Note also that only OEM will match OEM and ANSI will match ANSI. It is never true that OEM matches an ANSI code page). So, Financials checks that your client computer OEM or ANSI code page matches the database. If not, you will get a code page error. (If the code page in the error is 0 rather than a valid code page like 850, then you are trying to run against SQL Server 2000 with a version of Financials prior to 2.6C - you then need at least 2.6C). For example, your SQL Server 7.0 server (or SQL Server 2000 database) is using a sort order based on cp1252, which is an ANSI code page). Your client is using ANSI cp1250, and OEM cp850. Neither the client’s OEM or ANSI code page matches the server’s, so you will get the error. You have two options: change the server (or database) code page on the server, or change your client code page, depending on which is ‘wrong’. Since code pages determine character sets, and character sets are based on language, then your country will use a particular code page, and therefore your computer will follow that. E.g, 1252 for most western europe contries. Or 1250, 1251, 1253 etc for other european countries. This is set, for Windows NT and 2000 in the Regional Settings under the SET DEFAULT option (NOT the locale option). Under 98 it is in config.sys. If your machine is OK then your server needs changing: for 7.0 this means re-installing or rebuilding the master DB, for 2000 it might mean just creating a new database with the correct code page.

Thanks for the reply, I understand the problem now. However, I dont feel comfortable changing the code page of my client machine as it is the default for my locale (UK). I have tried creating a new database in SQL 2000 and getting Navision to use it, but I just get the same error. Navision is Version 2.6e The thing I don’t get is, that Navision and MSDE are running on the same machine, so arn’t the same code pages in effect ? Or does MSDE use it’s own default codepage, and if so how do you change the default ?? Regards Chris. download

OK, you’re using SQL Server 2000. That means there is a default (i.e. server) sort order which is defined by you at installation time, using the Collation dialog in the installation wizard. But you have to choose Custom installation to have access to this, otherwise the installation program will choose a default sort order based on your current regional settings. You have to re-install the server in order to change the default code page (the code page is part of the Collation, i.e. Sort Order). Your error message says that the code page is 1252, and this is referring to the default server code page. This code page is independent of the machine’s code page on which SQL Server is installed. SQL Server controls the character sets, code pages and sort orders for all its character data, and can use all available code pages for its databases. Navision Financials will create all its databases on that server with the same code page as the server default code page (in your case 1252), although SQL Server 2000 supports the creation of databases with different code pages (from Navision Attain onwards, this functionality is exploited when creating a database). The only way to get things working is to ensure that the server has been installed with a code page that matches all client computers that will connect to it. However, to me, 1252 seems like the correct code page that your computer should be using for the UK (along with OEM 437, but that doesn’t matter here) - in which case your server is set up ok - so I am doubting that your computer has the correct code page. Try the attached program to see what your code pages are. ANSI must be 1252 in order to access your server. download

Once again, thanks for the help. The codepage program reports that I have OEM 437 and ANSI 1252. I am not using SQL SERVER 2000 I am using MSDE (a small versin of SQL SERVER 2000) ? When installing, there is no custom option route to take! Regards Chris.

The Desktop Engine is an edition of SQL Server 2000, and exists prior to that, but is a much cut down version of it. Your problem may simply be the use of this rather than a proper edition of SQL Server. I can otherwise see no problem with your code pages. I think that Navision Financials supports and is tested against the Personal, Standard and Enterprise editions of SQL Server. You could try to verify that you can use such an edition successfully.

Topic moved from “Open Subject” not Attain/Financials Technical Forum.

From a production standpoint only the Standard and Enterprise are supported.

OEM or Ansi… Running SQL Server 2000 on a W2K we are not able to connect if the client has any Windows Version /Thai enabled installed. Even if we change the codepages it will not work. We HAVE to install a Windows Version without Thai. (That’s Microsoft, isn’t it (or you can say: Hey, that’s Thailand)) Regards Walter

I think I have tried just about every combination of codepages etc etc. Still no luck. I guess the two just don’t go, back to SQL7 for me then! Cheers Chris.

What is the code page on the client with Thai enabled - is it 874? The program in the download of my previous post should tell you for sure. I am interested in where the conflict is in this situation.

Robert, Win98 and ME: OEM 874 Ansi 874 W2K Workstations: OEM 437 Ansi 1252 Codepage Error was 150x where x=something. I cannot remember, but If you want I can do it again. When Tai enabled, we CANNOT change the codepage. Regards Walter

Walter, If your server default code page is any of 874, 1252 or 437 then you should be able to connect from a Navision Financials client when it has an oem or ansi code page that matches. Get the server code page by issuing in Query Analyzer:


SELECT COLLATIONPROPERTY(CAST(DATABASEPROPERTYEX('master', 'Collation') AS NVARCHAR(128)), 'CodePage')

The code page error that Financials gives does not include an error number (just a code page ID), so I don’t know what error you are referring to with 150x. Is Financials giving this error, and if so, when?

I am almost sure that navision SQL will not work with MSDE, I have tried but not very hard! But Navision does work with SQL 2000 personal edition. MSDE is a SQL 7.0 Server which came with office 2000 and various microsoft development platforms. You would normally install it on the same computer that Navision is running on so the code pages don’t come into it (I don’t think that MSDE could use a different codepage than the computer it is running on). The replacement for MSDE is SQL 2000 personal edition. Paul Baxter

Well I installed MSDE from my SQL SERVER 2000 cd.

Yes you are right it is on the SQL 2000 CD isn’t it. Looking it up MSDE can be distributed royalty free while you must have the required software licenses to use SQL Server. Paul Baxter

Well to keep you all upto date, I have deinstalled everything! I have made sure that the codepage utility offered for download earlier in this post is reporting codepage OEM 850 and ANSI 1252. I have reinstalled MSDE. I have reinstalled SQL SERVER Enterprise Manager and other Client tools. I have reinstalled Navision with SQL Option. Then I have tried it again to see if it works and guess what !!! It don’t. For any of you that may have missed it, look at the screen shot i left for download earlier in this port. Regards As always