1
vote
1answer
28 views

Exception : Callable statement did not return any value

I have written a java code to call a stored procedure which returns some data. Following is the code - CallableStatement callableStatement = null; List<OutputDTO> outputDTOList = new ...
0
votes
0answers
36 views

Column index out of range when creating alias with criteria

Ok so I get this weird issue that I can't fix. I have 3 entities ( i will write things that only matters imo) @Data @Entity // all @ are in javax @Table(name = "a", schema = "pl") ...
-2
votes
1answer
18 views

how to check which ip address accessing my database on 5432 port [on hold]

i want to monitor my postgres database running on 5432 port. i want to see which ip address is accessing this at what time using java. How to do this?
0
votes
1answer
27 views

postgres migration error; unterminated dollar-quoted string

Well this is abit strange, could anyone help me point out where this function may be wrong. I have a function similar to CREATE FUNCTION check_password(uname TEXT, pass TEXT) RETURNS BOOLEAN AS $$ ...
0
votes
0answers
22 views

liferay: create a table during run time

Description : i am trying to edit the web form portlet. But by default it store the values in expando tables but i want to store it in new table. but again i want keep this portlet as flexible as ...
0
votes
1answer
44 views

Application is getting stuck at hibernate txOracle.commit();

try { sessionOracle = BaseDAO.getHibernateSession().openSession(); sessionPostgres = BaseDAOgis.getHibernateSession().openSession(); int id = 0; JSONArray jaRoute = new ...
0
votes
0answers
20 views

Multiple access to the same shared database postgres sequence

I have two different java web application than access a shared postgres database for reading and writing. My first web application in deployed on apache tomcat and my second web application is ...
1
vote
0answers
33 views

String interning in the database

I am using a PostgreSQL database to log various aspects of a long-running system I have and one particular item I am logging is the CLASSPATH of the various sub-ordinate processes the system spawns . ...
0
votes
1answer
29 views

Switching between MongoDB and JPA (Postgres) in the same project

In our current project we use MongoDB. Recently there was a request to switch to Postgres. We don't want to drop MongoDB and just migrate to Postges right away. It would be great to have some sort of ...
2
votes
0answers
22 views

How to pass a set of composite types (UDTs) in PostgreSQL using JDBC

We are migrating from Oracle to PostgreSQL Enterprise DB and we have a stored procedure that accepts table-like structure. We used STRUCT with Oracle and it worked very well. Now this table is ...
1
vote
0answers
24 views

Hardware sizing an application which runs fine on a laptop?

If an application already runs well on a laptop with a local webserver and db, how does it impact hardware sizing for when it is deployed into product? We're piloting this application for the first ...
-2
votes
0answers
45 views

How to retrieve data from database in java? [closed]

I have an Excel.java class which has database connections and my task is that i need to retrieve data from database to whatever query i write !! So i created an jlabel.java class in the same package ...
0
votes
3answers
51 views

Java SQL query execution, problems in reading the ResultSet rows

I'm writing simple Java code and I have to execute an SQL query on my Postgresql database. The result of this database (I've checked manually) is a simple table made by one column and two integer ...
0
votes
1answer
17 views

Access to the original query through SQLWarning

I was wondering if there's a way to access the original SQL query from a SQLException/SQLWarning. I thought that that was unlikely, but the sentence Warnings are silently chained to the object whose ...
4
votes
1answer
73 views

Hibernate Spatial - 'Invalid endian flag value encountered' Exception

I'm trying to run a simple query in Hibernate Spatial 4.0 on PostgreSQL 9.3. I have a number of objects in a table with latitude/longitude values, and I'm trying to query objects that fall within a ...
0
votes
0answers
22 views

Parse postgres object literals

I'm working on a java/postgres project, and one of the db tables contains a fairly complex composite type. The project uses Ebean for O/R mapping, and I'm trying to map an ebean class to the table in ...
0
votes
1answer
50 views

Postgres DB can't connect to R with RJDBC

I've been trying to query data from a PostgreSQL DB via R. I've tried skinning the cat with a few different packages (RODBC, RJDBC, DBI, RPostgres, etc), but I seem to keep getting driver errors. ...
0
votes
0answers
22 views

BoneCP Connection Never Closed

