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. Web Development
  3. DropDownList and SQL question

DropDownList and SQL question

Scheduled Pinned Locked Moved Web Development
databasequestionsharepoint
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.
  • I Offline
    I Offline
    Illegal Operation
    wrote on last edited by
    #1

    Hi! I have 2 questions: 1. I have say 2 DropDownList boxes, when I select Product A from the first DropDownList Product A options appear in the second DropDownList and visa versa? 2. How would I write a SP in SQL to check if the value is already in the DB? For instance, if someone wants to add "jeff" then SQL must first check to see if jeff exists. If he exists then SQL must use that value and not add a second jeff. Thanks Guys and Gals! Illegal Operation Making Computer Software Talk

    D 1 Reply Last reply
    0
    • I Illegal Operation

      Hi! I have 2 questions: 1. I have say 2 DropDownList boxes, when I select Product A from the first DropDownList Product A options appear in the second DropDownList and visa versa? 2. How would I write a SP in SQL to check if the value is already in the DB? For instance, if someone wants to add "jeff" then SQL must first check to see if jeff exists. If he exists then SQL must use that value and not add a second jeff. Thanks Guys and Gals! Illegal Operation Making Computer Software Talk

      D Offline
      D Offline
      Divya Rathi
      wrote on last edited by
      #2

      hi I m not telling syntax just the approach 1)in first dropdownlist when u select a product , then retrieve the id of selected item & capture this event of item change . then in this event , retreive the options & populate the second combo 2) for sp create procedure test ( val in , existsval boolean out ) as select count(*) from [table] where value = val if @@rowcount = 0 then /* this value is not there in db */ existsval = false end if return look out for exact syntax of sp Divya Rathi

      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