Skip to content

Tag: sql

Accessing PostgreSQL Fields via Indexing

Is there a way in PostgreSQL to access fields without explicitly providing the column name? For example, instead of the statement: there’s a (possible) alternative of: Answer There is no such syntax in Postgres’ SQL. You could always resort to having code that dynamically constructs the query for …

sql table comparisons – postgres

I have two tables with some columns being the same: TABLE A TABLE B I’d like to return the following: How do I check what rows from table B are in table A and also return Col4 (from table B) where they match in the query. I was using EXCEPT which worked great but now I need to have the