• Jeff Moden (10/31/2008)


    ry.rith (10/31/2008)


    Thank so much,

    that you tell me about the solution.

    I also do the same of yours to complete the crosstab-report, but something that i want is to know why it's process abnormally.

    any technique, please inform me.

    your faithfully.

    Observe the following line of your code...

    Set @sql=@sql+' WHERE dbo.tab_IC_Packing_List_Detail.PackingListNo='+ char(39)+ @po_no + char(39) + char(13)

    Looks harmless enough until you trace it back to the real problem... which is...

    Alter Proc rsp_IC_PackingList_CrossTab (@po_no [font="Arial Black"]nvarchar[/font](32))

    Ask yourself... what do you get when you concatenate a VARCHAR(8000) with an NVARCHAR of any length? ;)

    "Must look Eye"

    or

    "A DBA has GOT to know his limitations" (with your best dirty Harry impersonation).

    ----------------------------------------------------------------------------------
    Your lack of planning does not constitute an emergency on my part...unless you're my manager...or a director and above...or a really loud-spoken end-user..All right - what was my emergency again?