I am trying to put together a query from the Sakila database. The query should find all actors that have starred in all 16 film categories. To get a ...
I am trying to put together a query from the Sakila database. The query should find all actors that have starred in all 16 film categories. To get a ...
From the 3 tables below I need to find 'John', who has a bike but not a car. I'm trying to use this syntax so in practise I create a left join from ...
I would like to use a division query to have all the customers who bought all products. The template is the following : It's well explained in thi ...
i'm facing a problem with sql queries... is there a shorthand for AND condition like IN= many OR conditions?? when not, any idea about this situation. ...
I've built an app that displays images. Each image can be tagged with multiple tags. I've now added a Search box that works fine in an OR kind of way. ...
I want to get all of the id1 where id2 is equal to 2 and 3. Consider the sample table given below Sample Table- In this case, expected output is a ...
I have a table of properties: A table of accessories: A table that relates properties and accessories (properties2accessories): I need all th ...
My Table Structure is shown below: I would like to retrieve company names and person names that working for this company and their position are (CE ...
The Name Table has more than just 1,2,3 and the list to parse on is dynamic NameTable CharacterTable NameToCharacterTable I am looking for ...
I am trying to create a SQL report that can do logic based on a boolean that exists in multiple rows. I created a bunch of fake data below, and my att ...
Bottom line, I want to be able to search for items by tag and tag combinations (plus and minus). I played with subqueries and considered CTE functiona ...
I want to select people who has 2 values (activate & recurring) in the table for example, table :: tbl_transactions id na ...
Given the data table below, how can I retrieve only the row #3, querying the field "chave", based on multiple json rows? I want to retrieve the maste ...
I have the following simple table COL1 COL2 COL3 U1 L1 X U1 L5 ...
On PostgreSQL, I have a table item, and a table item_attribute. So an item can have multiple attributes. table: item id name ...
I want to find a salesman who had sales in 1998, 1999 and 2001 For example: result should be "a" and "b" because only those salesman had sales in ...
I have these tables: Project id name version 1 Pete 0.0.1 2 Swag ...
I have a table that I want to be able to query to get rows that are in a defined sets of value. I can create new table structures if required as this ...
I am working on job related data and wanted to do some analysis. I have two tables a Job table with job_id and an Application table with app_id,job_i ...
I am working with nodejs and postgresql. My postgresql relation has 3 columns: id lesson_id tag_id. A lesson could belong to 1 or multipl ...