Cannot change FMS locale in Ubuntu

Hello FM Soup !

Has anyone managed to change the FMS locale settings in Ubuntu ?

I have successfully managed to change the system's locale preferences using

sudo locale-gen el_GR.UTF-8

then

sudo update-locale el_GR.UTF-8

and last

dpkg-reconfigure locales

Rebooted the Ubuntu VM and the locale is properly set to Greek as expected. The problem is that FileMaker Server is still on US locale

I am frequently using export records -> import records when copying data among tables, which is obviously going to be a big problem if I don't set the locale properly first.

Any ideas ?

Hello @stathis ,

please state your Ubuntu version as well as FMS version in order for the members to try in a similar environment.

Thanks

Hello @planteg

Valid observation.

FMS: 19.4.2.204
Ubuntu: VERSION="18.04.6 LTS (Bionic Beaver)"

What method are you using to detect the system locale? Get ( SystemLocaleElements )?

Yeap, running on server of course

I'll test on my end and post back here with the results, but that might not be until tomorrow. Did you reboot the server after changing the locale?

1 Like

I ran a quick test, setting the local to de_DE and it seems I can partially reproduce the issue. The language does get changed, but the decimal separator doesn't.

I ran

sudo locale-gen de_DE.UTF-8
sudo update-locale de_DE.UTF-8
localectl set-locale LANG=de_DE.UTF-8 LANGUAGE="de_DE:de"

and then rebooted just in case

after this,

locale -k LC_NUMERIC

returns

decimal_point=","
thousands_sep="."
grouping=3;3
numeric-decimal-point-wc=44
numeric-thousands-sep-wc=46
numeric-codeset="UTF-8"

whereas Get ( SystemLocaleElements ) lists returns LocaleID.IDStr = German but Num.Decimal is still "."

{
   "APIVers" : 1,
   "Currency" : 
   {
   	"Leading" : true,
   	"Symbol" : "$"
   },
   "Date" : 
   {
   	"DMQ" : 
   	{
   		"1stDayOfWeek" : 1,
   		"DaysOfWeek" : 
   		{
   			"AbbrvList" : 
   			[
   				"Sun",
   				"Mon",
   				"Tue",
   				"Wed",
   				"Thu",
   				"Fri",
   				"Sat"
   			],
   			"NameList" : 
   			[
   				"Sunday",
   				"Monday",
   				"Tuesday",
   				"Wednesday",
   				"Thursday",
   				"Friday",
   				"Saturday"
   			]
   		},
   		"Months" : 
   		{
   			"AbbrvList" : 
   			[
   				"Jan",
   				"Feb",
   				"Mar",
   				"Apr",
   				"May",
   				"Jun",
   				"Jul",
   				"Aug",
   				"Sep",
   				"Oct",
   				"Nov",
   				"Dec"
   			],
   			"NameList" : 
   			[
   				"January",
   				"February",
   				"March",
   				"April",
   				"May",
   				"June",
   				"July",
   				"August",
   				"September",
   				"October",
   				"November",
   				"December"
   			]
   		},
   		"Quarters" : 
   		{
   			"AbbrvList" : 
   			[
   				"Q1",
   				"Q2",
   				"Q3",
   				"Q4"
   			],
   			"NameList" : 
   			[
   				"1st Quarter",
   				"2nd Quarter",
   				"3rd Quarter",
   				"4th Quarter"
   			]
   		}
   	},
   	"DateNums" : 
   	{
   		"0d" : false,
   		"0m" : false,
   		"YYyy" : true
   	},
   	"DateOrderID" : 0,
   	"DateOrderName" : "MDY",
   	"MDY" : 
   	{
   		"ElementArray" : 
   		{
   			"NameList" : 
   			[
   				"M#",
   				"D#",
   				"D$",
   				"D$"
   			],
   			"SepList" : 
   			[
   				" ",
   				" ",
   				", ",
   				""
   			]
   		},
   		"MustUseLocalesSep" : false
   	},
   	"Sep" : "/"
   },
   "LocaleID" : 
   {
   	"IDNum" : 25,
   	"IDStr" : "German",
   	"ISOLangCode" : "de",
   	"LID" : "German",
   	"Name" : "German"
   },
   "Misc" : 
   {
   	"Active" : true,
   	"Metric" : false
   },
   "Num" : 
   {
   	"1000s" : ",",
   	"Decimal" : ".",
   	"Lead0" : true
   },
   "Text" : 
   {
   	"SQuotLead" : "“",
   	"SQuotTrail" : "”",
   	"Sep" : ","
   },
   "Time" : 
   {
   	"12h" : true,
   	"HMS" : 
   	{
   		"0h" : false,
   		"24h" : "",
   		"Seconds" : false
   	},
   	"NightDay" : 
   	{
   		"12hSuffix" : true,
   		"amStr" : " AM",
   		"pmStr" : " PM"
   	},
   	"Sep" : ":"
   }
}

Does FMS support Greek?

Yes it does.

I also tried en_GB and German, just to exclude the Greek language

At this moment I just want to know if anyone has managed to get other than US locale in a Linux installation, so no need to focus on the language.

