SELECT
  RTRIM([Doctype]) AS [doctype],
  RTRIM([Doc Num]) AS [doc_num],
  RTRIM([Original Doc]) AS [original_doc],
  [Doc Date] AS [doc_date],
  [Order Date] AS [order_date],
  [Req Date] AS [req_date],
  [Prom Date] AS [prom_date],
  RTRIM([Cust Num]) AS [cust_num],
  RTRIM([Cust Name]) AS [cust_name],
  RTRIM([Rep ID]) AS [rep_id],
  RTRIM([Rep Name]) AS [rep_name],
  RTRIM([Cust PO]) AS [cust_po],
  RTRIM([_HD_Grower]) AS [hd_grower],
  RTRIM([Origin]) AS [origin],
  RTRIM([Address Code]) AS [address_code],
  RTRIM([State]) AS [state],
  RTRIM([City]) AS [city],
  RTRIM([Cust Channel]) AS [cust_channel],
  RTRIM([Mold ID]) AS [mold_id],
  RTRIM([Item Num]) AS [item_num],
  RTRIM([Item Description]) AS [item_description],
  [Quantity] AS [quantity],
  RTRIM([Collection]) AS [collection],
  RTRIM([Segment]) AS [segment],
  [Unit Price] AS [unit_price],
  [Ext. Price] AS [ext_price],
  [Unit Cost] AS [unit_cost],
  [Ext. Cost] AS [ext_cost],
  [Margin Dollar] AS [margin_dollar],
  [Ext. Margin Dollar] AS [ext_margin_dollar],
  RTRIM([Margin %]) AS [margin_pct],
  RTRIM([Job Number]) AS [job_number],
  RTRIM([Program]) AS [program],
  RTRIM([Container]) AS [container],
  RTRIM([AOP Rep]) AS [aop_rep]
FROM [GPSERVER].[CHG].[dbo].[_custom_sales_line_connector]
