database2spreadsheet

Without any coding it is be possible to create a field of hyperlinks.
Just add a HYPERLINK formula next to the import range. The adjacent
field expands to the size of the import range.

You mean to the size of the image? It doesn't scale the images to achieve a reasonable overall layout?

In this case, I could make the images all the same size; in other cases, I might have images in all different sizes ...

Nope. I mean you can add a hyperlink to the spreadsheet which opens the
picture in your pic viewing program.

Ok, so I want to import data from a CSV file and would like to have some formatting applied automatically, like specifying a particular width and conditional formatting for some of the columns when I open the file which is sent to me by email.

It would be possible to write some extra data into the CSV to achieve this.

How could I do this?

Sorry, this is the wrong answer to the right post --- still a question, though.

The answer to this post should have been that I would need the images to appear in the spread sheet.

Without any coding it is be possible to create a field of hyperlinks.
Just add a HYPERLINK formula next to the import range. The adjacent
field expands to the size of the import range.

You mean to the size of the image? It doesn't scale the images to
achieve a reasonable overall layout?

In this case, I could make the images all the same size; in other cases,
I might have images in all different sizes ...

Nope. I mean you can add a hyperlink to the spreadsheet which opens the
picture in your pic viewing program.

Ok, so I want to import data from a CSV file and would like to have some
formatting applied automatically, like specifying a particular width and
conditional formatting for some of the columns when I open the file
which is sent to me by email.

It would be possible to write some extra data into the CSV to achieve this.

How could I do this?

Simply use the database engine of your choice. The one you are already
connected with. It should provide all the capabilities to export, import
and link csv table. In this case you would not need any Office suite at
all. Office users can import csv files in the office GUI. Copying table
icons from a text connected database into a regular database or copying
spreadsheet cells onto the icon of a database table.

For the built-in HSQLDB this is described here:
[Tutorial] Using csv/text files as editable data source.

https://forum.openoffice.org/en/forum/viewtopic.php?f=83&t=23260

And it works in the same way with later versions of HSQL.

Since you do not mention your database engine, Google is your friend.
There are thousands of hits about csv and MySQL. All this works without
any office suite and your Perl script can simply issue some SQL command
via the dbi module (I think). I'm 100& sure that an office suite can not
add anything to your project. Operate your database any way you want.
Finally you may or may not load the results into document templates.

[Example] Loading CSV into preformatted spreadsheets

https://forum.openoffice.org/en/forum/viewtopic.php?f=100&t=23727

how to maintain prepared Calc templates to be filled with raw data from
csv (or any other kind of data source provided by the Base component).

Pictures in Calc are no spreadsheet data. Pictures are decorative,
illustrating elements pinned to the cells or to the top-left corner of a
sheet. Writing a program to manipulate many calculator cells so they
wrap around picture objects is very difficult. Absolutely non-trivial.

For a LibreOffice user there is only one built-in tool to do reporting
with pictures. It is the report tool.

You are a Perl programmer. This kind of stuff has always be done with
html reports.

Sorry, this is the wrong answer to the right post --- still a question,
though.

The answer to this post should have been that I would need the images to
appear in the spread sheet.

Pictures in Calc are no spreadsheet data. Pictures are decorative,
illustrating elements pinned to the cells or to the top-left corner of a
sheet. Writing a program to manipulate many calculator cells so they
wrap around picture objects is very difficult. Absolutely non-trivial.

Hence my idea to resize the pictures outside of LO to suitable dimensions and put links to the resized ones into the CSV (or a databse table) to have them displayed reasonably in the spreadsheet.

For a LibreOffice user there is only one built-in tool to do reporting
with pictures. It is the report tool.

Hm, I'm not too happy with that because the defaults aren't too useful, and when I wanted to make a report to display data from a table, the report didn't display any of the data but the default placeholders instead.

You are a Perl programmer. This kind of stuff has always be done with
html reports.

Then the data cannot be edited as easily as with a spreadsheet ... However, a web page just like a spreadsheet would be very useful. I will have to look for some tool that works for this; there's probably something I could use.

Ok, so I want to import data from a CSV file and would like to have some
formatting applied automatically, like specifying a particular width and
conditional formatting for some of the columns when I open the file
which is sent to me by email.

It would be possible to write some extra data into the CSV to achieve this.

How could I do this?

Simply use the database engine of your choice. The one you are already
connected with. It should provide all the capabilities to export, import
and link csv table. In this case you would not need any Office suite at
all. Office users can import csv files in the office GUI. Copying table
icons from a text connected database into a regular database or copying
spreadsheet cells onto the icon of a database table.

Copying icons?

For the built-in HSQLDB this is described here:
[Tutorial] Using csv/text files as editable data source.

https://forum.openoffice.org/en/forum/viewtopic.php?f=83&t=23260

And it works in the same way with later versions of HSQL.

Since you do not mention your database engine, Google is your friend.

mysql

There are thousands of hits about csv and MySQL. All this works without
any office suite and your Perl script can simply issue some SQL command
via the dbi module (I think).

Yes, it uses DBI to do its work.

I'm 100& sure that an office suite can not
add anything to your project.

It makes life a hell of a lot easier because it provides a very useful frontend.

Operate your database any way you want.
Finally you may or may not load the results into document templates.

[Example] Loading CSV into preformatted spreadsheets

https://forum.openoffice.org/en/forum/viewtopic.php?f=100&t=23727

how to maintain prepared Calc templates to be filled with raw data from
csv (or any other kind of data source provided by the Base component).

Awesome, thank you! That might be exactly what I'm looking for, I'll check it out.

Indeed. In order to copy table or view contents from one DB to another
DB you copy the table _icon_ from one database window, select the table
icon in the other database window (the DB where you have write access)
and paste.
A dialog pops up which lets you map the matching fields of both tables.

I'm pretty sure this can be fixed one way or the other. Sorry, I don't
know about this problem since I do not use that reporting tool (in fact
I do not even use LibreOffice).

Assuming that you get that report with pictures running and you really
want to manipulate the data on that report and you know that this is NOT
how things should be done because your reports would differ from your
database content, then all you need to do is calling menu:File>SaveAs...
and save a new writable copy of that Writer document. All reports are
read-only Writer documents in the first place.

How weird, I'd never think of doing anything like that. And if I would, I wouldn't do it because LO is too likely to crash, leaving me with a mess.

BTW, as to reports, no, I don't want to alter data in reports, only in spreadsheets.