|
|
Sponsor |
VIEWS: msg#00003db.oracle.devel
Hi, I'm trying to create a view. I started with the select statement and it works well except for when I try to add the function (sum (soi.quantity*unit_price) here is my code... can anyone tell me what I am doing wrong. Thanks a million... select soi.id as order#, to_char(order_date,'mm/dd/yyyy')as Order_Date, region, rtrim(employee.emp_fname)||' '||rtrim(employee.emp_lname) as Sales_Rep, sales_rep as Rep_ID, company_name,rtrim(fname)||' '||rtrim(lname) as customer, '('||substr(customer.phone,1,3)||')'||substr(customer.phone,4,3)||'- '||substr(customer.phone,7) as phone, sum(soi.quantity*unit_price) value from sales_order_items as soi, sales_order, employee, customer, product where prod_id=product.id and soi.id=sales_order.id and cust_id=customer.id and sales_rep=emp_id group by soi.id, company_name order by soi.id / Juan --- Change your mail options at http://p2p.wrox.com/manager.asp or to unsubscribe send a blank email to leave-oracle-1796914O@xxxxxxxxxxxxx
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | looking for "Scott" and "OE" schemas to load, Dan Englander |
|---|---|
| Next by Date: | Re: How to get latest inserted record in a table, Thomas Gaines |
| Previous by Thread: | looking for "Scott" and "OE" schemas to load, Dan Englander |
| Next by Thread: | RE: VIEWS, pep0 |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
Free MagazinesCisco NewsReceive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business. subscribe Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field. subscribe The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business. subscribe Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company. subscribe Total Telecom Total Telecom is "The Economist of the communications industry". subscribe |
Home | sitemap
| advertise | OSDir is
an inevitable website.
|