Nice one, never noticed the LocaleID.IDStr, will check now to check whether I get the same result

How did you change the locale ? Even for the LocaleID.IDStr ?

I am getting the same with el_GR locale. Should I try another locale ?

{
	"APIVers" : 1,
	"Currency" : 
	{
		"Leading" : true,
		"Symbol" : "$"
	},
	"Date" : 
	{
		"DMQ" : 
		{
			"1stDayOfWeek" : 1,
			"DaysOfWeek" : 
			{
				"AbbrvList" : 
				[
					"Sun",
					"Mon",
					"Tue",
					"Wed",
					"Thu",
					"Fri",
					"Sat"
				],
				"NameList" : 
				[
					"Sunday",
					"Monday",
					"Tuesday",
					"Wednesday",
					"Thursday",
					"Friday",
					"Saturday"
				]
			},
			"Months" : 
			{
				"AbbrvList" : 
				[
					"Jan",
					"Feb",
					"Mar",
					"Apr",
					"May",
					"Jun",
					"Jul",
					"Aug",
					"Sep",
					"Oct",
					"Nov",
					"Dec"
				],
				"NameList" : 
				[
					"January",
					"February",
					"March",
					"April",
					"May",
					"June",
					"July",
					"August",
					"September",
					"October",
					"November",
					"December"
				]
			},
			"Quarters" : 
			{
				"AbbrvList" : 
				[
					"Q1",
					"Q2",
					"Q3",
					"Q4"
				],
				"NameList" : 
				[
					"1st Quarter",
					"2nd Quarter",
					"3rd Quarter",
					"4th Quarter"
				]
			}
		},
		"DateNums" : 
		{
			"0d" : true,
			"0m" : true,
			"YYyy" : true
		},
		"DateOrderID" : 0,
		"DateOrderName" : "MDY",
		"MDY" : 
		{
			"ElementArray" : 
			{
				"NameList" : 
				[
					"M#",
					"D#",
					"D$",
					"D$"
				],
				"SepList" : 
				[
					" ",
					" ",
					", ",
					""
				]
			},
			"MustUseLocalesSep" : false
		},
		"Sep" : "/"
	},
	"LocaleID" : 
	{
		"IDNum" : 21,
		"IDStr" : "English",
		"ISOLangCode" : "en",
		"LID" : "English",
		"Name" : "English"
	},
	"Misc" : 
	{
		"Active" : true,
		"Metric" : false
	},
	"Num" : 
	{
		"1000s" : ",",
		"Decimal" : ".",
		"Lead0" : true
	},
	"Text" : 
	{
		"SQuotLead" : "“",
		"SQuotTrail" : "”",
		"Sep" : ","
	},
	"Time" : 
	{
		"12h" : true,
		"HMS" : 
		{
			"0h" : true,
			"24h" : "",
			"Seconds" : false
		},
		"NightDay" : 
		{
			"12hSuffix" : true,
			"amStr" : " AM",
			"pmStr" : " PM"
		},
		"Sep" : ":"
	}
}

Hi @stathis,

I just tested with Greek myself, and it did not work the same as German. Ubuntu command line "locale" show that Greek is the system language for Ubuntu, but Get ( SystemLocaleElements ) still lists English.

I can speculate that in reality, FileMaker Server may not actually handle all locales for Get ( SystemLocaleElements ), only for languages into which FileMaker Server has been localized.

I've done a few different quick tests of how Get ( SystemLocaleElements ) actually works, not just on Linux and not just on Server, and I have seem some other signs that it does not actually always work the way at least I would suspect. At this point, I don't really have a pressing need to figure this out myself, so I am not going to spend that time on it, but I have seen indications that might mean that Get ( SystemLocaleElements ) may in reality not always "mean" the language of the operating system.

Perhaps more important from a short-term practical point of view, I am not sure what the reason would be for you to need to have Get ( SystemLocaleElements ) on the server set to Greek. Or in any case, there may be other ways of getting the end result you are looking for. That is probably a separate discussion.

Hello @CamelCase !

Thank you for your time testing it.

The reason behind it is the .mer export and number format. In Greek locale .mer uses semicolon as a separator and number thou is dot, decimals is comma.

I have used a lot of export / import which would mean I would need to check all files !

All the above has been reported to Claris, thank you for your help

Best
Stathis

I normally rely on File options > Data Entry: Always use file's save settings to control this.
Though more often than not, I won't even necessarily use the built-in import/export script steps, but rather script the whole thing myself. Unless very many records are involved, I sacrifice performance and easy of programming to get better control.

If you have a lot of FileMaker files, you can more or less automate the checking by using Save a Copy as XML and then parsing the File Options information by parsing the XML.
Relying on each individual file's settings is certainly far from perfect, but given what we have to work with right now, it may still be the least painful/most reliable option...

Yeap, especially now that the Save File As XML is supported in server.

When applicable, I always prefer the export/import records on server, the performance is just unparalleled.

There are so many aspects that server locale is involved: Data API, ODBC, text representation of dates or numbers.

I am very positive this will be fixed soon enough