Loading ...
Sorry, an error occurred while loading the content.

Re: I am having a syntax problem

Expand Messages
  • billah_norm
    Hi Baskaran!!! here is your solution I think : select shipping_option from lkup_shippingoption where shippingoptionid not in (select shippingoptionid from
    Message 1 of 2 , Sep 19 10:43 PM
    • 0 Attachment
      Hi Baskaran!!!
      here is your solution I think :

      select shipping_option from lkup_shippingoption where shippingoptionid
      not in (select shippingoptionid from productshippingoption where
      productid = 78);

      Cause the subquery needs one operand to return as u defined your where
      clause.

      Try This..



      Thanks
      Mostanser Billah

      --- In phpexperts@yahoogroups.com, bas karan <phpguru05@...> wrote:
      >
      > Hi all,
      >
      > I am having the problem when using the following syntax
      >
      > select shipping_option from lkup_shippingoption where
      shippingoptionid not in
      > (select * from productshippingoption where productid = 78)
      >
      > its showing
      >
      > #1064 - You have an error in your SQL syntax near 'select * from
      productshippingoption where productid = 78) LIMIT 0, 30' at line 2
      >
      > i am using phpmyadmin 2.6.0-pl3 version in lkup_shippingoption
      table i am using
      >
      > shippingoptionid and shipping_option in productshippingoption
      table i am using
      > shippingoptionid,productid and price
      >
      > i am having the situation that, for a product there is a combo
      displaying all the shipping_option, when a user select and save one
      option means, and then in next time if he selects the combo box i want
      to show the remaining shipping_option only i have used the above
      syntax. i don't know what the problem is help me.
      >
      > Advance thanks
      > Baskaran.B
      >
      > Send instant messages to your online friends
      http://uk.messenger.yahoo.com
      >
    Your message has been successfully submitted and would be delivered to recipients shortly.