Home > Archive > MS SQL Server DTS > January 2006 > multiple Conditions in the EvalExpression in the Forloop









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author multiple Conditions in the EvalExpression in the Forloop
John230873

2006-01-22, 8:23 pm

Is there a way of repersenting this stagement in the EvalExpression

@LoopCounter > @MaxRecordCount OR @RecordCountLeft > 0

@LoopCounter increments 1 each record
@MaxRecordCount is the maximum records that should be in the record set
@RecordCountLeft is the number of records left after the data flow tasks
has run it the forloop

I trying to make sure that the for loop statment doen't stay in the loop is
a record can not be removed.

Also is there a simple task the will allow the user to reasign a value of a
Variable?

Cheers

Allan Mitchell

2006-01-22, 8:23 pm

Hello John230873,


Have you tried

@LoopCounter > @MaxRecordCount || @RecordCountLeft > 0


Allan


> Is there a way of repersenting this stagement in the EvalExpression
>
> @LoopCounter > @MaxRecordCount OR @RecordCountLeft > 0
>
> @LoopCounter increments 1 each record
> @MaxRecordCount is the maximum records that should be in the record
> set
> @RecordCountLeft is the number of records left after the data flow
> tasks
> has run it the forloop
> I trying to make sure that the for loop statment doen't stay in the
> loop is a record can not be removed.
>
> Also is there a simple task the will allow the user to reasign a value
> of a Variable?
>
> Cheers
>



John230873

2006-01-22, 8:23 pm

I have and it didn't give me an error but I thougt || was AND what is a OR ?

"Allan Mitchell" wrote:

> Hello John230873,
>
>
> Have you tried
>
> @LoopCounter > @MaxRecordCount || @RecordCountLeft > 0
>
>
> Allan
>
>
>
>
>

Allan Mitchell

2006-01-22, 8:23 pm

Hello John230873,

|| = OR

&& = AND


Allan


[color=darkred]
> I have and it didn't give me an error but I thougt || was AND what is
> a OR ?
>
> "Allan Mitchell" wrote:
>


John230873

2006-01-22, 8:23 pm

Allan, I have almost finished the SSIS package to move not copy data, I
haven't seen any thing like it and thought maybe it can help other people,
any idea where to post it?


"Allan Mitchell" wrote:

> Hello John230873,
>
> || = OR
>
> && = AND
>
>
> Allan
>
>
>
>
>
>

Allan Mitchell

2006-01-22, 8:23 pm

Hello John230873,

If you think this will help others then why not put it up on wiki.SQLIS.com

Allan



[color=darkred]
> Allan, I have almost finished the SSIS package to move not copy data,
> I haven't seen any thing like it and thought maybe it can help other
> people, any idea where to post it?
>
> "Allan Mitchell" wrote:
>


Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com