Forum Replies Created

Viewing 15 posts - 76 through 90 (of 113 total)

  • RE: Want Sorting inside of CTS

    pl try below code..

    declare @My_Test_Temp table(

    [AccountID] [bigint] NULL,

    [CategoryID] [bigint] NULL,

    [RootID] [bigint] NULL,

    [TRNType] [varchar](1) NULL,

    [AcType] [varchar](2) NULL,

    [AcName] [nvarchar](max) NULL,

    [CrDr] [varchar](2) NULL,

    [Active] [int] NULL,

    [Sort_Order] [int] NULL,

    [HasParent] [varchar](1) NULL,

    [Descr] [ntext] NULL,

    [account_Code] [varchar](5)...

  • RE: Help on SQL query

    pls try below code declare @test-2 table (id varchar(10),name varchar(10),sal int,cum_sal int)

    insert into @test-2(id,name,sal)

    select 'C001','Jack',100

    union

    select 'C002','Mick', 500

    union

    select 'C003','Rock', 200

    --update stmt

    update t1 set cum_sal=(select SUM(t.sal)...

  • RE: Help on SQL query

    pls try below code.

    declare @test-2 table (id varchar(10),name varchar(10),sal int,cum_sal int)

    insert into @test-2(id,name,sal)

    select 'C001','Jack',100

    union

    select 'C002','Mick', 500

    union

    select 'C003','Rock', 200

    --update stmt

    update t1 set cum_sal=(select SUM(t.sal) from...

  • RE: Update Query Help

    pls check your where class values .

    you are send values correct or not.

  • RE: optimization of query

    IF IT IS necessary that time you will use order by

    ohter wise no need to use because it is take time.

  • RE: SSRS ISSUE

    i have developed one report in ssrs.

    when i had run that report it was showing out of memory Exception.

    when i was run same query in sql server it was took...

  • RE: Finding and replacing the exact value in TSQL

    pls try belo code.

    CLARE @OrigString VARCHAR(100)

    DECLARE @SearchFor VARCHAR(100)

    DECLARE @ReplaceWith VARCHAR(100)

    SET @SearchFor ='.[Sample]'

    SET @ReplaceWith = '.[Client_Sample]'

    SET @OrigString = 'Newdb.[Sample].dbo.TableName'

    select REPLACE(@OrigString, @SearchFor, @ReplaceWith)

  • RE: Using a Function in a Where clause

    i was told split is function.

    if you will pass any parameter life empid like '1a,1b,1c'

    that time

    how to pass that string in where class.

    select * from emp

    where...

  • RE: select distinct records based on subgroup

    pls try below code.

    select * into #temp from @SAMPLE

    order by SUBGROUP

    select * from

    (select *,row_number() over( partition by amount order by amount asc) rank

    from #temp)k

    ...

  • RE: Using a Function in a Where clause

    any way

    user defined function.

    calling.

    select * emp where empcode in(select * split('1a','1b','1c'))

  • RE: How do I replace ? in a REPLACE function

    select replace(columnname,char(63),'Null')

  • RE: Avoid Junk character in SQL server

    pls first find special character real values after using below code.

    DECLARE @postcode VARCHAR(15)

    SET @postcode = 'asd?'

    select replace(@postcode,CHAR(63),'')

  • RE: Split UK Postcode with SQL Server function

    pls try below code.

    CREATE FUNCTION dbo.fn_leanUtil_PostCodePart

    (

    @PostCode VARCHAR(15) ,

    @Part TINYINT

    )

    -- WhoWhenWhat

    --...

  • RE: Data Delete issue

    pls try below code

    DELETE FROM Emp

    where deptno in( select distinct e1.deptno from emp e1

    INNER JOIN dept

    ON e1.deptno=dept.deptno AND dept.deptno=50)

  • RE: page breaks issue

    Thanks for gave replay.

    i have two data sets is there in report.that two group by common id.

    that why client was asked page breaks commid.

    ex:

    first data set have d1,d2,d3

    second data set...

Viewing 15 posts - 76 through 90 (of 113 total)