Retriving data

Discussion in 'ASP .Net' started by simon, Nov 26, 2003.

  1. simon

    simon Guest

    One simple examle:

    I have SP returnArticle with parameter @artId:

    CREATE PROCEDURE returnArticle
    @artId as int
    AS
    select artText from Articles where artId=@artId

    I was using connection object in asp like this:

    sql="exec returnArticle 1"
    articleText=conn.execute(sql).fields.item(0).Value

    Very simple, I get text with one row of code

    Is there something similar in asp.net

    I don't like command object, there is to many rows of code, with parameters
    add and similar
    What is the best way here in aspNet?

    I tried something with sqlDataAdapter but doesnt work if I have parameter in
    procedure

    Thank you for your answers,
    Simon
     
    simon, Nov 26, 2003
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. george d lake
    Replies:
    0
    Views:
    490
    george d lake
    Aug 29, 2003
  2. sp
    Replies:
    1
    Views:
    433
    Joe Kesselman
    Feb 7, 2006
  3. Ivan S
    Replies:
    4
    Views:
    427
    Ivan S
    Mar 10, 2007
  4. Aneesh a

    retriving data from memo data type of msaccess to asp.net

    Aneesh a, May 7, 2005, in forum: ASP .Net Web Services
    Replies:
    0
    Views:
    113
    Aneesh a
    May 7, 2005
  5. iffy agbim

    Retriving data from Database

    iffy agbim, May 25, 2004, in forum: ASP General
    Replies:
    11
    Views:
    252
    Bob Barrows [MVP]
    May 26, 2004
Loading...

Share This Page