Mochalatte


When I execute this code:

create table radcases;

(co c(3),;

deptno c(6),;

fy06_cases n(12,0),;

fy06_quantity n(12,0),;

fy07_cases n(12,0),;

fy07_quantity n(12,0))

I get the error: "Field name is a duplicate or invalid"

What is wrong with my field names They are not duplicated, so they must be invalid. What's the deal Thanks!




Re: duplicate field?

Fox Me Up


its because your field names are longer than 10 chars.


create table radcases;

(co c(3),;

deptno c(6),;

fy06_cases n(12,0),;

fy06_quantity n(12,0),; && Greater then 10 chars

fy07_cases n(12,0),;

fy07_quantity n(12,0)) && Greater then 10 chars




try this



create table radcases;
(co c(3),;
deptno c(6),;
fy06_cases n(12,0),;
fy06_quant n(12,0),;
fy07_cases n(12,0),;
fy07_quant n(12,0))






Re: duplicate field?

Carl Warner

As was already said, your field names show names longer than 10 characters and they get truncated to only the first 10 characters which creates a duplicate field name, albeit an inadvertent one.

So, what that means is that you are creating a FREE table; i.e., one not associated with a database container (.dbc).

If you want field names as you show, you must have a database container (dbc) open for your CREATE TABLE to work exactly as you have shown. Any table field name with more than 10 characters is fine as long as it is part of a database container. In fact, the limit for characters in a field name with a table in a dbc is 128 characters.

CREATE TABLE - SQL Command

http://msdn2.microsoft.com/en-us/library/z1cc2za0(VS.80).aspx






Re: duplicate field?

Mochalatte

Thank you both so much!!