Not Displaying Kit Details on Invoice Form
Interprise Suite Community
 Home          Members     Calendar     Who's On

Welcome Guest ( Login | Register )
        



Not Displaying Kit Details on Invoice Form Expand / Collapse
Message
Posted 1/15/2010 10:16:33 AM Post #318
 

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member
I am trying to modify the standard CustomerInvoiceFormReportView to not display teh details of teh kit.




Can anyone help?

Here is the standard script:

SELECT a.InvoiceCode, cpv.AmountPaidRate AS Value, cpv.PaymentMethod, a.Ref1 AS Reference, a.Ref2 AS Reference2, taxRates.TaxRate AS TaxRate1,
a.TaxRate AS TaxValue, dbo.CreateAddress(a.BillToName, a.BillToCity, a.BillToState, a.BillToAddress, a.BillToPostalCode, a.BillToCounty, a.BillToCountry)
AS BillToNameAndAddress, dbo.CreateAddress(a.ShipToName, a.ShipToCity, a.ShipToState, a.ShipToAddress, a.ShipToPostalCode, a.ShipToCounty, a.ShipToCountry)
AS ShipToNameAndAddress, CASE WHEN ISNULL(a.BillToPhoneExtension, '') = '' THEN ISNULL(a.BillToPhone, '') ELSE ISNULL(a.BillToPhone, '')
+ ' ext ' + ISNULL(a.BillToPhoneExtension, '') END AS BillToPhoneNumber, CASE WHEN ISNULL(a.ShipToPhoneExtension, '') = '' THEN ISNULL(a.ShipToPhone, '')
ELSE ISNULL(a.ShipToPhone, '') + ' ext ' + ISNULL(a.ShipToPhoneExtension, '') END AS ShipToPhoneNumber, g.TaxNumber AS BillToTaxNumber,
h.TaxNumber AS ShipToTaxNumber, a.InvoiceDate, a.DueDate, a.CurrencyCode, a.PaymentTerm, a.ShippingMethod, x_1.ItemName, x_1.LineNum,
CASE WHEN x.ItemName = '' THEN NULL ELSE x.QuantityShipped END AS QuantityShipped, CASE WHEN x.ItemName = '' THEN NULL
ELSE x.QuantityOrdered END AS QuantityOrdered, CASE WHEN x.ItemName = '' THEN NULL ELSE x.QuantityBackOrdered END AS QuantityBackOrdered,
CASE WHEN x.ItemName = '' THEN NULL ELSE x.UnitMeasureCode END AS UnitMeasureCode, x_1.ItemDescription, x_1.TaxCode,
CASE WHEN x.ItemName = '' THEN NULL ELSE x.SalesTaxAmountRate END AS SalesTaxAmountRate, CASE WHEN x.ItemName = '' THEN NULL
ELSE x.SalesPriceRate END AS SalesPriceRate, CASE WHEN x.ItemName = '' THEN NULL ELSE x.Discount END AS DiscountRate,
CASE WHEN x.ItemName = '' THEN NULL ELSE x.NetPriceRate END AS NetPriceRate, CASE WHEN x.ItemName = '' THEN NULL
ELSE x.ExtPriceRate END AS ExtPriceRate, a.SubTotalRate, a.FreightRate, a.OtherRate, a.TaxRate, a.TotalRate, a.AppliedCreditRate, ISNULL(a.CouponDiscountRate,
0) + ISNULL(a.AmountPaidRate, 0) AS AmountPaidRate, a.BalanceRate, a.SubTotalRate + a.FreightRate AS NetValue, c.EntityName, c.EntityEmail, c.EntityFax,
c.EntityFaxExtension, c.ContactCode, c.ContactFullName, c.Email1 AS Email, c.BusinessFax, c.BusinessFaxExtension, a.IsPrinted, a.PrintCount, a.POCode,
ISNULL(EE.WebSiteCode, N'') AS WebSiteCode, x_1.CustomerPO,
'All goods remain the property of' + ' ' + d.CompanyName + ' ' + 'until paid for in full. Standard terms and conditions of sale apply.' AS NameOfCompany,
CASE WHEN ISNULL(a.WebSiteCode, '') = '' THEN d .CompanyName ELSE EE.WebSiteDescription END AS CompanyName, CASE WHEN EE.WebsiteLogo IS NULL
THEN NULL ELSE EE.WebSiteLogo END AS CompanyLogo
FROM dbo.CustomerInvoiceView AS a LEFT OUTER JOIN
(SELECT a.WarehouseCode, a.Warehouse, a.InvoiceCode, a.LineNum + 0.0 AS LineNum, ISNULL(a.ItemName, N'') + NCHAR(13)
+ CASE WHEN ISNULL(a.CustomerItemCode, '') = '' THEN '' ELSE '(' + ISNULL(a.CustomerItemCode, '') + ')' END AS ItemName, a.QuantityOrdered,
a.QuantityAllocated, CASE WHEN ISNULL(a.IsInventoryDescription, 0) = 0 THEN a.InventoryDescription + NCHAR(13)
+ '(' + a.ItemDescription + ')' ELSE a.ItemDescription END AS ItemDescription, a.UnitMeasureCode, a.TaxCode, 0 AS ItemKitDetailLineNum, a.ItemType,
a.QuantityShipped, a.QuantityBackOrdered, a.SalesTaxAmountRate, a.SalesPriceRate, a.Discount, a.NetPriceRate, a.ExtPriceRate, a.CustomerPO
FROM dbo.CustomerInvoice AS b INNER JOIN
dbo.CustomerInvoiceDetailView AS a ON b.InvoiceCode = a.InvoiceCode
WHERE (a.ItemType IN ('Assembly', 'Matrix Item', 'Stock', 'Kit', 'Non-Stock', 'Electronic Download', 'Service')) AND (b.Type = 'Invoice')
UNION ALL
SELECT a.WarehouseCode, a.Warehouse, a.InvoiceCode, a.LineNum + 0.1 AS LineNum, '' AS ItemName, NULL AS QuantityOrdered, NULL AS QuantityAllocated,
CASE WHEN ISNULL(a.IsInventoryDescription, 0) = 0 THEN ISNULL(' - ' + b.ItemDescription, '') ELSE ISNULL(' - ' + b.ItemDescription, '')
END AS ItemDescription, '' AS UnitMeasureCode, '' AS TaxCode, b.ItemKitDetailLineNum, a.ItemType, NULL AS QuantityShipped, NULL
AS QuantityBackOrdered, NULL AS SalesTaxAmountRate, NULL AS SalesPriceRate, NULL AS Discount, NULL AS NetPriceRate, NULL AS ExtPriceRate,
a.CustomerPO
FROM dbo.CustomerInvoice AS c INNER JOIN
dbo.CustomerInvoiceDetailView AS a ON a.InvoiceCode = c.InvoiceCode INNER JOIN
dbo.CustomerItemKitDetailView AS b ON a.ItemCode = b.ItemKitCode AND a.InvoiceCode = b.DocumentCode AND a.LineNum = b.LineNum
WHERE (c.Type = 'Invoice')) AS x_1 ON a.InvoiceCode = x_1.InvoiceCode LEFT OUTER JOIN
(SELECT a.TaxCode, SUM(c.TaxRate) AS TaxRate
FROM dbo.SystemTaxScheme AS a INNER JOIN
dbo.SystemTaxSchemeDetail AS b ON a.TaxCode = b.TaxCode INNER JOIN
dbo.SystemTaxDetail AS c ON b.TaxDetailCode = c.TaxDetailCode
GROUP BY a.TaxCode) AS taxRates ON x_1.TaxCode = taxRates.TaxCode LEFT OUTER JOIN
(SELECT x.SalesOrderCode, x.PaymentMethod, SUM(x.AmountPaidRate) AS AmountPaidRate
FROM dbo.CustomerPaymentView AS x INNER JOIN
dbo.CustomerTransactionReceipt AS y ON x.SalesOrderCode = y.DocumentCode AND x.ReceivableCode = y.ReceivableCode
GROUP BY x.SalesOrderCode, x.PaymentMethod) AS cpv ON a.InvoiceCode = cpv.SalesOrderCode LEFT OUTER JOIN
dbo.CRMContactView AS c ON a.ContactCode = c.ContactCode INNER JOIN
dbo.Customer AS g ON a.BillToCode = g.CustomerCode INNER JOIN
dbo.CustomerShipTo AS h ON a.ShipToCode = h.ShipToCode LEFT OUTER JOIN
(SELECT WebSiteCode, WebSiteLogo, WebSiteDescription
FROM dbo.WebSite) AS EE ON a.WebSiteCode = EE.WebSiteCode CROSS JOIN
dbo.SystemCompanyInformation AS d
WHERE (a.Type = 'Invoice')


