Results 1 to 3 of 3

Thread: Any idea, please?

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Aug 2000
    Posts
    617
    I need to do something like this

    select @string = 'My table'
    CREATE TABLE @string (vchasd varchar(10) null,
    vchfg int null)

    where @string is a variable

    Has any 1 ever done this?
    Can it be done?

    Thanks in advance

    This string variable will be passed to a stored procedure
    as an argument


  2. #2
    Guest

    Wink argument to a stored procedure

    My understanding of your problem is that you want to run a stored procedure with a stringargument, isn't it?

    If yes, U have 2 ways:

    -> easy

    cn.execute "exec Storedprocedurename '"& vbvar & "'"
    that will execute e.g. the following SQL statement:

    exec storedprocedurename 'blablabla'
    (don't forget the single quotes!
    -> annoy me

    create a command object, an parameters collection in that command object, populate your argument and execute the command.

    franckly, the easy is the best on my mind.

    Hope that help.

  3. #3

    Thread Starter
    Fanatic Member
    Join Date
    Aug 2000
    Posts
    617

    Thanks

    Thanks for responding...

    I did describe my intents.. poorly

    But I did find a way to solve what I wanted to....do

    Thanks again for responding VBGURU




Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width