Question re: pldbgapi

2018-06-19 Thread Steven Hirsch
Hi, all. I'm trying to debug a rather complicated function using pldbgapi in pgAdmin III and am running into an annoying problem. In order to set breakpoints, I need to execute the query that invokes the function. It then stops at the first line and allows me to set breakpoints. However, I

Re: Fwd: Carto ODBC_FDW issue "ERROR: Connecting to driver" from PG to DB2

2018-04-11 Thread Steven Hirsch
On Wed, 11 Apr 2018, karthik kumar wrote: This is the error we see in the ODBC trace log         DIAG [08001] [IBM][CLI Driver] SQL30081N  A communication error has been detected. Communication protocol being used: "TCP/IP".  Communication API being used: "SOCKETS".  Location where the error

Re: Fwd: Carto ODBC_FDW issue "ERROR: Connecting to driver" from PG to DB2

2018-04-11 Thread Steven Hirsch
On Wed, 11 Apr 2018, karthik kumar wrote: Hello Adrian I built fdw with debug option and ran it with debug option.  Here is the output postgres=# select * from odbc_testt; DEBUG:  StartTransactionCommand DEBUG:  StartTransaction DEBUG:  name: unnamed; blockState:       DEFAULT; state:

Re: FDW with DB2

2018-04-06 Thread Steven Hirsch
On Fri, 6 Apr 2018, Ravi Krishna wrote: the CartoDB ODBC driver works quite well.  I've used it to move a large amount of data from DB2 and Netezza databases.   ​Hello Steven Will it be OK if I or my team reach out to you for any guidance/help. To the extent that questions on

Re: Introducing brand-new dbForge Studio for PostgreSQL, a powerful IDE for working with PostgreSQL databases

2018-03-22 Thread Steven Hirsch
On Thu, 22 Mar 2018, Devart wrote: /Devart announced the first release of dbForge Studio for PostgreSQL that allows to manage and develop database objects in PostgreSQL. This new IDE offers many robust features like Code Completion, Object Explorer and Data Editor which help users create,

psql '\copy to' and unicode escapes

2018-02-26 Thread Steven Hirsch
I fear that I'm missing something very obvious, but I cannot find a syntax that permits me to use an escaped hexadecimal representation in a CSV file and have that representation interpreted as the equivalent unicode character when inserting into the database. Both client and server are using

Re: Odd behavior with 'currval'

2018-02-09 Thread Steven Hirsch
On Fri, 9 Feb 2018, Francisco Olarte wrote: I was trying to be careful and changed the address manually for all messages except this one. Do not bother with that. The style in this list is to just reply to all, so the people that are participating in the thread can get a copy of the messages

Re: Odd behavior with 'currval'

2018-02-09 Thread Steven Hirsch
On Fri, 9 Feb 2018, Adrian Klaver wrote: I remember seeing it, so I went back to look at the message. Turns out you sent it to me only. Unfortunately I am not a Java programmer so I did not catch the error. For the record: Ah, blast... Apologies to everyone concerned. I need to understand

Re: Odd behavior with 'currval'

2018-02-09 Thread Steven Hirsch
On Fri, 9 Feb 2018, Francisco Olarte wrote: This may sound a bit harsh but: The culprit is in the JDBC domain, NOT PostgreSQL! According to the documentation I found, the ResultSet 'getLong()' method returns a value of zero when it sees NULL as an input. Why the JDBC libs don't treat this as

Re: Odd behavior with 'currval'

2018-02-08 Thread Steven Hirsch
On Thu, 8 Feb 2018, David G. Johnston wrote: On Thu, Feb 8, 2018 at 12:54 PM, David G. Johnston wrote:  The only 'currval' procedure is the one defined at installation (in public). ​So, the installed version of currval would be defined in

Re: Odd behavior with 'currval'

2018-02-08 Thread Steven Hirsch
On Thu, 8 Feb 2018, David G. Johnston wrote: On Thu, Feb 8, 2018 at 10:58 AM, Steven Hirsch <snhir...@gmail.com> wrote: On a hunch, I tried 'SELECT currval(NULL)' to see if it returned '0', but that too returns NULL.  So, where is the '0' coming from when I do:

Re: Odd behavior with 'currval'

2018-02-08 Thread Steven Hirsch
On Thu, 8 Feb 2018, Adrian Klaver wrote: hplc=> \d student_attendance_attendance_id_seq Sequence "public.student_attendance_attendance_id_seq" Column | Type |Value ---+-+-- sequence_name | name|

Re: Odd behavior with 'currval'

2018-02-08 Thread Steven Hirsch
On Thu, 8 Feb 2018, Melvin Davidson wrote: I believe your problem is in your usage. In order for currval(regclass) to work, you must first do a SELECT nextval(regclass) in your _current transaction_! https://www.postgresql.org/docs/9.6/static/functions-sequence.html I AM doing that. It is

Odd behavior with 'currval'

2018-02-08 Thread Steven Hirsch
I have a body of code using JDBC to work with a PostgreSQL 9.6 database. All tables use 'SERIAL' or 'BIGSERIAL' types to generate ids. All are working correctly in terms of using the next value as a default. However, reading back the most recently applied (currval) value is failing for one