Questions tagged as 'postgresql'

3
answers

Make INNER JOIN of a foreign key

How do I see the description of the department using an SQL query that calls all the people's records? This is the query I have SELECT p.nombre, p.apellido1, p.apellido2, p.dep FROM personas p, departamentos d WHERE p.dep = d.dep  ...
asked by 19.12.2018 / 20:35
1
answer

I get an error when wanting to make the connection laravel 5.6 with Postgres and I get error

.env file DB_CONNECTION=pgsql DB_HOST=127.0.0.1 DB_PORT=5432 DB_DATABASE=p1 DB_USERNAME=postgres DB_PASSWORD=123456tuyyo file config / database.php 'default' => env('DB_CONNECTION', 'pgsql'), [     
asked by 05.09.2018 / 21:02
2
answers

What java object to use to insert a date in a PostgreSQL timestamp field

I am working with a PostgreSQL database , in which I have a field of type timestamp since I only want a date with its time (no time zone ). To do the saving I am making use of the object LocalDateTime of Java 8. The ques...
asked by 23.07.2018 / 12:30
2
answers

current_timestamp does not exist in PostgreSQL?

I have a database that is about Heroku. A field is filled automatically with the date. I try to use current_timestamp , but it seems that it does not work. Here is the schema of the database. drop table if exists users; create table u...
asked by 03.07.2018 / 16:18
1
answer

MERGE in PostgreSQL 9.5

I am trying to do a MERGE in PostgreSQL 9.5 and I get the following error: ERROR: syntax error at or near "MERGE" LINE 1: MERGE INTO TP_ESTADO_EQUIPOS AS EQ ^ ********** Error ********** ERROR: syntax error at or near "MERGE"...
asked by 19.03.2018 / 15:43
3
answers

Problem with Declaration ORDER BY

I have the following concern: When making this query SELECT * FROM la_tabla ORDER BY padre row 4 should be located below row 1, however I am getting this result, what is the error here?     
asked by 18.12.2017 / 19:51
4
answers

Insert data from a Postgresql Query to an HTML table

Good afternoon, I'm trying to make a table in HTML using PHP to establish communication with the database, the query is as follows $query1="SELECT b.nombreforense, b.apelldoforense, COUNT(*) AS Total FROM fallecido AS a INNER J...
asked by 11.04.2017 / 21:38
1
answer

Problem with JRLoader

I am trying to run a report in Jasper Report with the following code: Class.forName("org.postgresql.Driver"); Connection conexion = DriverManager.getConnection("jdbc:postgresql://localhost:5432/reportes", usuario, contraseña; File repor...
asked by 24.01.2017 / 22:57
2
answers

C # Connection with PostgreSQL through Npgsql provider

Hello the problem is that the connection is fine only when I am using the ODBC , but when I change it to the provider of PostgreSQL Npgsql , it does not let me connect it tells me that syntax error, I think the error is in the connec...
asked by 22.10.2016 / 18:18
1
answer

Obtain records of several tables without duplicates in postgresql

I'm having a problem when it comes to bringing the database records, I have an inventory system of some technological equipment, each one has an asset code, but an asset code can be on several computers since an asset can be made up of several c...
asked by 28.06.2016 / 23:30