Set JRE in LibreOffice

Good morning
I recently upgraded to 6.0.4.

In recent versions a java runtime environment was set up automatically or I did that manually.
For example on a Windows 7 notebook
-> tools - options - libreoffice - advanced -> Java options
location: C:\Program Files\Java\jre xxx

However in 6.0.4 the Java options box is empty and when I try to add the jre:
location (Windows 10): C:\Program Files(x86)\Java\jre xxx

I get the error message:
"The folder you selected does not contain a Java runtime environment. Please select a different folder."

Actually there are TWO jre versions, both cause the same error message.
The Java version on the computer is the newest one available.

Is there a trick to it, or does 6.0.4 does not use JRE any more?
Thank you.
Thomas

Hi Thomas,

which version of LO do you use? 64bit or 32bit? You need Java 32bit for
LO 32bit and Java 64bit for LO 64bit.

Regards

Robert

I am currently talking about a 64-bit Windows 10 machine where also LO is 64-bit.
However, over the last 10+ years I NEVER needed to specify that during setup.
Nor during the installation of Java.
The Java website allows you download the newest version, but does NOT ask about 32/64-bit installation.
(I presume it detects that automatically)
Am I missing something important here?
Thomas

Hi Thomas,

The Java website allows you download the newest version, but does NOT
ask about 32/64-bit installation.
(I presume it detects that automatically)

No, it seems it doesn't. I haven't any Windows running here, but heard a
lot of wrong Java for LO, because 64bit and 32bit problem. Seems the
automatic download of Java mostly installs 32bit-Java.

Have a look here for Java for 64bit and try:
https://www.java.com/de/download/manual.jsp

... it isn't /de for you, but you have to search for "All Java downloads".

Regards

Robert

hello.
i read somewhere that libreoffice 64 bit and 32 bit both supports java
32 bit version.
i recommend you that download java 32bit and test it that does it
resolve your issue.
however, thanks God, java is required only for base and other
applications and features of libreoffice, dont need java.

I keep seeing this fallacy of "only Base requires Java" repeated in this forum and so this is to keep the record straight. This may not be true, unless LO has changed in this area from 5.2.7. I can no longer test it. Options also seem to need Java. When I was having problems with LO Base crashing after a Linux Kernel security update which turned out to affect Java, I tried to use a tools config or two and some crashed the same way - implying they also used Java. IIRC, it was when I clicked on Internet > MediaWiki. So there may be other areas of LO in addition to Base that seem to use Java.

I remember a while back, LO was making an effort to remove Java requirements. Some progress to that end has been made over the years, but I suspect there are still some threads connecting LO to Java, besides Base.

Girvin Herr

Hi Zarah,

i read somewhere that libreoffice 64 bit and 32 bit both supports java
32 bit version.

This is a wrong information. We have a lot of trouble with
Windows-users, who didn't realize 64bit Java is needed for 64bit LO.
There are many people in mailinglists, also in bugtracker reporting this
problem. Seems to be only a Windosw-problem. Linux will install the
right Java-version by default.

You are right, this is a problem for people using Base. If you don't
need Base (and, for example, serial letters in Writer) you don't need to
install the right Java for LO.

Regards

Robert

Hello Girvin,

I remember a while back, LO was making an effort to remove Java
requirements. Some progress to that end has been made over the years,
but I suspect there are still some threads connecting LO to Java,
besides Base.

It is only the internal HSQLDB-database (Java), which will be removed in
some years. Next LO-version will support an automatic migration to the
new internal Firebird-database.

The report-builder, for example, does need Java also - and won't work
without.

Regards

Robert

Hi :slight_smile:
That is interesting about the Windows versions of LibreOffice being a bit
different from the Gnu&Linux! I've always thought they were pretty much
identical. However this is not the first time that i've heard of
differences so it's probably not just a case of Gnu&Linux being smarter at
installing stuff.

Also i've thought that 32bit tools work fine in 64bit environments. I
guess that now 64bit is so much the mainstream it is 32bit things that can
increasing expect quirkiness when there is a 64bit version available.

I vaguely remember some stat that 99% of java in LO has been converted to
Python or other languages but that leaves 3rd party Extensions and the
in-built hsqldb back-end in Base and very little else needing java.

Base is supposed to MUCH better when using an external back-end - it's what
Base was originally designed for and it's where Base beats Access.
Annoyingly that seems to be a little known fact that doesn't get picked up
on by people marketing LO. Oddly hsqldb as an external back-end (ie
installing the most recent version into the OS and getting it from the
hsqldb project themselves, instead of using the old twisted version
hard-coded into LO) tends to be quite fantastic - but it is totally
dependent on Java and Java is a nightmare. So the move away from the
twisted old version of hsqldb to firebird is great news.