If I scripot a new one like this:

SELECT a.InvoiceCode, cpv.AmountPaidRate AS Value, cpv.PaymentMethod, a.Ref1 AS Reference, a.Ref2 AS Reference2, taxRates.TaxRate AS TaxRate1,
a.TaxRate AS TaxValue, dbo.CreateAddress(a.BillToName, a.BillToCity, a.BillToState, a.BillToAddress, a.BillToPostalCode, a.BillToCounty, a.BillToCountry)
AS BillToNameAndAddress, dbo.CreateAddress(a.ShipToName, a.ShipToCity, a.ShipToState, a.ShipToAddress, a.ShipToPostalCode, a.ShipToCounty, a.ShipToCountry)
AS ShipToNameAndAddress, CASE WHEN ISNULL(a.BillToPhoneExtension, '') = '' THEN ISNULL(a.BillToPhone, '') ELSE ISNULL(a.BillToPhone, '')
+ ' ext ' + ISNULL(a.BillToPhoneExtension, '') END AS BillToPhoneNumber, CASE WHEN ISNULL(a.ShipToPhoneExtension, '') = '' THEN ISNULL(a.ShipToPhone, '')
ELSE ISNULL(a.ShipToPhone, '') + ' ext ' + ISNULL(a.ShipToPhoneExtension, '') END AS ShipToPhoneNumber, g.TaxNumber AS BillToTaxNumber,
h.TaxNumber AS ShipToTaxNumber, a.InvoiceDate, a.DueDate, a.CurrencyCode, a.PaymentTerm, a.ShippingMethod, x_1.ItemName, x_1.LineNum,
CASE WHEN x.ItemName = '' THEN NULL ELSE x.QuantityShipped END AS QuantityShipped, CASE WHEN x.ItemName = '' THEN NULL
ELSE x.QuantityOrdered END AS QuantityOrdered, CASE WHEN x.ItemName = '' THEN NULL ELSE x.QuantityBackOrdered END AS QuantityBackOrdered,
CASE WHEN x.ItemName = '' THEN NULL ELSE x.UnitMeasureCode END AS UnitMeasureCode, x_1.ItemDescription, x_1.TaxCode,
CASE WHEN x.ItemName = '' THEN NULL ELSE x.SalesTaxAmountRate END AS SalesTaxAmountRate, CASE WHEN x.ItemName = '' THEN NULL
ELSE x.SalesPriceRate END AS SalesPriceRate, CASE WHEN x.ItemName = '' THEN NULL ELSE x.Discount END AS DiscountRate,
CASE WHEN x.ItemName = '' THEN NULL ELSE x.NetPriceRate END AS NetPriceRate, CASE WHEN x.ItemName = '' THEN NULL
ELSE x.ExtPriceRate END AS ExtPriceRate, a.SubTotalRate, a.FreightRate, a.OtherRate, a.TaxRate, a.TotalRate, a.AppliedCreditRate, ISNULL(a.CouponDiscountRate,
0) + ISNULL(a.AmountPaidRate, 0) AS AmountPaidRate, a.BalanceRate, a.SubTotalRate + a.FreightRate AS NetValue, c.EntityName, c.EntityEmail, c.EntityFax,
c.EntityFaxExtension, c.ContactCode, c.ContactFullName, c.Email1 AS Email, c.BusinessFax, c.BusinessFaxExtension, a.IsPrinted, a.PrintCount, a.POCode,
ISNULL(EE.WebSiteCode, N'') AS WebSiteCode, x_1.CustomerPO,
'All goods remain the property of' + ' ' + d.CompanyName + ' ' + 'until paid for in full. Standard terms and conditions of sale apply.' AS NameOfCompany,
CASE WHEN ISNULL(a.WebSiteCode, '') = '' THEN d .CompanyName ELSE EE.WebSiteDescription END AS CompanyName, CASE WHEN EE.WebsiteLogo IS NULL
THEN NULL ELSE EE.WebSiteLogo END AS CompanyLogo
FROM dbo.CustomerInvoiceView AS a LEFT OUTER JOIN
(SELECT a.WarehouseCode, a.Warehouse, a.InvoiceCode, a.LineNum + 0.0 AS LineNum, ISNULL(a.ItemName, N'') + NCHAR(13)
+ CASE WHEN ISNULL(a.CustomerItemCode, '') = '' THEN '' ELSE '(' + ISNULL(a.CustomerItemCode, '') + ')' END AS ItemName, a.QuantityOrdered,
a.QuantityAllocated, CASE WHEN ISNULL(a.IsInventoryDescription, 0) = 0 THEN a.InventoryDescription + NCHAR(13)
+ '(' + a.ItemDescription + ')' ELSE a.ItemDescription END AS ItemDescription, a.UnitMeasureCode, a.TaxCode, 0 AS ItemKitDetailLineNum, a.ItemType,
a.QuantityShipped, a.QuantityBackOrdered, a.SalesTaxAmountRate, a.SalesPriceRate, a.Discount, a.NetPriceRate, a.ExtPriceRate, a.CustomerPO
FROM dbo.CustomerInvoice AS b INNER JOIN
dbo.CustomerInvoiceDetailView AS a ON b.InvoiceCode = a.InvoiceCode
WHERE (a.ItemType IN ('Assembly', 'Matrix Item', 'Stock', 'Kit', 'Non-Stock', 'Electronic Download', 'Service')) AND (b.Type = 'Invoice')
UNION ALL
SELECT a.WarehouseCode, a.Warehouse, a.InvoiceCode, a.LineNum + 0.1 AS LineNum, '' AS ItemName, NULL AS QuantityOrdered, NULL AS QuantityAllocated,
CASE WHEN ISNULL(a.IsInventoryDescription, 0) = 0 THEN ISNULL(' - ' + b.ItemDescription, '') ELSE ISNULL(' - ' + b.ItemDescription, '')
END AS ItemDescription, '' AS UnitMeasureCode, '' AS TaxCode, b.ItemKitDetailLineNum, a.ItemType, NULL AS QuantityShipped, NULL
AS QuantityBackOrdered, NULL AS SalesTaxAmountRate, NULL AS SalesPriceRate, NULL AS Discount, NULL AS NetPriceRate, NULL AS ExtPriceRate,
a.CustomerPO
FROM dbo.CustomerInvoice AS c INNER JOIN
dbo.CustomerInvoiceDetailView AS a ON a.InvoiceCode = c.InvoiceCode INNER JOIN
dbo.CustomerItemKitDetailView AS b ON a.ItemCode = b.ItemKitCode AND a.InvoiceCode = b.DocumentCode AND a.LineNum = b.LineNum+'9999'
WHERE (c.Type = 'Invoice')) AS x_1 ON a.InvoiceCode = x_1.InvoiceCode LEFT OUTER JOIN
(SELECT a.TaxCode, SUM(c.TaxRate) AS TaxRate
FROM dbo.SystemTaxScheme AS a INNER JOIN
dbo.SystemTaxSchemeDetail AS b ON a.TaxCode = b.TaxCode INNER JOIN
dbo.SystemTaxDetail AS c ON b.TaxDetailCode = c.TaxDetailCode
GROUP BY a.TaxCode) AS taxRates ON x_1.TaxCode = taxRates.TaxCode LEFT OUTER JOIN
(SELECT x.SalesOrderCode, x.PaymentMethod, SUM(x.AmountPaidRate) AS AmountPaidRate
FROM dbo.CustomerPaymentView AS x INNER JOIN
dbo.CustomerTransactionReceipt AS y ON x.SalesOrderCode = y.DocumentCode AND x.ReceivableCode = y.ReceivableCode
GROUP BY x.SalesOrderCode, x.PaymentMethod) AS cpv ON a.InvoiceCode = cpv.SalesOrderCode LEFT OUTER JOIN
dbo.CRMContactView AS c ON a.ContactCode = c.ContactCode INNER JOIN
dbo.Customer AS g ON a.BillToCode = g.CustomerCode INNER JOIN
dbo.CustomerShipTo AS h ON a.ShipToCode = h.ShipToCode LEFT OUTER JOIN
(SELECT WebSiteCode, WebSiteLogo, WebSiteDescription
FROM dbo.WebSite) AS EE ON a.WebSiteCode = EE.WebSiteCode CROSS JOIN
dbo.SystemCompanyInformation AS d
WHERE (a.Type = 'Invoice')

