Forum Replies Created

Viewing 4 posts - 1 through 4 (of 4 total)

  • RE: How to use MAX() function when NULL is returned

    Thank you athiraviam,

    That is the solution to my problem.

    I did try the same thing before I posted this problem and it did not work. Most probably I was mistyping...

  • RE: WHILE loop returns only result of the first pass

    Dave,

    Thank you so much for your support.

    I have found the culprit!

    It was line in C# code where input parameter was cast into SQL equivalent:

    cmd.Parameters.Add("@PageSize", SqlDbType.Bit).Value = pageSize;

    instead of:

    cmd.Parameters.Add("@PageSize", SqlDbType.Int).Value =...

  • RE: WHILE loop returns only result of the first pass

    I did confirm equality of all parameters. Anyway, if there was mismatch I would not expect to get the first row of proper result set.

  • RE: WHILE loop returns only result of the first pass

    Here is the code used during testing

    SET ANSI_NULLS ON

    GO

    SET QUOTED_IDENTIFIER ON

    GO

    ALTER PROCEDURE [dbo].[grhr_Article_GetObjectTypeObjects]

    @ObjectTypeint,

    @PublishedOnlybit = 'false',

    @MaxTextFieldLengthint,

    @SortExpressionnvarchar(256) = ' AddedDate DESC ',

    @PageIndexint = 0,

    @PageSizeint = 100

    AS

    BEGIN

    SET NOCOUNT ON;

    DECLARE @PageLowerBound...

Viewing 4 posts - 1 through 4 (of 4 total)