I have a complicated db query that selects schools based on real estate listing attributes, performance statistics for the schools, and the distance o ...
I have a complicated db query that selects schools based on real estate listing attributes, performance statistics for the schools, and the distance o ...
I use transactions with PostgreSQL. Transactions are a necessary part of serious databasing. Transactions inevitably lead to "deadlocks". Deadlocks ar ...
I have the following test code: I have been trying to get this to stream data instead but unsuccessfully. I did try pg-query-stream, with querystre ...
Setup - PHP 7 app. - Postgres is on Heroku Hobby v11.x - MySQL version was v5.5.56 and protocol 10 - I do not have a great understanding of PHP - I do ...
This does not work I get this error: Warning: pg_query(): Query failed: ERROR: syntax error at or near "-" This one does work So I suppos ...
How to concat hyperlink in php postgresql query, I tried this but confused with single and double quotes my problem is the CONCAT part getting synt ...
I want to use the same pattern for destructuring query results, but seems I cannot. In the following code: if I then follow that with: The only ...
In the code below the first query works as expected and the result is fine. But when the second query runs the result is undefined and it throws an er ...
I'm trying to get the right syntax for the following. In this case $post_pub = 1 Php throws an error: column "$post_pub" does not exist I've stumb ...
I'm trying to get data from a postgresql database, I get the error: pg_last_error() expects parameter 1 to be resource, object given in /path/to/query ...
I'm updating some legacy PHP code and trying to get some decent error logging. All calls to the DB now go through this function: But, in at least o ...
I have doubts about the speed of a query in postgres. I run this query in psql (shell): The result is: Then i run the same query with PHP: ...
pg_query can't be executed in the case where name = ' Kill 'em all ' the error is pointing at the " ' " before "em" which is the problem but i can't f ...
I'm trying to create a table where the table name is a parameter. Is it possible? Like this: $result = pg_query("CREATE TABLE '$_POST[nome_arquivo_so ...
I would like to do search for advanced search. The Search feature has and/or for every category. User can choose any combination of and n or. Here i g ...
after everything to fix it, I have no more ideas and came here to find some help. My $_SESSION isn't working inside an SELECT of postgres, but when I ...
I had a table with a bigserial PK, one character varying FK and a bigint FK and a unique constraint on these FKs, a character varying NOT NULL and two ...
I am creating a node function to create a user in a PostgreSQL database. I'm using node.js, pg and pg-query to communicate from the app to the databas ...