relational-division Questions

5

Solved

I have a simple question about the most efficient way to perform a particular join. Take these three tables, real names have been changed to protect the innocent: Table: animal animal_id name ....
Barrel asked 7/2, 2012 at 2:8

3

Solved

Suppose it's a website that sells photo cameras. Here are my entities (tables): Camera: A simple camera Feature: A feature like: 6mp, max resolution 1024x768, The thing is between cameras and f...
Calx asked 1/2, 2012 at 20:33

4

Solved

My query includes a having and count or all in. How are these represented in RA/DRC/TRC? Would I have to simplify my SQL query even more? Here is a simplified example: empl(employee (primary key),...

5

Solved

I'm trying to select items from an associative table that have satisfy two or more values of the same field, sounds confusing, let me explain. +-----------------------+ | item_id | category_id | +...
Tague asked 13/9, 2011 at 18:57

3

Solved

I have two tables in my database: Products id (int, primary key) name (varchar) ProductTags product_id (int) tag_id (int) I would like to select products having all given tags. I tried: S...
Vshaped asked 16/2, 2011 at 14:33

6

Solved

Let's say I have a two-column table like this: userid | roleid --------|-------- 1 | 1 1 | 2 1 | 3 2 | 1 I want to get all distinct userids that have roleids 1, 2 AND 3. Using the above exampl...
Kaka asked 25/1, 2009 at 1:1

5

Solved

So imagine that you have a table of Products (ID int, Name nvarchar(200)), and two other tables, ProductsCategories (ProductID int, CategoryID int) and InvoiceProducts (InvoiceID int, ProductID int...
Paulapauldron asked 25/10, 2010 at 22:21

6

Solved

Given the following tables: Recipes | id | name | 1 | 'chocolate cream pie' | 2 | 'banana cream pie' | 3 | 'chocolate banana surprise' Ingredients | id | name | 1 | 'banana' | 2 | 'cream' | 3 | '...
Stroll asked 12/6, 2010 at 17:10

9

Solved

Say I have a table that has items and attributes listed like, frog green cat furry frog nice cat 4 legs frog 4 legs From the items column I want to select unique objects that have both the green...
Sententious asked 29/5, 2009 at 19:29

7

Solved

I have a database with two main tables notes and labels. They have a many-to-many relationship (similar to how stackoverflow.com has questions with labels). What I am wondering is how can I search ...
Kino asked 8/12, 2008 at 13:32

© 2022 - 2024 — McMap. All rights reserved.