As for 3rd party Extensions these are often written as freeware rather than
as Free Software so there are often licensing issues and problems getting
hold of the source-code. There are/were some really nice Extensions that
have been lost due to lack of maintenance and become out-of-date. Usually
the dev(s) involved are quite happy to re-release under a GPL or LGPL
license so that other people can keep their code up-to-date but it's often
very difficult to get hold of the dev to ask them.

I'm not sure where else Java is used in LO. It's annoying that it seems to
be needed for MediaWiki. Somewhere there used to be a table and pie-chart
showing all the different languages used in LO but i haven't looked for it
lately. I think it was almost all C, C++ and Python last time i looked.

This has been an interesting thread for me. It seems quite a bit has
changed over the years and it has been interesting to hear from people who
know the current situations :slight_smile:
Thanks and regards from
a Tom :slight_smile:

Hello Girvin,
>
> I remember a while back, LO was making an effort to remove Java
> requirements. Some progress to that end has been made over the years,
> but I suspect there are still some threads connecting LO to Java,
> besides Base.

It is only the internal HSQLDB-database (Java), which will be removed in
some years. Next LO-version will support an automatic migration to the
new internal Firebird-database.

The report-builder, for example, does need Java also - and won't work
without.

Regards

Robert
--
Homepage: http://robert.familiegrosskopf.de
LibreOffice Community: http://robert.familiegrosskopf.de/map_3

--
To unsubscribe e-mail to: users+unsubscribe@global.libreoffice.org
Problems?

https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/

Hi :slight_smile:

Snip

Base is supposed to MUCH better when using an external back-end - it's what
Base was originally designed for and it's where Base beats Access.
Annoyingly that seems to be a little known fact that doesn't get picked up
on by people marketing LO. Oddly hsqldb as an external back-end (ie
installing the most recent version into the OS and getting it from the
hsqldb project themselves, instead of using the old twisted version
hard-coded into LO) tends to be quite fantastic - but it is totally
dependent on Java and Java is a nightmare. So the move away from the
twisted old version of hsqldb to firebird is great news.

Snip

