> On Aug 17, 2015, at 2:42 PM, tim.bu...@pobox.com wrote:
> 
> ----- Forwarded message from "Adkins, Blake" <blake.adk...@intel.com> -----
> 
> Date: Mon, 17 Aug 2015 17:51:41 +0000
> From: "Adkins, Blake" <blake.adk...@intel.com>
> To: "tim.bu...@pobox.com" <tim.bu...@pobox.com>
> Subject: DBI Dilemma
> 
>   Tim,
> 
>   I've been using your module to enable people in my group to do searches on 
> a database that is regularly
>   backed up as a .csv file. The problem here is with a particular column 
> name. Of the 140 columns in the
>   database, one is named DESC, short for description. This was established 
> well before my time at the
>   company and I believe the name comes from GE who makes the Cimplicity 
> product. If I try to do a SELECT
>   using that column, the script dies, or quietly passes DESC in the column 
> header and all the rows. I've
>   tried to figure out how to get around it without success. Do you have any 
> suggestions aside from
>   renaming the column? (I was thinking along  the lines of escaping the name)
> 

How you do this depends on the database, but yeah escaping the name is what I’d 
investigate first.

The table had to be created somehow, and if the DB works, it’s valid; can you 
query it in the database itself using built in tools? (EG: sqlplus or mysql or 
psql, for example)

The issue may well not be DBI, but the particular DBD module in use. I know for 
a fact that I can make a column named ‘DESC’ in oracle and it just works. But 
Oracle’s got a long history of letting you get away with murder in naming 
things...



-- 
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group

Institutions do not have opinions, merely customs

Reply via email to