Bug 139467 - Calc: Data->Refresh Range fails if query (Base) has been inserted with user interface language set to German
Summary: Calc: Data->Refresh Range fails if query (Base) has been inserted with user i...
Status: ASSIGNED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
26.2.0.0 alpha0+ master
Hardware: All All
: medium normal
Assignee: dcbw@libreoffice.org
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Database-Queries
  Show dependency treegraph
 
Reported: 2021-01-07 12:00 UTC by Martin
Modified: 2026-01-24 10:37 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin 2021-01-07 12:00:38 UTC
Description:
Have created a couple of queries with Base and saved in a odb document. Query does work (source is local PostgreSQL database). Query is inserted into Calc document. Table with current values is in Calc document. Calc fails with error "Die Schnittstelle X..." (english ...) if query has been inserted with language interface language set to german.

Steps to Reproduce:
1. Set user interface language to German. Restart LibreOffice
2. Create query with Base, save in document.
3. Open Calc document.
4. Choose query from Base document from Ctrl-Shift-F4 and drag into Calc document.
5. Check Menu Data, item Refresh Range (German menu "Bereich aktualisieren")

Actual Results:
If user interface is set to German, updating (Daten->Bereich aktualisieren) fails with "Die Schnittstelle XQueriesSupplier ist nicht verfügbar."

If user interface is set to "English (USA)" and a Calc document is opened with a query inserted with german user interface activated, Data->Refresh Range raises error "The interface XQueriesSupplier is not available."

Expected Results:
Inserting Base queries into Calc documents should work with different user interface language setting than "English (USA)".


Reproducible: Always


User Profile Reset: No



Additional Info:
Workaround: insert query into Calc document while English user interface language activated and save file.
Comment 1 dcbw@libreoffice.org 2025-12-02 18:42:01 UTC
Reproduced with 26.2.0.0.alpha0+ (Mac x86).
Comment 2 dcbw@libreoffice.org 2025-12-06 17:31:42 UTC
I'm not sure this is related to the language issue so much as Calc just failing to re-load a database query that refers to a local database file. At least, that's what I tracked down when looking at this bug.

See https://gerrit.libreoffice.org/c/core/+/195173 for a fix.
Comment 3 Hossein 2025-12-16 13:59:21 UTC
@Martin
@Dan

Please always copy the LibreOffice version information from "Help > About". This is important in both filing bugs and reproducing them.

What I see now is:

Version: 25.8.3.2 (X86_64)
Build ID: 8ca8d55c161d602844f5428fa4b58097424e324e
CPU threads: 20; OS: Windows 11 X86_64 (build 26200); UI render: Skia/Vulkan; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: CL threaded

As you can see, there are 3 important locale information here. Application locale, system locale and system UI.
Comment 4 Martin 2025-12-17 19:49:31 UTC
I can still reproduce the error. Here is version info:

Version: 25.2.7.1 (X86_64) / LibreOffice Community
Build ID: 520(Build:1)
CPU threads: 4; OS: Linux 6.4; UI render: default; VCL: gtk3
Locale: de-DE (de_DE.utf8); UI: de-DE
Calc: threaded
Comment 5 dcbw@libreoffice.org 2025-12-18 15:09:57 UTC
This was my repro procedure:

1) create a new Base file backed by a postgresql database (like the bug)
2) make a simple table with a couple rows
3) create a “SELECT * FROM <table>” kind of SQL query
4) drag that query from the Base window into Calc
5) add a row to the database from the Base window
6) refresh the query in calc and make sure the new row shows
7) save the Calc and Base files
8) quit
9) re-run LO and re-open the Calc file
10) click one of the filled cells
11) refresh the data query from the menus; see the "The interface XQueriesSupplier is not available." error
Comment 6 Hossein 2026-01-08 09:21:55 UTC
I still can not reproduce the issue with both latest LO stable and master:

PostgreSQL 9.11

