Results 1 to 19 of 19

Thread: Query report CR11 and VB6 Problem

Hybrid View

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Dec 2006
    Posts
    139

    Re: Query report CR11 and VB6 Problem

    oh yeah .. fixed.. 1 was string and 1 was number.. now working..

    Now another 2 queries

    1) When the parameter value of "stat" is 0 .. i want to show a text like "shipped" somewhere.. how do i do this connection in the report ??

    2) There is another 2 queries.. if the parameter value is 0 then the following query should be run

    Code:
    select order_details.order_id FROM order_details INNER JOIN shipping ON order_details.order_id = shipping.order_id
    else the following should be run ( if parameter "stat" = 1 )

    Code:
    SELECT order_details.order_id FROM order_details WHERE order_details.order_id NOT IN (SELECT shipping.order_id FROM shipping )
    how do i do this codeing in the report in to run seperate queries depending upon the parameter value??

    thanks

  2. #2
    Frenzied Member
    Join Date
    Nov 2001
    Location
    Mass USA
    Posts
    1,674

    Re: Query report CR11 and VB6 Problem

    If you are passing stat to the report you can make a formula field to display different things depending on the parameter.

    Just make a new formula and add a if statement to it.

  3. #3
    Frenzied Member
    Join Date
    Nov 2001
    Location
    Mass USA
    Posts
    1,674

    Re: Query report CR11 and VB6 Problem

    Quote Originally Posted by khandu
    oh yeah .. fixed.. 1 was string and 1 was number.. now working..

    Now another 2 queries

    1) When the parameter value of "stat" is 0 .. i want to show a text like "shipped" somewhere.. how do i do this connection in the report ??

    2) There is another 2 queries.. if the parameter value is 0 then the following query should be run

    Code:
    select order_details.order_id FROM order_details INNER JOIN shipping ON order_details.order_id = shipping.order_id
    else the following should be run ( if parameter "stat" = 1 )

    Code:
    SELECT order_details.order_id FROM order_details WHERE order_details.order_id NOT IN (SELECT shipping.order_id FROM shipping )
    how do i do this codeing in the report in to run seperate queries depending upon the parameter value??

    thanks
    To answer #1 all you have to do is make a formula field with an if statement in it.

    If {?Parameter} = 0 Then
    "Shipped"
    else
    "Not Shipped

    then place the formula field on the report somewhere.

    not sure how to answer #2

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