Forum Replies Created

Viewing 15 posts - 1,831 through 1,845 (of 2,894 total)

  • RE: Simple Insert Stored procedure

    ...

    If i just go with my option #2 or #3 or 4... what can go worng??

    ...

    Nothing. But in all of your cases the error will still be returned as error,...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Simple Insert Stored procedure

    I wouldn't use any one of your's posted.

    It is really depends on what you want your caller to get- Error or Status?

    1. If error, then simpler analogue of your...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Simple Insert Stored procedure

    Lowell (3/22/2012)


    here's a pretty full fleshed model:

    CREATE PROCEDURE EXAMPLEINSERT(

    @Value VARCHAR(30))

    AS

    BEGIN

    BEGIN TRY

    BEGIN TRANSACTION

    ...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Simple Insert Stored procedure

    itskanchanhere (3/22/2012)


    Need to write a simple Insert stored procedure (Single insert)with proper error handling.. The sp should make the insert and return somthing to client application indicating the insert was...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Stored procedure taking more time than expected

    If you would only post stored procedure code...

    Without seeing the code it's impossible to advise anything concrete.

    It may be due to:

    1. Parameter sniffing

    2. Tables require update statistics

    3. Bad code

    and many...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Remove GUID within a String Field

    ...

    It's actually what scalar UDF's were invented for and one of the few places where RBAR actually has the advantage. Of course, I threw in a couple...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Handling Deadlocks

    What about posting the code?

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Creating a text file in SQL Server 2008 on a remote - non domain PC

    The owner of the file is account under which your SQL Server service is running.

    It's pretty bad idea of creating files on remote PC's from SQL Server.

    You can either create...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Joined Update

    tom.mcginty (3/20/2012)


    All,

    Over the years, I've had fits trying to update large tables via join to another table. I currently have a 46 million-record table I need to update via joining...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: MonthToDate function?

    1. http://msdn.microsoft.com/en-us/library/ms186724.aspx

    2. http://www.sqlservercentral.com/articles/Best+Practices/61537/

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: PATINDEX equivalent

    Try to post on MYSQL forum, it should be the one somewhere;-)

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Unexpected table grow .

    ...

    Since your table is a heap, you can either use the drop method or you'll need to add a clustered index.

    ...

    You could also use TRUNCATE to clear the...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: how to initialize datafield to zero instead of NULL

    Create a DEFAULT for your column. You can do it via T-SQL or Table Design in SSMS

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: SSIS 2005 package works but the related SQL 2008 job fails

    I guess you have this step failing due to SQLServer 2008 cannot find your ZIP providing DLL.

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Unexpected table grow .

    Does your table have a clustered index?

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

Viewing 15 posts - 1,831 through 1,845 (of 2,894 total)