Version: 25.8.4.2 (X86_64)
Build ID: 290daaa01b999472f0c7a3890eb6a550fd74c6df
CPU threads: 12; OS: Linux 6.2; UI render: default; VCL: gtk3
Locale: de-DE (en_US.UTF-8); UI: en-US
Calc: threaded

Version: 26.8.0.0.alpha0+ (X86_64)
Build ID: 368ae459417fc11b6ef232e43fa3e805dc0095d6
CPU threads: 12; OS: Linux 6.2; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: CL threaded

Nor with German language:

Version: 25.8.4.2 (X86_64)
Build ID: 290daaa01b999472f0c7a3890eb6a550fd74c6df
CPU threads: 12; OS: Linux 6.2; UI render: default; VCL: gtk3
Locale: de-DE (de_DE); UI: de-DE
Calc: threaded

Version: 26.8.0.0.alpha0+ (X86_64)
Build ID: 368ae459417fc11b6ef232e43fa3e805dc0095d6
CPU threads: 12; OS: Linux 6.2; UI render: default; VCL: gtk3
Locale: de-DE (de_DE); UI: de-DE
Calc: CL threaded
Comment 7 Hossein 2026-01-08 12:45:49 UTC
@Martin:
Is it possible for you to test Dan's patch?

If you can not build the patch from sources, the alternative way to verify the fix is to test the patch after it gets merged, with nightly builds.

(In reply to dcbw@libreoffice.org from comment #2)
> I'm not sure this is related to the language issue so much as Calc just
> failing to re-load a database query that refers to a local database file. At
> least, that's what I tracked down when looking at this bug.
> 
> See https://gerrit.libreoffice.org/c/core/+/195173 for a fix.
Comment 8 Buovjaga 2026-01-08 14:58:09 UTC
I can't reproduce the issue with PostgreSQL 18.1.

Version: 26.8.0.0.alpha0+ (X86_64)
Build ID: 55b9b552c8eaf28a9d567d2168c98c2ea4b9c2cf
CPU threads: 8; OS: Linux 6.18; UI render: default; VCL: gtk3
Locale: fi-FI (fi_FI.UTF-8); UI: de-DE
Calc: CL threaded

The repro steps were missing info on how to set up PostgreSQL, so I am adding them. I used these as guidance mainly:
https://wiki.archlinux.org/title/PostgreSQL
https://linuxgenie.net/install-postgresql-psql-arch-linux/

sudo pacman -S postgresql
sudo su postgres
initdb -D /var/lib/postgres/data
systemctl start postgresql.service
psql
CREATE USER myuser WITH ENCRYPTED PASSWORD 'mypass';
CREATE DATABASE mytestdb OWNER myuser;

You can list databases in the psql prompt with `\l`, list roles with `SELECT rolname FROM pg_roles;`, delete a user with `drop role myuser;`, drop a database with `DROP DATABASE mytestdb WITH (FORCE);`

In Base, when setting up the PostgreSQL connection use localhost for the server.
Comment 9 Martin 2026-01-10 08:22:03 UTC
(In reply to Hossein from comment #7)
> @Martin:
> Is it possible for you to test Dan's patch?
> [...]

How to get the patch? I'm on SuSE Linux LEAP 15.6.
Comment 10 Hossein 2026-01-12 11:57:20 UTC
(In reply to Martin from comment #9)
> (In reply to Hossein from comment #7)
> > @Martin:
> > Is it possible for you to test Dan's patch?
> > [...]
> 
> How to get the patch? I'm on SuSE Linux LEAP 15.6.
First, you should be able to build LibreOffice from sources. Instructions are here:

Development/BuildingOnLinux
https://wiki.documentfoundation.org/Development/BuildingOnLinux

This is Dan's patch:

tdf#139467 correctly handle DatabaseLocation for Calc cell ranges
https://gerrit.libreoffice.org/c/core/+/195173

Then, you can download the patch using 'git review'. There are also other ways, but 'git review' seems to be one of the easiest methods:

$ git review -d 195173

Then, you can build again and test:

$ make
$ instdir/program/soffice