After seeing some odd performance and eventual timeouts, I used the connection watch with BoneCP and see the following: 14:41:38,637 ERROR [com.jolbox.bonecp.CloseThreadMonitor] ...
1
vote
1answer
59 views

Slow JBoss startup, possibly related to DataSource pointing to Heroku Postgres

I am observing a slow JBoss startup. Specifically there is a freeze in the startup when deploying my application, it seems during Hibernate initialisation: 22:43:00,066 DEBUG ...
0
votes
0answers
31 views

Android, take an entire row from postgreSQL database and put in a table or another structure

i'm new to Android programming but i made a little application that interacts with a postgreSQL database via JDBC e made things that aren't related to my question. My main question is: i have a table ...
1
vote
0answers
30 views

How do I log postgres driver messages with slf4j?

I'm using postgres db in my webapp. I added following dependencies in my pom.xml: <dependency> <groupId>org.slf4j</groupId> ...
0
votes
1answer
39 views

Hibernate + PostgreSQL + Network Address Type (inet, cdir)

I have started my example project with Hibernate 4.2.7 and PostgreSQL 9.3.1 and everything is going well. At the moment I would like to use INET PostgreSQL type but I am not able to map it with ...
0
votes
2answers
35 views

Using Hibernate to CREATE SCHEMA in PostgreSQL

All i want is to execute the following SQL on my PostgreSQL server after my Hibernate SessionFactory has been initialized: CREATE SCHEMA IF NOT EXISTS "fooschema" AUTHORIZATION "foouser"; Currently ...
0
votes
0answers
23 views

How can Fix the TypeNotPresentExceptionProxy exception in java?

I am working in a java application and got the exception while migrating my users from postrgre sql db from mongo db getting the exception for the particular id, 2013-11-15 17:08:21,036 ERROR ...
0
votes
0answers
43 views

Storing Malformed Unicode Strings in Postgres

I want to store a string like following in one of my database tables: ygei@kqmfNk@?w@Ac@l@}CbEoD|EM`@MLK@KCKS[e@W[[o@yAuCSUi@[G@KAII?MFk@?cAKWIQ?YFIDEd@cBzA}KvBuPX}B`BwLt@iFFEzE}AlDaA|JqC@y This is ...
2
votes
0answers
34 views

Hibernate: Creating an index for an ElementCollection table

@Entity public class FruitStore { @Id private Long storeId; @ElementCollection private Set<Fruit> fruits; } Of course, the Fruit class is marked @Embeddable. In the database (postgresql to ...
2
votes
2answers
32 views

One hour discrepancy in UTC offset between Postgresql and Java

I have a java program that generates timezone values in the binary format expected by Postgresql's COPY command in binary format. The data is written to a binary file which I then insert into ...
0
votes
1answer
30 views

Postgres sql error code for insert statement

A insert statement is generated in my java program that results in an error given as : ERROR: @20111@ SQL state: P0001 -- Executing query: insert into C_OrderLine (AD_Client_ID, AD_Org_ID, ...
0
votes
0answers
21 views

Postgresql server refuses connection despite authorizing it

I'm connecting to a Postgresql server (version 8.4) with a Spring application. My connection parameters are: <Environment name="/db/driver_class" value="org.postgresql.Driver" ...
0
votes
0answers
33 views

Postgresql org.hibernate.exception.SQLGrammarException: could not retrieve generated id after insert:

I have an application with Spring MVC and Hibernate, and had not given problem, lately I get problem when I delete a value and then want to add to the same table, the table use a sequence for id and ...
0
votes
0answers
39 views

postgres 9 | jdk 7.45 | irregular “No results were returned by the query”

this thing is making me stupid for nothing since yesterday (googled a lot without finding any other developer with the same problem). I'm upgrading an application server written in java (jdk5), which ...
0
votes
0answers
30 views

Getting error while updating an image into database using Java Spring

I tried the code below. I'm using both image and text for update, but I'm getting an application error. Can't infer the SQL type to use for an instance of this error I'm getting. QuestionRef ...
0
votes
1answer
56 views

JDBC - select where column is NULL

I have a simple table in my Postgres 9.0 database: create table test (id int not null, value int); I have populated it with a few rows: insert into test values (1, 1); insert into test values (2, ...
0
votes
0answers
26 views

alter column type from bytea to timestamp with data retention in a Postgres Database

The field in the java class looked like this : private LocalDateTime updateTime; However, Hibernate stores it in the database like this: (output of "select update_time from my_table;") ac ed 00 ...
0
votes
2answers
91 views

unable to create new database with flyway

Question: Is it possible to create a new DB in a migration script and then connect to it? How? My Scenario: I'm trying to use flyway in my Java project (RESTful application using Jersey2.4 + tomcat 7 ...
2
votes
2answers
69 views

PostgreSQL JDBC getGeneratedKeys returns all columns

I've recently switched from MySQL to PostgreSQL for the back end of a project and discovered some of my database proxy methods needed reviewing. To insert linked objects I use a transaction to make ...
0
votes
1answer
42 views

PGpoint hibernate (de)serialization exception

In my database I've this table: CREATE TABLE base_station ( MCC INT NOT NULL, MNC INT NOT NULL, LAC INT NOT NULL, CID INT NOT NULL, type TEXT NOT NULL, geoposition point NOT ...
0
votes
1answer
50 views

ClassNotFoundException (org.postgresql.Driver) with connection pooling example

I am using the sample code found here to implement Connection Pooling for my webapp: http://tomcat.apache.org/tomcat-7.0-doc/jdbc-pool.html#Plain_Ol'_Java Since I am using PostgreSQL as my database, ...
2
votes
2answers
71 views

Order By Date Desc with Spring Data

I try to make an application with Spring-Data-JPA on a table in order by DESC but it gives me an error: Invalid derived query! No property asc found for type java.util.Calendar Why ? ...
0
votes
1answer
18 views

Find ColumnDefinition Enum or Constants

I am looking a class that will contain the constants or enum for JPA columnDefinition. Ex: public class MyEntity { @JoinColumn(name = "my_value", columnDefinition = "BIGINT") private ...
1
vote
1answer
36 views

CallableStatement with parameter names on PostgreSQL

I've tried to call a stored procedure with parameter names specified, but the JDBC failed to accept the parameters. It says: Method ...
1
vote
0answers
39 views

Strange lock with PostgreSQL and Hibernate

I have a web application using Hibernate and PostgreSQL. In this application I have several entities and one of them is: @Entity public class UniverseTime extends Model { @Required public ...
0
votes
1answer
29 views

hadoop - DBInputFormat causing error when configuring object

I know that my error revolves around the fact that not all the nodes in my cluster don't see the Postgresql driver jar, but I don't know which file to edit to have the postgres jar visible to all ...
0
votes
0answers
29 views

tryit failure on slow query

I've been continuing to work on this, but I cannot run a query that runs for more than one minute. I need to do this. If this is possible, what do I need to do? I have the same problem using the ...
0
votes
1answer
77 views

Criteria: ClassCastException Integer to Long

I'm using Hibernate 4.2, and PostgreSQL. I have this table in postgres: id bigserial NOT NULL (chave primária) name text And my entity is: @Entity @Table(name="customer") public class ...
0
votes
1answer
102 views

java.lang.IllegalStateException: Pool not open

while handling large Db transaction I encountered the following problem : java.lang.IllegalStateException: Pool not open at ...
0
votes
1answer
29 views

hibernate persist fails tries to create object with existing id

I am using spring-hibernate-postgres. I have a table say 'some_entity'. It already contains some records. I have a program that tries to create new SomeEntity object. I am populating that object with ...
0
votes
2answers
78 views

java.sql.SQLException: No Suitable Driver error in android app that interacts with postgres

i'm following a tutorial that connects an Android App to a PostgresSQL db, the tutorial is here http://appliedcoffeetechnology.tumblr.com/post/10657124340 and then i have the following code: package ...
0
votes
3answers
48 views

How to storage a file into a Database as byte[] with Hibernate?

I want to storage a file into a database table as byte[]. Now I have a question concerning storing a byte[] into a postgres database table with Hibernate. I have this implementation in my Entity ...
0
votes
2answers
38 views

Postgresql lock shared table with multiple users

So, I'm having a synchronization issue here; Let's explain the situation: I have a table called Sendings, that consists of these columns: id sending_object_id type destinatary The id is the ...

15 30 50 per page