chinni1
02-11-2009, 05:41 AM
Hello
Can we Use orderby clause in views
create view v10 as
SELECT P.product_id AS id,P.Number
as Number,P.name AS name,I.qty_inhouse AS
qty, p.price as price,p.actual_price as
actprice,p.batch_num as batchnum,i.min_qty,(p.actual_price*I.qty_inhouse)as buyprice,(p.price*I.qty_inhouse)as buyprice1,
p.active,p.flag,p.email_list as email,p.def_mail
as def_mailselect ,pod.quantity as availqty,(I.qty_inhouse-pod.quantity)as nqty FROM product_master P, inventory_master I,product_order_details pod,product_orders po WHERE P.inventory=1 AND po.order_id=pod.order_id and pod.product_id=p.product_id and
P.outofseason=0 and po.status=0 and i.inv_id = p.product_id orderby p.product_id
Can we Use orderby clause in views
create view v10 as
SELECT P.product_id AS id,P.Number
as Number,P.name AS name,I.qty_inhouse AS
qty, p.price as price,p.actual_price as
actprice,p.batch_num as batchnum,i.min_qty,(p.actual_price*I.qty_inhouse)as buyprice,(p.price*I.qty_inhouse)as buyprice1,
p.active,p.flag,p.email_list as email,p.def_mail
as def_mailselect ,pod.quantity as availqty,(I.qty_inhouse-pod.quantity)as nqty FROM product_master P, inventory_master I,product_order_details pod,product_orders po WHERE P.inventory=1 AND po.order_id=pod.order_id and pod.product_id=p.product_id and
P.outofseason=0 and po.status=0 and i.inv_id = p.product_id orderby p.product_id