Subquery returned more than 1 value

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Shals

    #1

    Subquery returned more than 1 value

    Hi,

    I'm using Form and a subform control within that form. Main form is
    getting data from one table(Buildings ) and subform is getting data from
    another table(BldgDataB yFloor). but both the form and subform are
    linked through a child field which is common in both the
    tables(Building Number).

    Now, whenever I close the form I receive an error
    "Subquery returned more than 1 value. This is not permitted when the
    subquery follows =,!=,<,<=,>,>= or when the subquery is used as an
    expression."

    I'm not being able to debug and catch exactly where this error is
    coming. I don't have any stored procedure or trigger written for that
    form or subform.

    Please if any one has faced the same error or has solution to this kind
    of error then do guide me.
    Thanks for any suggestions on how to solve this problem.

  • kingston via AccessMonster.com

    #2
    Re: Subquery returned more than 1 value

    If you've checked the subform control's Link Master Field and Link Child
    Field properties, simply delete the subform. Save the main form. Drop the
    subform back in the design of the main form and use the wizard to create the
    link. HTH

    Shals wrote:
    >Hi,
    >
    >I'm using Form and a subform control within that form. Main form is
    >getting data from one table(Buildings ) and subform is getting data from
    >another table(BldgDataB yFloor). but both the form and subform are
    >linked through a child field which is common in both the
    >tables(Buildin gNumber).
    >
    >Now, whenever I close the form I receive an error
    >"Subquery returned more than 1 value. This is not permitted when the
    >subquery follows =,!=,<,<=,>,>= or when the subquery is used as an
    >expression."
    >
    >I'm not being able to debug and catch exactly where this error is
    >coming. I don't have any stored procedure or trigger written for that
    >form or subform.
    >
    >Please if any one has faced the same error or has solution to this kind
    >of error then do guide me.
    >Thanks for any suggestions on how to solve this problem.
    --
    Message posted via AccessMonster.c om


    Comment

    • Shals

      #3
      Re: Subquery returned more than 1 value

      I tried doing that, but it didn't help :-( anyother suggestions!!!
      kingston via AccessMonster.c om wrote:
      If you've checked the subform control's Link Master Field and Link Child
      Field properties, simply delete the subform. Save the main form. Drop the
      subform back in the design of the main form and use the wizard to create the
      link. HTH
      >
      Shals wrote:
      Hi,

      I'm using Form and a subform control within that form. Main form is
      getting data from one table(Buildings ) and subform is getting data from
      another table(BldgDataB yFloor). but both the form and subform are
      linked through a child field which is common in both the
      tables(Building Number).

      Now, whenever I close the form I receive an error
      "Subquery returned more than 1 value. This is not permitted when the
      subquery follows =,!=,<,<=,>,>= or when the subquery is used as an
      expression."

      I'm not being able to debug and catch exactly where this error is
      coming. I don't have any stored procedure or trigger written for that
      form or subform.

      Please if any one has faced the same error or has solution to this kind
      of error then do guide me.
      Thanks for any suggestions on how to solve this problem.
      >
      --
      Message posted via AccessMonster.c om
      http://www.accessmonster.com/Uwe/For...ccess/200611/1

      Comment

      • kingston via AccessMonster.com

        #4
        Re: Subquery returned more than 1 value

        Did you try recreating the main form too? You have absolutely no code
        attached to either form so it can't be that (although bad code somewhere else
        might be causing a problem - do a compile project to find out). Did you
        check all field and control names for reserved words? Compact and Repair
        probably isn't of any help either. One other thing that you can try is to
        build a query to feed the form instead of relying on Access's subform. I'm
        sorry I can't be of more help.

        Shals wrote:
        >I tried doing that, but it didn't help :-( anyother suggestions!!!
        >If you've checked the subform control's Link Master Field and Link Child
        >Field properties, simply delete the subform. Save the main form. Drop the
        >[quoted text clipped - 25 lines]
        >Message posted via AccessMonster.c om
        >http://www.accessmonster.com/Uwe/For...ccess/200611/1
        --
        Message posted via AccessMonster.c om


        Comment

        Working...