How can I get Access to allow a "." in a Field Name?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'm trying to use field names which include a period (.) in the name. I know
this isn't an allowed character in an MS Access field name...but does anyone
know of a way of getting around this?
 
Bryan said:
I'm trying to use field names which include a period (.) in the name.
I know this isn't an allowed character in an MS Access field
name...but does anyone know of a way of getting around this?

I don't think there's a way around it -- that character occupies too
fundamental a role in parsing SQL statements. Why on Earth would you
want to? If you can explain your reasons, maybe we can think of an
alternative.
 
It's actually someone I work with that's doing this. They're importing data
into our decision engine from an Access database.

Many of the field names have at least one "." in the name, while some have
none (and also, some have many).

Because they're using the field name in a select statement, of course it
must match exactly to import the data. So they're either going to have to
rename a BUNCH of field names, or we've got to figure a way around it.

Thanks,

Bryan
 
Bryan said:
It's actually someone I work with that's doing this. They're
importing data into our decision engine from an Access database.

Many of the field names have at least one "." in the name, while some
have none (and also, some have many).

Because they're using the field name in a select statement, of course
it must match exactly to import the data.

I'm not sure about the "of course" part of that. It doesn't seem all
that unlikely that an import feature for some (unspecified) program
might allow for mapping field names. Is the SELECT statement in
question being created and run by this "decision engine", or is it in
Access?

Does the import feature in question support importing from CSV files?
If so, you might export from Access to a CSV file, add the desired
field-name header line, and then import that into the other program?

Or could you make it a two-step process: define the Access tables with
some special character in the field names to represent the dot, then
have the import process import them into some temp table, rename the
fields by replacing that character, and then append that temp table to
the permanent table?
 
Dirk Goldgar said:
define the Access tables with
some special character in the field names to represent the dot

I'd suggest _ or underscore.

Tony
--
Tony Toews, Microsoft Access MVP
Please respond only in the newsgroups so that others can
read the entire thread of messages.
Microsoft Access Links, Hints, Tips & Accounting Systems at
http://www.granite.ab.ca/accsmstr.htm
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top