Results 1 to 6 of 6

Thread: Creating views

  1. #1
    Join Date
    Oct 2003
    Posts
    58

    Question Unanswered: Creating views

    Hi all,

    Bit of a SQL server newbie here, I have two tables; Fish (containing Name and ID) and Fishing (containing just a concatonatted FishingID), but to relate the tables i would have to join (reference) the fields in the Fish table ie: fishname and FishID to match the other tables FishingID.

    Every time i concanonate the fishname and FishID in the criteria the view doesent run but if i actually write an example FishingID in the criteria the view runs.

    How do i refernce the fields in the criteria section?

    Jnr

  2. #2
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    You'll get an answer much quicker if you post the DDL of your tables, ssome sample data and the expected results...

    Also what about the SELECT Statement you created....

    My telepathic usb port is clogged....
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  3. #3
    Join Date
    Jun 2003
    Location
    Ohio
    Posts
    12,592
    Provided Answers: 1
    What is the concatennated ID for?

    Something sounds FishyID to me.
    If it's not practically useful, then it's practically useless.

    blindman
    www.chess.com: "sqlblindman"
    www.LobsterShot.blogspot.com

  4. #4
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    Quote Originally Posted by Brett Kaiser
    My telepathic usb port is clogged....
    That is a very good thing!

    -PatP

  5. #5
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    Quote Originally Posted by Pat Phelan
    That is a very good thing!

    -PatP
    Why is that...I was hoping to use it to do all my typing for instead...
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  6. #6
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    You and a telepathic anything sounds like a class 3 SLG (spontaneous lawsuit generator) to me. Between the various forms of harassment, the politicially incorrect thoughts being broadcast, and the ensuing chaos from just having your head opened up to the casual passer-by... Egad!

    -PatP

Posting Permissions

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