cust_id Order_id Unique
001 001 1
001 002 0
001 003 0
002 001 1
003 001 1
003 002 0
Is the above result set what you are looking for? Below is an example based on the AdventureWorks database. The reason you are getting all 1's above is due to the grouping over cust and order. You want to group over just Cust.
use AdventureWorks2008R2
;with CustSales as
(
select
C.CustomerID,
H.SalesOrderID,
ROW_NUMBER() over (partition by C.CustomerID order by SalesOrderID) as s
from Sales.Customer C
join Sales.SalesOrderheader H on
C.CustomerID = H.CustomerID
)
select
CustomerID,
SalesOrderID,
case when s = 1 then 1 else 0 end as [Unique]
from CustSales