Posted by Simon Hayes on 07/08/05 20:29
<rsstonejr@yahoo.com> wrote in message
news:1120843610.046693.98710@g44g2000cwa.googlegroups.com...
> Hello.
>
> I'm working on an application where the original developer used the
> field name 'index'. This works ok when accessing the table from MS
> Access through query, but when I try to reference it via SQL with
> either a statement from Enterprise Manager or a stored procedure I'm
> getting an error because 'index' is a keyword.
>
> Is there any way to reference this? Maybe some delimeters I can put
> around it that I don't know about?
>
> Thanks,
> Stoney
>
You can use brackets:
select [index]
from dbo.MyTable
See "Using Identifiers" and "Delimited Identifiers" in Books Online, as well
as "Reserved Keywords".
Simon
Navigation:
[Reply to this message]
|