Please start any new threads on our new site at http://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2008 Forums
 SSIS and Import/Export (2008)
 Import CSV and perform calculations
 Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

1sqlover
Yak Posting Veteran

56 Posts

Posted - 12/04/2013 :  12:10:02  Show Profile  Reply with Quote
Scenario:

[Field1] determines if [Field2] is positive or negative.

If [Field1] has a value of 3 then [Amount] is positive, if [Field1] has a value of 4 then [Amount] is negative.

Currently I am importing a CSV and performing calculations within my reports as described above. I would like to change it that when I import the CSV I perform the calculations on the fields I import the new values.

Is this possible, or is doing this in the report the best method?

Thanks

epoh

visakh16
Very Important crosS Applying yaK Herder

India
52326 Posts

Posted - 12/05/2013 :  02:22:23  Show Profile  Reply with Quote
you can do it during import itself. If in SSIS, you can use Derived column transformation task for this.

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/
https://www.facebook.com/VmBlogs
Go to Top of Page
  Previous Topic Topic Next Topic  
 Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.05 seconds. Powered By: Snitz Forums 2000