Clive, Emmitt, Razzak, MDRD Thanks for the ideas. Declaring vars in a ViewVars so they are in memory before reloading makes sense and seems easy. Using Emmitt's idea of moving to temp views would also work for most situations. Most of our reports use views based on 1-2 tables which are pretty simple. I do have several large ones (12-18 pages) packed with hundreds of text, note, and integer data items from 18 different tables with heavy use of views, regions and subs. You have given plenty of new ideas to work on. I appreciate it.
Tom Frederick Elm City Center 1314 W Walnut Jacksonville, IL 62650 O - 217-245-9504 F- 217-245-2350 Email - [email protected] -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of MDRD Sent: Monday, April 19, 2010 7:33 AM To: RBASE-L Mailing List Subject: [RBASE-L] - Re: Variables in views for reports Tom I had the same problem a long time ago. I have command files that run Pack or Unload All routines. In the command file I Run ViewVars in Prog.apx then do the Unload All. The ViewVars sets all the Vars needed for my Views. Also, I have not had time to go back and convert them to Temp Views yet, maybe one day. Marc -------------------------------------------------- From: "Tom Frederick" <[email protected]> Sent: Sunday, April 18, 2010 8:37 PM To: "RBASE-L Mailing List" <[email protected]> Subject: [RBASE-L] - Variables in views for reports > We use views for most reports and it works great. Some of these get very > big so I started using variables in the WHERE statement like this : 'WHERE > T1.MedCurrentYN = 'Y' AND T1.ZID = (.vZID)' simply to cut down on volume > sent over the LAN particularly for some slower computers. This WHERE pulls > current medications for one particular person. Works like a charm. Usually > get 2-15 rows compared to 300+ without the .vZID, 95% of which is not > needed. In database maintenance routines, PACK and RELOADs work without a > hitch. When rebuilding the database after an unload, the error message > 'unrecognized global variable in expression (2161)' pops up and the view > never reloads. If I eliminate .vZID, the rebuild runs just fine with the > changed view in place. Put .vZID back in and the error returns. I could > use this variable approach in 20-30 views but I really need them to > rebuild after an unload. Retyping holds no appeal. > > As we move to more wireless operations, I will have more staff using > laptops away from our offices to get notes and reports done immediately > using a satellite connection. These are Medicaid services and you do not > get paid for writing reports back in the office. You create them while you > are with the person. In our office, I can live with 300 view rows of > something because the LAN is pretty quick. In an apartment with a > satellite connection, 300 rows of data slows the database to a crawl. > > I realize this can be done using TEMP tables, but I really like the > benefits of using views. I am also trying very hard to stay consistent in > how the database works because I am not the only one doing the > programming. Based on the error message, is there some way to declare the > variable during the unload/rebuild process so view based variables simply > work like they do in PACK and RELOAD? > > Tom Frederick > Jacksonville, IL > >

