Thanks to all who responded--- tom ----- Original Message ----- From: "David M. Blocker" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, June 28, 2002 10:18 AM Subject: Re: Sorting question
> Tom > > It sounds like you are trying to sort a report and look up data from another > table and then sort by it. Yes? > > If so, you can't sort by the lookup variable. However, your report will run > faster (lookups are slow) AND be sortable if you use a multi-table view. > > A "view" in R:Base is nothing but a save SELECT command. > > If you are not facile with SELECT, R:Base has a great screen to teach you > the syntax so that eventually you can learn to do the more flexible way, by > typing it at the R> prompt. > > Here's how: > > 1. Select Tools / View Designer from the menu or click on Views / New from > the Object Manager > > 2. R:Base prompts either to select a view to change or to enter a new view > name. To create new view, type in the view name here and click on OK. > > This takes you directly to the query screen without first going through the > BROWSE screen. > > 3. Select the first table to link: R:Base usually will figure out the > fastest way to link tables together , so the order you select the tables > doesn't matter. > > Choose the first table under List of Tables and click on Add. > > R:Base places this table in the center and next to it a T1: short for table > 1. > > 4. Add next table. Choose the second table under List of Tables; click on > Add. > > 5. Repeat for each table needed. THERE IS NO LIMIT TO THE NUMBER OF TABLES > YOU CAN SELECT ON THIS SCREEN OR AT THE R> PROMPT! > > 6. Choose the column(s) froyou want to view: You must do this ONE table at a > time: > > a.Click the right mouse button on the first table and choose Select > Column(s) > b.A list of the columns in that table comes up. > c.Double click the Left Mouse button on each column you need from this > table. > d.Click on OK when done for that table > e.Repeat for each table. > > 7. View the Results! Click on either table with the Right Mouse button and > select Browse Query! > > 8. Save the query as a view. Click on the Query icon to return to the Query > screen. Then press [Alt] and choose File - Save view > > To see view names: Type: LIST VIEWS at the R> prompt or click on Views from > the Object Manager. > > Once the view is created, you can treat it as if it were a table. When you > SELECT * FROM viewname, R:Base will perform the SELECT embedded in the view > definition. > > When you build a report, after naming the report, select the VIEW with all > the columns/tables you need for the report as the driving "table/view". > THen lookups are not needed - all the columns are there - and you can sort > by the columns in the other tables when you PRINT. > > David Blocker > > ----- Original Message ----- > From: "Tom Eldred" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Friday, June 28, 2002 6:56 AM > Subject: Sorting question > > > > I am using 6.5++ and am trying to sort our mailing labels according to ZIP > > code. So far I haven't been able to sort and I wonder if this is because > we > > use a look-up to select the mailing address or because the ZIP is included > > in a variable? > > > > so questions.... > > > > Can part of a variable be used as a sort field? > > > > If not is there a way I can auto-expand my city field so that I end > up > > with a "good-looking" label > > (i.e. "city,state,zip" rather than "city > > state,zip") > > > > Is there a way that I can select the sort off of the lookup ZIP? > > The look up zip chooses home or office addresses. The standard > > (default) address is home. > > > > I thank you in advance for your advice... pretty new to Rbase here and > > inherited this database. > > > > tom eldred > > > > ================================================ > > TO SEE MESSAGE POSTING GUIDELINES: > > Send a plain text email to [EMAIL PROTECTED] > > In the message body, put just two words: INTRO rbase-l > > ================================================ > > TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED] > > In the message body, put just two words: UNSUBSCRIBE rbase-l > > ================================================ > > TO SEARCH ARCHIVES: > > http://www.mail-archive.com/rbase-l%40sonetmail.com/ > > > > > ================================================ > TO SEE MESSAGE POSTING GUIDELINES: > Send a plain text email to [EMAIL PROTECTED] > In the message body, put just two words: INTRO rbase-l > ================================================ > TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED] > In the message body, put just two words: UNSUBSCRIBE rbase-l > ================================================ > TO SEARCH ARCHIVES: > http://www.mail-archive.com/rbase-l%40sonetmail.com/ > > ================================================ TO SEE MESSAGE POSTING GUIDELINES: Send a plain text email to [EMAIL PROTECTED] In the message body, put just two words: INTRO rbase-l ================================================ TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED] In the message body, put just two words: UNSUBSCRIBE rbase-l ================================================ TO SEARCH ARCHIVES: http://www.mail-archive.com/rbase-l%40sonetmail.com/
