Allan,
I have 33 fields in each record and I have to validate each field anyways
and log every single validation error in a seperate table(**NO DOUBT ABOUT
IT**).in my senario the only thing which is added is to check if the
status_code is not set before and if not set it to 1(which mean critical
error).I'd like to use this field for further processing because output of
this step would be input to another DTS package which dose the business
rules on the records which are ok (I mean there is no validation error
occured on them).I know there might be performance issue regarding this
scenario.But this proecess is supposed to be launched at midnigh and for
client what is important is not the performance of the system ,but the
ability to tell them what was wrong (in very detail) with their CSV file
Thanks and sorry for asking lots of questions.Now I have a very bright
underesanding of what I m going to accomplish.
I so appreciate your help.
Ray
[quoted text, click to view] "Allan Mitchell" <allan@no-spam.sqldts.com> wrote in message
news:eYosb7iIFHA.2656@TK2MSFTNGP09.phx.gbl...
> This validation will occur on each Row*Row. You may want to experiment
> with doing this up front of the DataPump task. All your valid Qs recently
> have been based around the Lookup. Remember this operates on EVERY row so
> IMHO does not scale well on large datasets particularly
>
>
> Allan
>
> "RayAll" <RayAll@microsft.com> wrote in message news:RayAll@microsft.com:
>
>> Yes ,you are right ,but I don't want other fields in the same row
>> overwrite
>> the column I have associated with having error status per row.
>>
>> I'd like to write to that field(error status) only once ,because I'm
>> inserting each field's validation error to a seperate table and I want
>> this
>> field only shows that wether there is an error happened in this row or
>> not
>> ,for details I would use the other table.there might be 10 errors per row
>> ,but I want to update this field only once.
>>
>> Dose that make sence?do you have any better suggessions?
>>
>> Thanks for your help
>> "Allan Mitchell" <allan@no-spam.sqldts.com> wrote in message
>> news:OFo$AYWIFHA.1948@TK2MSFTNGP14.phx.gbl...
>> > What type of validation errors?
>> >
>> > You don't need a GV at all as far as I can see
>> >
>> > Say I want to see if Col2 on the Source == 2 and if it is I set
>> > Destination Col3 to 1 and if not I set it to 0
>> >
>> >
>> > DTSDestination("Col2") = DTSSource("Col2")
>> >
>> > If DTSSource("Col2") = 2 THEN
>> > DTSDestination("Col1") = 1
>> > ELSE
>> > DTSDestination("Col1") = 0
>> > END IF
>> >
>> >
>> > If the Source is SQL Server then you do not even need to do it here at
>> > all
>> > you can do it in the SourceSQLStatement
>> >
>> > SELECT
>> > Col2,
>> > CASE WHEN Col2 = 2 THEN 1 ELSE 0 END as Validation
>> > FROM
>> > TABLE
>> >
>> > Make sense?
>> >
>> > Allan
>> >
>> >
>> > "ALI-R" <Ray@Alirezaei.com> wrote in message news:Ray@Alirezaei.com:
>> >
>> >> I have four field in each row:
>> >>
>> >> Field1 Field2 Field3 Field4
>> >>
>> >> I'd like to set my global variable to 1 in Filed1 and if in the other
>> >> fields
>> >> a validation error ocuured I set it to 0 and in the rest because it's
>> >> 0 I
>> >> don't check the validation,but this mechanism should be reset in every
>> >> row.I
>> >> tried it but Data pump task (which I'm using to pump data from a CSV
>> >> file
>> >> into a Table) ,transforms fields in each row ,with no special order (I
>> >> thought fields are transformed from let to right) that's why I came up
>> >> with
>> >> this idea.
>> >>
>> >> Makes sence?
>> >>
>> >> Thanks for your help
>> >>
>> >> "Allan Mitchell" <allan@no-spam.sqldts.com> wrote in message
>> >> news:eu9EuJVIFHA.3696@tk2msftngp13.phx.gbl...
>> >> > Could you elaborate?
>> >> >
>> >> > Reset with what?
>> >> >
>> >> > I am not sure what you are trying to do.
>> >> >
>> >> >
>> >> > "RayAll" <RayAll@microsft.com> wrote in message
>> >> > news:RayAll@microsft.com:
>> >> >
>> >> >> Hi All,
>> >> >>
>> >> >> I'd like to have a global variable which is reset on every row in
>> >> >> my
>> >> >> data
>> >> >> pump task.I tried to reset my global variable in the first first
>> >> >> field
>> >> >> of
>> >> >> my
>> >> >> column mapping in Data pump task ,but to my surprise there is no
>> >> >> order
>> >> >> for
>> >> >> columns to be transfered in each record.
>> >> >>
>> >> >> Any suggessions?
>> >> >>
>> >> >> Thanks
>> >> >
>> >
>