Viewing 12 posts - 1 through 12 (of 12 total)
Thank you so much! This is an awesome basis on which to finish my query. I have to add a lot of filtering and additional logic in.
Deepest appreciation!
I need...
July 12, 2013 at 11:21 am
Thanks Sean! Deeply appreciated.
I think that's right now, I followed your lead.
July 12, 2013 at 10:36 am
lol @ my fail of replacing the tablename with "Order" I can see how that would cause some problems :blush:
July 12, 2013 at 10:10 am
Yours is much more consumable - is there a reference for the shortcodes? Please forgive my haphazard posting, I sincerely appreciate your help.
July 12, 2013 at 10:02 am
insert myOrder
select 1511,'0080014959',NULL,'11/07/2013',1,1 union all
select 1510,'0080014957',NULL,'11/07/2013',1,1
insert orderITEMS
select 1646,1511,900001,'71034600','13EM10643',1 union all
select 1645,1510,10,'71034600','13EM10643',1
insert shipping
select 177620,400,'0080014959','2013-07-11 00:00:00.000' union all
select 177618,400,'0080014957','2013-07-11 00:00:00.000'
insert shippingArchive
select 4262720,0,400,'71034600',2838356,'13EM10643',1,177618,'2013-07-11 00:00:00.000' union all
select 4262722,0,400,'71034600',2838356,'13EM10643',1,177620,'2013-07-11 00:00:00.000'
July 12, 2013 at 10:01 am
Let me get some better IDs for you - I just used some top IDs
July 12, 2013 at 9:56 am
Thanks for all the help! I feel like I could write this query with just a push in the right direction, but for some reason I'm hitting a brick wall...
July 12, 2013 at 9:56 am
The naming conventions are poor.
The order connects to the shipment via the PO - PO in shipping is the OrderRef1 in the ORDER table
July 12, 2013 at 9:40 am
What do you mean by expected results?
July 12, 2013 at 9:40 am
ORDER
IDOrderRef1OrderDateShippedReceiptSent
1525118111515912/01/201300
1524118111515810/01/201300
orderITEMS
IDOutboundDeliveryIDOrderLineNrItemNumberBatchNrQtyToShip
16631525901715655552Y637N20
1662152420122000600NULL1
shipping
idclientpodate
1776204000080014959 2013-07-11 00:00:00.000
1776184000080014957 2013-07-11 00:00:00.000
shippingArchive
IDOrigIDClientProductCodeLotIDLotQtyStatusIDStatusDate
4262720040071034600283835613EM1064311776182013-07-11 00:00:00.000
4262722040071034600283835613EM1064311776202013-07-11 00:00:00.000
July 12, 2013 at 9:31 am
CREATE TABLE [dbo].[ORDER](
[ID] [int] IDENTITY(1,1) NOT NULL,
[OrderRef1] [varchar](10) NULL,
[OrderRef2] [varchar](10) NULL,
[OrderDate] [varchar](10) NULL,
[Shipped] [bit] NOT NULL,
[ReceiptSent] [bit] NOT NULL,
)
CREATE TABLE [dbo].[orderITEMS](
[ID] [int] IDENTITY(1,1) NOT NULL,
[OutboundDeliveryID] [int] NOT NULL,
[OrderLineNr] [int] NULL,
[ItemNumber]...
July 12, 2013 at 9:23 am
Thanks for getting back to me so quickly!
Is there any quick/easy way to pull these out of SQL Management Stuido, or do I have to hand write these statements for...
July 12, 2013 at 9:02 am
Viewing 12 posts - 1 through 12 (of 12 total)