Alpha Video Training
Results 1 to 4 of 4

Thread: Refresh needed somewhere

  1. #1
    Member
    Real Name
    Bruce Roberson
    Join Date
    Mar 2011
    Posts
    88

    Default Refresh needed somewhere

    The code below check to see if a property setup exists in file RRCetc. For those records in texastx1 that are not contained in file RRCetc, it shows a layout of the records that need to be added.

    From this list, I manually go in and add records needed. After I am done with this pass, I need to basically rerun this operation to make sure I get the setups correctly. The problem here is I get the same results I had before I make the additions.

    My question is therefore where do I change this operation to refresh it each time I make corrections and then come back to run this operation?

    Flow should be:

    Check once, get records not listed
    Manually add records
    Check again, report or layout should say so records exist that meet this criteria.


    Thanks,


    Bruce



    dim filter as c
    dim order as c
    dim options as c
    dim description as c
    dim show_all_flag as L
    dim layout_name as c
    dim layout_type as c
    filter = "(.NOT.exist(Propertynumber+tax_cde,\"RRCETC\",\"RRCetc\")) .and. unique_key_value()"
    order = "Propertynumber"
    options = "U"
    description = "Saved Query: Query for No Prop Setups"
    show_all_flag = .f. 'user cannot turn off the query
    layout_type = "browse" 'to open a form, set this to "form"
    layout_name = "" 'This will open the default layout. You can also specify a named layout here
    dim args as sql::arguments
    if eval_valid("arguments") then
    if typeof(arguments) = "P" then
    args = arguments
    end if
    end if
    a5_open_layout(layout_type,layout_name,"texastx1",filter,order,description,options,show_all_flag,args)

  2. #2
    "Certified" Alphaholic Stan Mathews's Avatar
    Real Name
    Stan Mathews
    Join Date
    Apr 2000
    Location
    Bowling Green, KY
    Posts
    25,119

    Default Re: Refresh needed somewhere

    I would try changing

    options = "U"
    to
    options = "M"

    This forces a new query to be run.

    The behavior of the "U" parameter seems unnecessary given your filter only returns unique key values.

  3. #3
    Member
    Real Name
    Bruce Roberson
    Join Date
    Mar 2011
    Posts
    88

    Default Re: Refresh needed somewhere

    Hi Stan, I made that change and pushed the button again. For whatever reason, I got the same results.

    I am not sure I have found the culprit, but this is the filter expression in the query that would be rerun.

    exist(Propertynumber+tax_cde,"RRCETC","RRCetc")

    Is some indicator in file RRCETC not being refreshed that is causing the situation?

    Bruce

  4. #4
    "Certified" Alphaholic Stan Mathews's Avatar
    Real Name
    Stan Mathews
    Join Date
    Apr 2000
    Location
    Bowling Green, KY
    Posts
    25,119

    Default Re: Refresh needed somewhere

    exist() uses the index specified to check for the Propertynumber+tax_cde. As long as the index is up to date the process should work.

    Open the default browse for the table, do a find by Key, see if you can find one of the combinations that keeps reappearing.

Similar Threads

  1. help needed
    By lokiqc in forum Alpha Five Version 8
    Replies: 2
    Last Post: 06-06-2007, 03:19 PM
  2. Serious Help Needed
    By Jared Sutherland in forum Web Application Server v6
    Replies: 1
    Last Post: 05-13-2005, 03:03 PM
  3. Help needed
    By Debbie Bartlett in forum Alpha Five Version 5
    Replies: 15
    Last Post: 01-02-2003, 09:05 AM
  4. Help needed ....
    By drgarytraub in forum Alpha Five Version 4
    Replies: 4
    Last Post: 07-24-2000, 01:17 PM

Bookmarks

Posting Permissions

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