Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Other Discussions
  3. The Weird and The Wonderful
  4. Everything That Has a Beginning Has an End

Everything That Has a Beginning Has an End

Scheduled Pinned Locked Moved The Weird and The Wonderful
question
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    AspDotNetDev
    wrote on last edited by
    #1

    SET @value = SUBSTRING(@sText, 1, CHARINDEX(@sDelim, @sText) -1)
    BEGIN
    INSERT @retArray (idx, value)
    VALUES (@idx, @value)
    END

    ...but why have a BEGIN in the first place? :doh:

    Driven to the ARMs by x86.

    L 1 Reply Last reply
    0
    • A AspDotNetDev

      SET @value = SUBSTRING(@sText, 1, CHARINDEX(@sDelim, @sText) -1)
      BEGIN
      INSERT @retArray (idx, value)
      VALUES (@idx, @value)
      END

      ...but why have a BEGIN in the first place? :doh:

      Driven to the ARMs by x86.

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #2

      Probably, the guy copied part of a code that belonged to an IF statement and forgot to remove the BEGIN.. END, he must have thought 'why disturb the code if it compiles well?'

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups