Forum Replies Created

Viewing 15 posts - 541 through 555 (of 595 total)

  • RE: Is this possible....

    Working with your example, I came up with:

    DROP TABLE myData

    GO

    SET NOCOUNT ON

    CREATE TABLE myData

    (

      id int PRIMARY KEY,

      index1 int,

      index2 int,

      value varchar(50)

    )

    INSERT myData (id, index1, index2,...

  • RE: Word docs with Access frontend and SQL backend

    You didn't mention previously you were using DTS. Are you connecting to an Access database, then transferring all of the data to SQL Server using a DTS package?  Was that a...

  • RE: Word docs with Access frontend and SQL backend

    Powerbuilder is a development environment/language produced by Sybase, Inc. (from whom Microsoft used to license SQL Server code, through version 4.21a). My point was that I thought I did something...

  • RE: Word docs with Access frontend and SQL backend

    Bryan,

    I have a couple of databases in which I store Word documents that are stored and retrieved from within a Powerbuilder application.

    Have you verified that you have the necessary indexes...

  • RE: Transaction Error

    Yes, if an error occurs in UPDATE tblTemp1 (after saving T1), then you jump to your error handler without committing or rolling back transaction ABC. Same thing could happen with...

  • RE: Transaction Error

    SET NOCOUNT ON | OFF can be used anywhere as many times as you want.

    GO is a batch separator, so any local variables created with DECLARE are release when you...

  • RE: FTP of ASCII file using DTS

    You are correct, I don't see anyway to specify ASCII or BINARY in DTS.

    I have two simple DTS packages, each containing a single FTP task. One task transfers a self-extracting archive...

  • RE: CREATE VIEW doesnt like a join to another DB?

    Actually, if you saved the example script as "createscript.sql", you could execute the following from a command prompt, or place the following statements into a Windows batch file. The batch...

  • RE: CREATE VIEW doesnt like a join to another DB?

    If you are running this interactively, and not as a job, then use could use Query Analyzer to generate a script to create all of the views, then cut and...

  • RE: Need Help removing leading tab

    >>

    "SELECT @tabremove = RIGHT(@stringWithTab, LEN(@strWithTab) - LEN(chr(9)))" . . . doesn't work because the "chr" function on the end should be "char".

    >>

    I showed the Char() correction in my previous example,...

  • RE: Need Help removing leading tab

    Try:

    SELECT @tabremove = RIGHT(@stringWithTab, LEN(@stringWithTab) - LEN(CHAR(9)))

    To handle blank or null @stringWithTab values, try

    SELECT @tabremove = CASE WHEN @stringWithTab = '' OR @stringWithTab IS NULL THEN @stringWithTab ELSE RIGHT(@stringWithTab, LEN(@stringWithTab)...

  • RE: Odd date appearing

    The problem may be that the source dates your are inserting are not actually null, but blank strings.  For example, this happens frequently when importing FoxPro or dBase data though...

  • RE: URLDecode or Hex to ASCI Char

    Here's a possible solution using two UDF's, dbo.fnHex2Int and dbo.fnURLDecode:

    -- Example:

    -- SELECT dbo.fnURLDecode ('http://www.sqlservercentral.com/forums/shwmessage.aspx?messageid=113594')

    -- SELECT dbo.fnURLDecode ('http://www.sql%20server%20central.com/forums/shwmessage.aspx?messageid=113594')

    GO

    CREATE FUNCTION dbo.fnHex2Int

    (

      @hexNum varchar(20)

    )

    RETURNS int

    AS

    BEGIN

      DECLARE @hexdigits varchar(16), @next char(1), @num int, @multiplier...

  • RE: "IN Clause" Stored Procedure

    You cannot place a list of values in a variable for the IN clause: Mon in (@mon)

    To use @mon, you would have to resort to dynamic...

  • RE: Taking parsed string and assigning variables without using a temp table

    I use the following procedure, uspGetToken, to return the first substring. The original source string is modified by stripping the first token and the first delimiter string (which can be...

Viewing 15 posts - 541 through 555 (of 595 total)