it works in the query but will not let me save it.

Any ideas?


Mark B Littman

Innovative ERP Solutions Inc.

Chief Information Officer (CIO)

9848 SW Glenbrook Dr.

Port Saint Lucie, FL 34987

Main Tel: 772-336-2831

mlittman@ierps.com

http://www.ierps.com



LinkedIn Profile

http://www.linkedin.com/in/markblittman

See who we know in common
Posted 1/16/2010 6:36:02 PM Post #320
 

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member
Try this - hopefully you get the result you need - changed binding field from table x to x_1: :

SELECT     a.InvoiceCode, cpv.AmountPaidRate AS Value, cpv.PaymentMethod, a.Ref1 AS Reference, a.Ref2 AS Reference2, taxRates.TaxRate AS TaxRate1,
                      a.TaxRate AS TaxValue, dbo.CreateAddress(a.BillToName, a.BillToCity, a.BillToState, a.BillToAddress, a.BillToPostalCode, a.BillToCounty, a.BillToCountry)
                      AS BillToNameAndAddress, dbo.CreateAddress(a.ShipToName, a.ShipToCity, a.ShipToState, a.ShipToAddress, a.ShipToPostalCode, a.ShipToCounty, a.ShipToCountry)
                      AS ShipToNameAndAddress, CASE WHEN ISNULL(a.BillToPhoneExtension, '') = '' THEN ISNULL(a.BillToPhone, '') ELSE ISNULL(a.BillToPhone, '')
                      + ' ext ' + ISNULL(a.BillToPhoneExtension, '') END AS BillToPhoneNumber, CASE WHEN ISNULL(a.ShipToPhoneExtension, '') = '' THEN ISNULL(a.ShipToPhone, '')
                      ELSE ISNULL(a.ShipToPhone, '') + ' ext ' + ISNULL(a.ShipToPhoneExtension, '') END AS ShipToPhoneNumber, g.TaxNumber AS BillToTaxNumber,
                      h.TaxNumber AS ShipToTaxNumber, a.InvoiceDate, a.DueDate, a.CurrencyCode, a.PaymentTerm, a.ShippingMethod, x_1.ItemName, x_1.LineNum,
                      CASE WHEN x_1.ItemName = '' THEN NULL ELSE x_1.QuantityShipped END AS QuantityShipped, CASE WHEN x_1.ItemName = '' THEN NULL
                      ELSE x_1.QuantityOrdered END AS QuantityOrdered, CASE WHEN x_1.ItemName = '' THEN NULL ELSE x_1.QuantityBackOrdered END AS QuantityBackOrdered,
                      CASE WHEN x_1.ItemName = '' THEN NULL ELSE x_1.UnitMeasureCode END AS UnitMeasureCode, x_1.ItemDescription, x_1.TaxCode,
                      CASE WHEN x_1.ItemName = '' THEN NULL ELSE x_1.SalesTaxAmountRate END AS SalesTaxAmountRate, CASE WHEN x_1.ItemName = '' THEN NULL
                      ELSE x_1.SalesPriceRate END AS SalesPriceRate, CASE WHEN x_1.ItemName = '' THEN NULL ELSE x_1.Discount END AS DiscountRate,
                      CASE WHEN x_1.ItemName = '' THEN NULL ELSE x_1.NetPriceRate END AS NetPriceRate, CASE WHEN x_1.ItemName = '' THEN NULL
                      ELSE x_1.ExtPriceRate END AS ExtPriceRate, a.SubTotalRate, a.FreightRate, a.OtherRate, a.TaxRate, a.TotalRate, a.AppliedCreditRate,
                      ISNULL(a.CouponDiscountRate, 0) + ISNULL(a.AmountPaidRate, 0) AS AmountPaidRate, a.BalanceRate, a.SubTotalRate + a.FreightRate AS NetValue, c.EntityName,
                      c.EntityEmail, c.EntityFax, c.EntityFaxExtension, c.ContactCode, c.ContactFullName, c.Email1 AS Email, c.BusinessFax, c.BusinessFaxExtension, a.IsPrinted,
                      a.PrintCount, a.POCode, ISNULL(EE.WebSiteCode, N'') AS WebSiteCode, x_1.CustomerPO,
                      'All goods remain the property of' + ' ' + d.CompanyName + ' ' + 'until paid for in full. Standard terms and conditions of sale apply.' AS NameOfCompany,
                      CASE WHEN ISNULL(a.WebSiteCode, '') = '' THEN d .CompanyName ELSE EE.WebSiteDescription END AS CompanyName, CASE WHEN EE.WebsiteLogo IS NULL
                      THEN NULL ELSE EE.WebSiteLogo END AS CompanyLogo
