There is one more criteria that you missed out on.. The view name cannot be longer than 30 characters. So if the form name is 31 characters or more the view name is truncated to 30 characters. This obviously means there is a chance of duplicate view names if the first 30 characters of two or more forms are the same. In this case, the ending postfix of the view name is appended with the schema id of the form. So the view name is truncated to 30 characters minus the length of the schema id when type casted into characters plus the schema id.
I have a query written to generate view names in case you are using a pre ARS 71. I have however not considered the fact that _x is used to replace database keywords in form names. So I may need to modify that query a bit. Honestly I wasn't aware of that till your email. I had never used database keywords in Form names so had never noticed that. Cheers Joe -----Original Message----- From: Action Request System discussion list(ARSList) [mailto:[email protected]]on Behalf Of RFrench Sent: Friday, December 19, 2008 8:40 AM To: [email protected] Subject: Re: Getting the Current Form Name If you have a look at this thread it will give you some more information http://n2.nabble.com/SQL-Reporing-Services---making-sense-of-Remedy-Table-structure-tt1562658.html#none http://n2.nabble.com/SQL-Reporing-Services---making-sense-of-Remedy-Table-structure-tt1562658.html#none I am not sure if it is possible to take the name of a form and create a query to list the view name. However the form name is very close to the view that the data is stored in. This is what the database reference says about form and view names SQL views For each table that is built in the system (except for the attachment tables), an SQL view is automatically created. This view uses the form name as the view name and the field names (not a display label in one of the views) as the column names. The names are created by using the following rules: All alphabetic and numeric characters remain as defined. All other characters are converted to an underscore (_). If the first character is not alphanumeric, a leading A is added to the name. If the name of a field is blank, a field name with a leading A followed by the fieldId is used. If the name is one of the reserved words for the database, the string _x is appended. No virus found in this outgoing message. Checked by AVG. Version: 7.5.552 / Virus Database: 270.9.19/1859 - Release Date: 12/20/2008 2:34 PM _______________________________________________________________________________ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: "Where the Answers Are"

