Question: I can't seem to get Acu4GL to create the files in Microsoft SQL Server. They keep coming up as Vision files.
Answer: Check to see that the DEFAULT-HOST variable is set in the runtime
configuration file or the environment. Setting DEFAULT-HOST in the environment
overrides the setting in the runtime configuration file.
Type wruncbl -vv and make sure that the version number of the Microsoft SQL
Server interface is reported. This tells you that the interface has been
installed successfully. If -vv does not return the Microsoft SQL Server interface
information, make sure the linked runtime has the name you used, and is the first
so-named executable on the PATH.
If you cannot locate a runtime that displays a Microsoft SQL Server interface
version number using -vv, you will have to create one by re-linking the runtime.
If you need to do that, call Acucorp Technical Support.
Question: Can I use both Microsoft SQL Server and Vision at the same time?
Answer: Yes, you can. In the runtime configuration file, set DEFAULT-HOST to the
file system you want the runtime to use automatically. Then, for selected
files, assign them to an alternate file system with the variable filename-HOST. For
example, to put CUSTFILE into Microsoft SQL Server and everything else into
Vision, you would add:
DEFAULT-HOST Vision
CUSTFILD-HOST MSSQL
Question: How can I find out what the Microsoft SQL Server error message is?
Answer: If you run your application with the -x option, you will receive secondary
error numbers that include those returned by Microsoft SQL Server, in addition
to the ACUCOBOL-GT error.
If you have sent the errors to an output file with the -e option, the runtime
will also attempt to include the text that explains the errors. See Microsoft SQL Server: Runtime Errors , for additional details.
You can also retrieve error codes from within your COBOL program by using
library routine C$RERR. See Microsoft SQL Server: Runtime Errors , for additional details.
Question: Do my XFD files have to be in the same directory as my object files?
Answer: No. You can instruct the compiler to put the XFD files in a directory other than the current one with the -Fo option, or you can move the XFD files after they're created. Then at runtime, make sure you have the runtime configuration file variable XFD-DIRECTORY set to that same directory.
Question: Why aren't my keys being retrieved in the correct order?
Answer: You may have illegal data in the field. For example, if you've used LOW-VALUES or HIGH-VALUES in a numeric key to mark control records,
those values are considered invalid and can cause the records containing them to
be retrieved in an unexpected sequence.
Signed numeric data in key fields can also be a problem; the records may not
sort, or be retrieved, in the same sequence as under the Vision file system.
To enable special values such as these to be processed, use the BINARY
directive in front of the key field. This will allow data of any classification to be
processed. Either designate an individual field as binary, or specify USE
GROUP, BINARY in front of a group of fields.
Question: When I try to open a file for output, I get the error 9D,2714 There is already an object named * in the database. Why?
Answer: One of your record's data items probably has the same name as a Microsoft SQL Server reserved word. Locate the column by comparing a file trace of the CREATE TABLE to Microsoft SQL Server's list of reserved words. Apply the NAME directive to the field in the FD that is associated with the invalid column, then recompile the program to create a new XFD file.
Question: Can I open tables in different databases?
Answer: Yes. Use a file name like:
database.owner.tablename
Note that, because Acu4GL for Microsoft SQL Server will automatically determine an owner, you could also specify a file name like database..tablename. The two dots are mandatory in this case.
Question: Can I use multiple servers (on the same machine or on different machines) on my network?
Answer: Yes. Each server has a unique name. To see if the necessary setup has been done, enter:
isql -S servername
If this connects you to the server you want, then you can open tables on that server by giving them a name like servername.database.owner.tablename. Note that this naming can be done in your runtime configuration file.
Question: I'm getting an error 9D,11 ACUCOBOL-GT lock table missing. I know that I added the lock table during installation.
Answer: This is probably a permissions problem. All users must have READ, WRITE, UPDATE, and DELETE access to AcuLocks (and therefore to the database that contains it). Be sure to check your permissions.
Question: I keep receiving an error message saying that my login is invalid. But I'm sure I'm using the correct username and password.
Answer: All usernames, passwords, and database names are case sensitive. Be sure that you are typing the names exactly as they are set up.
Question: Is it possible to use the same XFD file for data files with different names, if they all have the same structure? This would be useful when I create several customer files that use the same record definitions.
Answer: At runtime, it is possible to use a single XFD for files that have different names. For example, suppose a site has customer files that have identical structures but different names (CUST0001, CUST0002, CUST0003, etc.). It's not necessary to have a separate XFD for each file, so long as their record definitions are the same.
The individual files can all be mapped to the same XFD via a runtime configuration variable called XFD-MAP. Here's how it works.
Suppose your COBOL application has a SELECT with a variable ASSIGN name, such as customer-file. This variable assumes different values (such as CUST0001 and CUST0002) during program execution.
Before compiling the application, you would use the FILE directive to provide a base name for the XFD. Suppose you provide CUST as the base. The compiler would then generate an XFD named cust.xfd. (The compiler always converts XFD names to lower case.)
To ensure that all customer files, each having a unique name, will use this same XFD, you make this entry in your runtime configuration file:
XFD-MAP CUST* = CUST
The asterisk (*) in the example is a wildcard that matches any number of characters. Note that the extension .xfd should not be included in the map. This statement would cause the XFD cust.xfd to be used for all files whose names begin with CUST.
The XFD-MAP variable has this syntax:
XFD-MAP [pattern = base-xfd-name] ...
where pattern consists of any valid filename characters and may include * or ?. These two characters have special meanings in the pattern:
* matches any number of characters? matches a single occurrence of any character
For example:
CUST???? matches CUST0001 and CUSTOMER
does not match CUST001 or CUST00001CUST* matches all of the above
CUST*1 matches CUST001 and CUST0001 and
CUST00001
does not match CUSTOMER*OMER matches CUSTOMER
does not match CUST001 or CUST0001
The XFD-MAP variable is read during the open file stage of any Acu4GL interfaces linked into the runtime.
This is the end of the Acu4GL for Microsoft SQL Server section. Click the Contents button at the top of this window to return to the Table of Contents page.