Solved

Derived column expression meaning in ssis

Posted on 2011-03-21
2
469 Views
Last Modified: 2012-05-11
Please let me know the actual purpose, I am trying to understand from an existing package
1)ISNULL(ESN) ? (DT_WSTR,50)"Accessories" : "Phone"

2)(DT_DBTimeStamp)((SUBSTRING((DT_WSTR,8)[Receive Date],5,2) + "-" + SUBSTRING((DT_WSTR,8)[Receive Date],7,2) + "-" + SUBSTRING((DT_WSTR,8)[Receive Date],1,4)))

3)ISNULL(ESN) ? REPLACE(SKU,SUBSTRING(SKU,1,FINDSTRING(SKU," ",1)),"") : SKU
0
Comment
Question by:sqlcurious
2 Comments
 
LVL 7

Accepted Solution

by:
lozzamoore earned 500 total points
ID: 35188112
1) If the ESN field is null, then return "Accessories", otherwise return "Phone".

2) Manufacture a datetime string in the format: DD-MM-YYYY (or could be MM-DD-YYYY depending on the original format) setting DD as 5th and 6th characters, MM as 7th and 8th characters, and YYYY as the 1st 4 characters from the "Receive Date" column.

3) If the ESN field is null, then return the first part of the SKU field up to the space, otherwise return the whole field.
0
 

Author Closing Comment

by:sqlcurious
ID: 35191839
thanks
0

Featured Post

Control application downtime with dependency maps

Visualize the interdependencies between application components better with Applications Manager's automated application discovery and dependency mapping feature. Resolve performance issues faster by quickly isolating problematic components.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
replication - alerts? 4 23
Slow SQL query 12 29
add 1 to a field for 100 rows 11 24
SqlAdvisor 2016 3 11
Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
The Delta outage: 650 cancelled flights, more than 1200 delayed flights, thousands of frustrated customers, tens of millions of dollars in damages – plus untold reputational damage to one of the world’s most trusted airlines. All due to a catastroph…
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now