Hi Tom,
History lesson as I remember it: I suppose OO/AOO/LO wanted a built-in database engine to better compete with Access, which had the Jet engine built-in. Choosing hsqldb must have had its reasons back then. Going back before OO, StarOffice had its own built-in database engine, Adabase D, but I never could get it to work. (Granted, I was a database newbie back then and my problems may not have been StarOffice's fault.) I was glad to get OO (back then) working with MySQL about 2005. BTW: I think there was a crude and circuitous way to get Access 1.1 to talk to an external database server via a "connector" system. But I never tried to do it before I converted my databases to MySQL and never looked back.

My experience: I have always used LO with MySQL as my backend (aka server) with the Java connector between them. Actually, I am now using Mariadb, as this is what Slackware Linux distributes now. I have not had any problems with my database system, after the initial configuration learning curve. It works. Therefore, hsqldb and now the proposed switch to the firebird backend are a non-issue for me, as long as LO will continue to support the external server paradigm. But that is me. Others may require the built-in engine paradigm.

For years, LO, has been reporting an imminent built-in (aka "native") support for MySQL so that the Java connector is no longer needed. However, that functionality seems to be another myth.

Girvin Herr

Hi Girvin,
The same as you I have used MySQL/MariaDB with OO/LO for at least a decade. Before that
I looked after DB2 (Mainframe...) as an IBM-Systems Engineer. I also cave been using the
JDBC-connector happily. One of the problems I encountered with the "native" connector
was the absence of a capability to reconnect to my remote server after an activity timeout
occurred (the server would allow me to increase the timeout specified).
In any case - I feel that a connection to an external database server should continue to be
available. One reason - databases in enterprises tend to be used by more than just ONE
application system...
Just my two cents worth...
Regards from Salzburg
H. Stoellinger

Hi *,

I 'm using the internal database for deveopement of databases, with
pupils in scool and for some little projects, which only need a
standalone-database. For "normal" use I also prefer MariaDB. The native
driver had some (little) problems here so I switched to JDBC. I am using

jdbc:mysql://«hostname»:3306/«databasename»?autoReconnect=true

to connect to MariaDB and don't loose the connection to the server.

Problem for MariaDB/MySQL: You have to know much about SQL or you must
create the tables with PHPMyAdmin or something else for using
Innodb-tables and create relationships between them.

Regards

Robert

Hi :slight_smile:
Access can be forced into using an external database and some people claim
it's easy but it makes a kludgy mess that makes it difficult and risky to
update Access. It pushes people into buying other M$ database programs if
they need to upscale an Access database. Access just is not designed to be
used that way. Base is.

Java was widely advertised as being by far the best and sometimes as the
only way to write code that could be used on any machine using any OS.
Even today there are many expensive training courses teaching people how to
use it. It's still kinda like "The Emporer's New Clothes".

Hsqldb is an excellent fast and light database program but it needs to be
kept updated, just like any program. The version hard-coded into LO can't
be updated and is stuck on some ancient transitional version. The
hard-coding was allegedly done by just 2 people without the support of the
Hsqldb community and against the wishes of LO's former, former, former
owners and community - however it did make it more competitive with
Access. So it was a heroic effort and should have been supported and
applauded.

Future iterations of the in-built hsqldb(ish) were probably envisaged as
being closer to proper Hsqldb and as being made easier to update&upgrade -
but without the support of either community or their leadership the code
just stagnated for a few decades instead. People sniping at each other and
pulling in opposing directions rather than helping and supporting each
other doesn't always work well.

The main reasons I really like the move to Firebird are;
1. The name is more excitingly fashionable and easier to market
2. Tactically good to have a refreshing break from our tragic past
regardless of whether it might have been easier and more consistent to just
upgrade to a newer, easier to upgrade, purer version of Hsqldb. (Oddly it
would have been harder to go with Hsqldb and there discussions about which
way to go.)
3. The move to C++ and away from Java - even though it's a step backwards
to a more geeky, less marketable name.

It is really great to see Base getting some much needed love and tlc. It
deserves it.

Regards from
a Tom :slight_smile:

Hi :slight_smile:
I hadn't realised the Firefox was previously called "Mozilla Firebird"
after being forced to rename itself from Phoenix due to name infringement
with "Phoenix Technologies". Annoyingly for them Firebird was also taken
but they were was less hostile to Firefox about possible name
infringement.

Of course you know Firefox used to be Netscape which was (ime) far, far
better than any other web-browser but lost a marketting war with
Microsquish. I just hadn't known about the intermediate names Firefox went
through around 20 years ago.

Ironically LibreOffice uses the "Mozilla License" as well as the LGPL and
now is going to be using the Firebird product that kinda pushed Mozilla
into having to rebrand themselves a 3rd time!

I think it shows that moving away from MS is a move towards a much more
co-operative but still competitive free-trade market. Also that these
young revolutionary anti-corporate new upstarts are actually decades-old
companies/communities. Instead of getting bogged down into a kludgy
unweildy mess, 'we' have remained innovative and fresh by allowing each
community to retain it's indepence and focus.

Regards from
a Tom :slight_smile:

Hi :slight_smile:
Is anyone here in the MariaDb or MySql communities? Is there any chance of
attracting some of their devs to work on an Open Source connector or better
yet to work with our devs to create native support?

I tried asking the MariaDb people around the time they forked off from the
Oracle overlords but I'm really bad with people and they were quite busy.

Someone in the Postgresql community did a fantastic job of getting their
devs and our devs working together a few years ago and so LibreOffice
apparently connects to LO really neatly.

Regads from
a Tom :slight_smile:

Hi :slight_smile:
Omg I go off on one sometimes! It's not like I was really there or really
know or am in any position to judge anyone. I didn't mean it to but my
post sounds very judgemental now I re-read it. Sorry! :frowning:

Wrt sniping and pulling in different directions working well sometimes - it
has worked really well for OpenOffice and LibreOffice. Since we forked
there have been tons of articles and discussions about 'which is better' or
about alleged acrimony between us which has hugely helped "raise the
profile" of both. Nowadays when I mention LibreOffice / OpenOffice to a
group of strangers there is usually at least 1, usually more, who uses one
of them!

Regards from
a Tom :slight_smile:

Hi :slight_smile:
Access can be forced into using an external database and some people claim
it's easy but it makes a kludgy mess that makes it difficult and risky to
update Access. It pushes people into buying other M$ database programs if
they need to upscale an Access database. Access just is not designed to be
used that way. Base is.

Java was widely advertised as being by far the best and sometimes as the
only way to write code that could be used on any machine using any OS.
Even today there are many expensive training courses teaching people how to
use it. It's still kinda like "The Emporer's New Clothes".

Hsqldb is an excellent fast and light database program but it needs to be
kept updated, just like any program. The version hard-coded into LO can't
be updated and is stuck on some ancient transitional version. The
hard-coding was allegedly done by just 2 people without the support of the
Hsqldb community and against the wishes of LO's former, former, former
owners and community - however it did make it more competitive with
Access. So it was a heroic effort and should have been supported and
applauded.

Future iterations of the in-built hsqldb(ish) were probably envisaged as
being closer to proper Hsqldb and as being made easier to update&upgrade -
but without the support of either community or their leadership the code
just stagnated for a few decades instead. People sniping at each other and
pulling in opposing directions rather than helping and supporting each
other doesn't always work well.

The main reasons I really like the move to Firebird are;
1. The name is more excitingly fashionable and easier to market
2. Tactically good to have a refreshing break from our tragic past
regardless of whether it might have been easier and more consistent to just
upgrade to a newer, easier to upgrade, purer version of Hsqldb. (Oddly it
would have been harder to go with Hsqldb and there discussions about which
way to go.)
3. The move to C++ and away from Java - even though it's a step backwards
to a more geeky, less marketable name.

It is really great to see Base getting some much needed love and tlc. It
deserves it.

Regards from
a Tom :slight_smile:

Robert,
Your "Problem for MariaDB/MySQL" has not been my experience. Yes, LO will not create the database. That must be done with the MariaDB/MySQL tools. I use the "mysql" tool and the "GRANT" and "CREATE DATABASE" commands to create my empty database. As you say, there are other tools available to do this. Use whatever tool fits your "hand". After the database is created, Base can be used to do all the rest: create tables, add relationships, etc. I did need to learn a bit of SQL to do some sorting of lists (tables) so they are alphabetically listed in the forms I made. I found the book "Teach Yourself SQL in 24 Hours" by Ryan Stephens and Ron Plew, published by Sams, to be of value to me.

To create the relationships, I use the "Queries" "Database" option of Base and the "Tasks" options. I prefer to start with the "Create Query in Design View" to do most of the work. In this option, the screen has two main windows. The top window is for adding tables and relationships. The bottom window is for specifying the Query output fields. Then, instead of specifying the table directly in a form or report data source, I reference the query for the form or report's data source input. This part of Base is very nice to use. Base then creates the SQL for you. If you really need to see or edit the SQL for the query, you can do that by editing in SQL mode. You can switch between the SQL editing mode and the "Design" editing mode with the Turn Design View Off/On icon. You can even "Run" the SQL or design to verify the output is what you expected with the "Run Query" icon. Slick.

BTW: I am currently running Mariadb 10.0.34 with mysql-connector-java 5.1.42 and LO 5.3.4 and AOO 4.1.5 under Slackware Linux 14.2 (k4.4.118_smp). I have a database with many tables and relationships and several Base forms for data entry/maintenance on each table. I have several reports with different data sorting to sort the table data by different fields. Each report and form has their own query. Several of my tables have thousands of records. Most of my tables contain critical inventory data that I need in my work. So, my Base usage is not trivial and losing it, including the report generation, would be painful to me.

HTH.
Girvin

Hi :slight_smile:
Is anyone here in the MariaDb or MySql communities? Is there any chance of
attracting some of their devs to work on an Open Source connector or better
yet to work with our devs to create native support?

I tried asking the MariaDb people around the time they forked off from the
Oracle overlords but I'm really bad with people and they were quite busy.

Someone in the Postgresql community did a fantastic job of getting their
devs and our devs working together a few years ago and so LibreOffice
apparently connects to LO really neatly.

Regads from
a Tom :slight_smile:

Hi Girvin,

To create the relationships, I use the "Queries" "Database" option of
Base and the "Tasks" options. I prefer to start with the "Create Query
in Design View" to do most of the work.

Seems you create the relation between tables in queries. That is not the
way to create relationships in databases. It doesn't define foreignkeys
to other tables and the behavior of a database, which should be done
when loosing the value for the foreignkey of the other table.

MyISAM-tables are a part of MySQL/MariaDB. If you have created a
database you could connect with Base to the database. You could create
tables. All this tables, which are created by GUI, are MyISAM-tables.
And this tables doesn't have functionality for creating relationships.
So Base says, when opening Tools > Realtionships: "Your database doesn't
allow to create relationships".

You have to create Innodb-tables to create such relationships with
foreignkeys. And this isn't supported by the GUI of Base. You have to do
it in direct SQL or with other tools.

Regards

Robert

Hi Tom,

Is anyone here in the MariaDb or MySql communities? Is there any chance of
attracting some of their devs to work on an Open Source connector or better
yet to work with our devs to create native support?

There is a native connector available for MySQL/MariaDB:
https://extensions.libreoffice.org/extensions/mysql-native-connector

I have tested both, native connector and JDBC. Have forgotten what I
missed in native-connector and works in JDBC, but decided to take
JDBC-connector instead.

Regards

Robert