You are here: Re: Wanna create a table field name as 'Name' « MsSQL Server « IT news, forums, messages
Re: Wanna create a table field name as 'Name'

Posted by Ed Murphy on 07/24/06 06:26

On 23 Jul 2006 22:36:15 -0700, prabhukumarasamy@gmail.com wrote:

>Now i m working in a existing project. I have to do some updations. In
>that project database table contain a table(usergroups) field name as
>'Name'.

Lex Luthor: "Are you /sure/?"

>When i am trying to insert a new record in (usergoups) table
>like as follows'
>
>
>insert into UserGroups(Name,modusr,moddt) values ('sam',131,'7/23/2006
>10:02:13 PM')
>
>
>The response ll come as follows,
>
>
>Invalid column name 'FirstName'.Invalid column name 'LastName'.
>
>The usergroups table structure is as follows,
>
>
> UserGroupId int 4 (PK field)
> Name varchar 50
> modusr int 4
> moddt datetime 8

Again, are you sure?

>Plz tell the correct insert query to add records for the above
>table....

If the table structure is indeed as you describe, and if UserGroupID
is auto-assigned, then your insert should be fine.

I suspect the table structure is not as you describe. What does
"select * from UserGroups" give you? (Just the headers and first
line of data would suffice.)

Perhaps the table has "Name" *and* "FirstName" and "LastName" columns,
with trigger logic (which may or may not be smart).

Are you sure you're accessing the right database?

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация