how function pg_ls_dir () work in postgresql 8.0.6? - postgresql

Behold, I send such a request to the database
select pg_ls_dir('. . . /data/pg_log/') as files_dir;
and I get an answer here:
ERROR: function pg_ls_dir("unknown") does not exist
HINT: No function matches the given name and argument types. You may need to add explicit type casts.
It says here that there is no function version of postgresql c I work with (8.0.6), is there any way to connect to the desired function, or the other way is even files from the directory?

That's because you're using an old version of Postgres. pg_ls_dir() appeared in version 8.1.
I would strongly suggest you upgrade to the latest version (9.3 as of this writing) if at all possible, as version 8.0 is nine years old and no longer supported.

The pg_ls_dir() function was introduced in PostgreSQL 8.1 so it's not available in 8.0.
You could try adding the function to the installation manually but I would advise against it. Here's the source regardless: http://doxygen.postgresql.org/builtins_8h.html#a35b15cee7a44663710a7125c5b57484d

Related

Error: column p.proisagg does not exist in PostgreSQL 11

When I tried to copy paste the tables from my connection database and paste the tables into my local database in postgres I'm getting this error. I've been using navicat version 12 and postgres version 11. Is there any conflict in terms of versioning between the two extension?
Some resources says: p.proisagg should change into p.prokind: the question is how can I change this? I've been using windows.It would be great if anybody could figure out where I am doing something wrong. thank you so much in advance.
The software version(navicat version 12) is inconsistent with the PGSQL version(postgres version 11). As a result, some configurations are not associated. You can upgrade the software version to resolve the problem,like navicat 15 or final (now is 16).

Magento 2 error Current version of RDBMS is not supported. Used Version: 10.1.37-MariaDB. Supported versions: MySQL-8, MySQL-5.7, MariaDB-(10.2-10.4)

I am running a magento 2.4 project but current not in position to update mysql version. any way to skip that error ?
Magento 2 error Current version of RDBMS is not supported. Used Version: 10.1.37-MariaDB. Supported versions: MySQL-8, MySQL-5.7, MariaDB-(10.2-10.4)
An alternative solution if you are in a bind.
Edit file app/etc/di.xml
You can specify acceptable MariaDB versions here - currently 10.2-10.4
Example to allow MariaDB 10.5
<item name="MariaDB-(10.2-10.5)" xsi:type="string">^10\.[2-5]\.</item>
Yes you can try to change one file but can be some issues can occur in project while running.
Go to Vendor/Magento/Framework/DB/Adapter/SqlVersionProvider.php
Update function getVersionString and replace line
$sqlVersionOutput = $this->fetchSqlVersion($resource);
to
$sqlVersionOutput = '10.2.37-MariaDB';
This is temporary solution. So you should consider to update mysql version.
You could override module to allow MariaDB 10.5 to 10.9 support for development...
composer require reessolutions/db-override:*
(Source: https://github.com/Sental/db-override)
This has worked for me.

Issue related to timescaledb backup: "ERROR: function timescaledb_pre_restore() does not exist"

Scenario:
PostgreSQL 11.4
TimescaleDB 1.2.2
When trying to dump and restore a database, and following this documentation, I'm getting the following error message:
function timescaledb_pre_restore() does not exist
It seems to be something obvious, but I don't get it. ¿Any help?
Thanks.
This function didn’t exist in 1.2.2. Check out the backup/restore docs for this version here: https://docs.timescale.com/v1.2/using-timescaledb/backup
You are using a fairly old version of TimescaleDB, and the instructions were different for 1.2. But our docs are versioned (see the version switcher in the top of the left-hand nav). So navigate over to version 1.2, and there are slightly different instructions:
https://docs.timescale.com/v1.2/using-timescaledb/backup

Error while creating extension in postgresql

I am using https://tada.github.io/pljava/install/install.html link to create pljava extension in postgresql.
Build is ok and there is no unsuccessful operation. However when i tried to create extension using the statement below:
create extension pljava;
It is giving me the error:
ERROR: java.text.ParseException: Excpected keyword 'SQLActions'
Internet gave me no result about this error. Any help is appreciated to solve this problem.
That is definitely unexpected. To begin to look for the cause, could you please run
pg_config --version --sharedir
and then also post the contents of
$SHAREDIR/extension/pljava.control
where $SHAREDIR is as reported by the pg_config command?
Have you ever had an earlier PL/Java version in use with this database?
Does postgresql.conf contain any settings of pljava.* or of dynamic_library_path?
Also, what's your operating system and version?
If you have a github account, you could open this as a PL/Java issue there.

Access postgres in matlab without database toolbox

I followed the steps listed in the previous answer to this question here
How can I access a postgresql database from matlab with without matlabs database toolbox?
However, on the step
driver = org.postgresql.Driver;
I'm getting the following error.
Undefined variable "org" or function "org.postgresql.Driver"
I've added it to the dynamic path, and running "javaclasspath" shows the following at the bottom
DYNAMIC JAVA PATH
M:\postgresql-9.3-1100.jdbc41.jar
any ideas on what is wrong?
You probably got the wrong bytecode-versin of postgresql. The jdbc41 is for java 1.7 and 1.8 only, which is not included at least up to Matlab 13a. Only 13b has Java 1.7 with jdbc41 integrated.
Type ver to check your current JRE integrated into Matlab, then download the correct bytecode-version of postgresql, which is probably jdbc4.