Question: I am searching for a streaming solution, my company need to record and stream a live event on a Website, I am looking for hint as to which technology we should use, and what do we need in our setup.

This is how I see that for now :

We will need to install 3 camera, 1 console (to manage which camera is streamed), 1 Streaming server, on the location of the events. And our website would have a plugin (Flash?) showing what is streaming by the Server at the event location.

Do I have that right?

Any of you have any experience with similar technology?

Answer: 
I'd have a table with a row per item per day - store the date, the item ID, the quantity sold, and the price sold at (store this even though it's also in the product table - if that changes, you want the value you actually sold at preserved). You can compute totals per item-day and totals per day in queries.

Tables:

```
create table product (
  id integer primary key,
  name varchar(100) not null,
  price decimal(6,2) not null,
  inventory integer not null
);

create table sale (
  saledate date not null,
  product_id integer not null references product,
  quantity integer not null,
  price decimal(6,2) not null,
  primary key (saledate, product_id)
);

```

Reporting on a day:

```
select s.product_id, p.name, s.quantity, s.price, (s.quantity * s.price) as total
from product p, sale s
where p.id = s.product_id
and s.saledate = date '2010-12-5';

```

Reporting on all days:

```
select saledate, sum(quantity * price) as total
from sale
group by saledate
order by saledate;

```

A nice master report over all days, with a summary line:

```
select *
from (
    (select s.saledate, s.product_id, p.name, s.quantity, s.price, (s.quantity * s.price) as total
    from product p, sale s
    where p.id = s.product_id)
  union
    (select saledate, NULL, 'TOTAL', sum(quantity), NULL, sum(quantity * price) as total
    from sale group by saledate)
) as summedsales
order by saledate, product_id;

```
Try modelling your sales as a transaction - with a "header", i.e. who sold to, when sold, invoice # (if applicable), etc. and "line items", i.e. 20 \* product\_x @ $5 = $100. The safest approach is to avoid relying upon prices etc. from the products table - as these will presumably change over time, and instead copy much of the product information (if not all) into your line item - so even when prices, item descriptions etc. change, the transaction information remains as was at the time the transaction was made.