Forum Replies Created

Viewing 15 posts - 76 through 90 (of 5,502 total)

  • RE: could use some help doing a simple update and/or delete

    What do you mean by Even a simple delete from tablex where id ... will not execute.?

    Is there any error message?



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Casting a dynamic Sql

    You need to apply the cast to varchar inside the dynamic SQL. Otherwise you're only converting the dynaic statement, not the result.

    declare @result varchar(max)

    set @result = ('select cast((select * from...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Casting a dynamic Sql

    What do you mean by "It is not casting to varchar"?

    Do you get any error message?

    Can you provide a test scenario so we can reproduce the result you're getting?



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Need help on Update statment with where condition

    Are you looking for something along those lines?

    WITH cte as

    (

    SELECT DISTINCT cvid FROM [x_ApplyJob] a

    WHERE EXISTS (SELECT 1 FROM [z_JobChecking] c WHERE c.JobCheckingID = a.JobNoticeID)

    )

    UPDATE cv

    SET score...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Need help on Update statment with where condition

    What about the table you mention in your first post? I thought that was the table being updated?

    Looks to me like you are changing your requirements and I still don't...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Need help on Update statment with where condition

    Unfortunately, you didn't answer my question:

    Why would idx=34 get a score of 10?

    It would be a lot easier if the data where in normalized form instead of a separated list....



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Mapping between tables

    Please provide ready to use sample data including your expected result as described in the first link in my signature.

    If possible, in your price table separate the number of days...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Need help on Update statment with where condition

    What are you trying to do?

    Your description is rather vague...

    For instance, what do you mean by

    Where idx=34, Numeric in ApplyJob (3) EXIST in r_ApplyJob --> SET score=10

    ??

    For that idx value...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Are the posted questions getting worse?

    Sean Lange (8/19/2014)


    The amount of spam on this site is just out of control. Something needs to happen or our users are going to go elsewhere. I for one have...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Are the posted questions getting worse?

    Alvin Ramard (8/19/2014)


    ...

    Hang on here! You guys get more than pizza under the door twice a day?????? 😛

    How do you recognize a "day"? You don't have any kind...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Define the columns or fields programmatically from a blank table

    That doesn't sound like a normalized table structure...

    An normalized table would look more like this:

    CREATE TABLE meaningfulName

    (RowId INT IDENTITY(1,1),

    MyReader varchar(50),

    MyReaderPos INT ,

    CONSTRAINT CX_meaningfulName PRIMARY KEY...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: SQL Agent Job using Proxy and run by many users

    You could create a stored procedure with EXECUTE AS using a user having the same login as it is assigned to the proxy being allowed to run the SQL agent...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Table creation policies. Is this silly or is it just me?

    I don't understand the need for the double loop. It should be enough to either provide the table description (including columns) or the CREATE TABLE statement (including permissions and growth...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Convert sql to sqlsrv code

    IF EXISTS (SELECT 1 FROM legalcontracts WHERE con_ContractNumber= @con_ContractNumber)

    PRINT '1'; --If there is a record match in the Database - Not Available

    ELSE

    PRINT '0'; --No Record Found - con_ContractNumber is...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Please help me out in this

    The "hint" might not have put you in the right direction.

    So here's a straight advice: please read and follow the instructions provided in the first link in my signature.

    Ready to...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

Viewing 15 posts - 76 through 90 (of 5,502 total)