FROM         dbo.CustomerInvoiceView AS a LEFT OUTER JOIN
                          (SELECT     a.WarehouseCode, a.Warehouse, a.InvoiceCode, a.LineNum + 0.0 AS LineNum, ISNULL(a.ItemName, N'') + NCHAR(13)
                                                   + CASE WHEN ISNULL(a.CustomerItemCode, '') = '' THEN '' ELSE '(' + ISNULL(a.CustomerItemCode, '') + ')' END AS ItemName, a.QuantityOrdered,
                                                   a.QuantityAllocated, CASE WHEN ISNULL(a.IsInventoryDescription, 0) = 0 THEN a.InventoryDescription + NCHAR(13)
                                                   + '(' + a.ItemDescription + ')' ELSE a.ItemDescription END AS ItemDescription, a.UnitMeasureCode, a.TaxCode, 0 AS ItemKitDetailLineNum, a.ItemType,
                                                   a.QuantityShipped, a.QuantityBackOrdered, a.SalesTaxAmountRate, a.SalesPriceRate, a.Discount, a.NetPriceRate, a.ExtPriceRate, a.CustomerPO
                            FROM          dbo.CustomerInvoice AS b INNER JOIN
                                                   dbo.CustomerInvoiceDetailView AS a ON b.InvoiceCode = a.InvoiceCode
                            WHERE      (a.ItemType IN ('Assembly', 'Matrix Item', 'Stock', 'Kit', 'Non-Stock', 'Electronic Download', 'Service')) AND (b.Type = 'Invoice')
                            UNION ALL
                            SELECT     a.WarehouseCode, a.Warehouse, a.InvoiceCode, a.LineNum + 0.1 AS LineNum, '' AS ItemName, NULL AS QuantityOrdered, NULL AS QuantityAllocated,
                                                  CASE WHEN ISNULL(a.IsInventoryDescription, 0) = 0 THEN ISNULL(' - ' + b.ItemDescription, '') ELSE ISNULL(' - ' + b.ItemDescription, '')
                                                  END AS ItemDescription, '' AS UnitMeasureCode, '' AS TaxCode, b.ItemKitDetailLineNum, a.ItemType, NULL AS QuantityShipped, NULL
                                                  AS QuantityBackOrdered, NULL AS SalesTaxAmountRate, NULL AS SalesPriceRate, NULL AS Discount, NULL AS NetPriceRate, NULL AS ExtPriceRate,
                                                  a.CustomerPO
                            FROM         dbo.CustomerInvoice AS c INNER JOIN
                                                  dbo.CustomerInvoiceDetailView AS a ON a.InvoiceCode = c.InvoiceCode INNER JOIN
                                                  dbo.CustomerItemKitDetailView AS b ON a.ItemCode = b.ItemKitCode AND a.InvoiceCode = b.DocumentCode AND a.LineNum = b.LineNum + '9999'
                            WHERE     (c.Type = 'Invoice')) AS x_1 ON a.InvoiceCode = x_1.InvoiceCode LEFT OUTER JOIN
                          (SELECT     a.TaxCode, SUM(c.TaxRate) AS TaxRate
                            FROM          dbo.SystemTaxScheme AS a INNER JOIN
                                                   dbo.SystemTaxSchemeDetail AS b ON a.TaxCode = b.TaxCode INNER JOIN
                                                   dbo.SystemTaxDetail AS c ON b.TaxDetailCode = c.TaxDetailCode
                            GROUP BY a.TaxCode) AS taxRates ON x_1.TaxCode = taxRates.TaxCode LEFT OUTER JOIN
                          (SELECT     x.SalesOrderCode, x.PaymentMethod, SUM(x.AmountPaidRate) AS AmountPaidRate
                            FROM          dbo.CustomerPaymentView AS x INNER JOIN
                                                   dbo.CustomerTransactionReceipt AS y ON x.SalesOrderCode = y.DocumentCode AND x.ReceivableCode = y.ReceivableCode
                            GROUP BY x.SalesOrderCode, x.PaymentMethod) AS cpv ON a.InvoiceCode = cpv.SalesOrderCode LEFT OUTER JOIN
                      dbo.CRMContactView AS c ON a.ContactCode = c.ContactCode INNER JOIN
                      dbo.Customer AS g ON a.BillToCode = g.CustomerCode INNER JOIN
                      dbo.CustomerShipTo AS h ON a.ShipToCode = h.ShipToCode LEFT OUTER JOIN
                          (SELECT     WebSiteCode, WebSiteLogo, WebSiteDescription
                            FROM          dbo.WebSite) AS EE ON a.WebSiteCode = EE.WebSiteCode CROSS JOIN
                      dbo.SystemCompanyInformation AS d
WHERE     (a.Type = 'Invoice')

Posted 1/17/2010 11:52:19 AM Post #321
 

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member
That worked great ....thanks.

Mark B Littman

Innovative ERP Solutions Inc.

Chief Information Officer (CIO)

9848 SW Glenbrook Dr.

Port Saint Lucie, FL 34987

Main Tel: 772-336-2831

mlittman@ierps.com

http://www.ierps.com



LinkedIn Profile

http://www.linkedin.com/in/markblittman

See who we know in common
« Prev Topic | Next Topic »


Reading This Topic Expand / Collapse
Active Users: 0 (0 guests, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: Bill Dimes, John Grande, BJ Dimes, Terry Palmer

Permissions Expand / Collapse

All times are GMT -8:00, Time now is 4:38am

Powered By InstantForum.NET v4.1.4 © 2010
Execution: 0.016. 8 queries. Compression Disabled.
Email Newsletter icon, E-mail Newsletter icon, Email List icon, E-mail List icon Sign up for our Email Newsletter

Links to our Sponsors

DimeSoft Business Solutions Logo Interprise Suite Plugins Logo Logo Ad

Recent DimeSoft Blog Posts

Recent InfoSourcing Blog Posts

Recent Premier Blog Posts