views:

36

answers:

2

hey all,

i am having trouble adding stuff into the Email column. I can add stuff into the Username column but for some reason i get the following error:

Microsoft OLE DB Provider for SQL Server error '80040e14'
Invalid column name 'Email'.

When I use this code:

Set rstSimple = cnnSimple.Execute("insert into SALT (Email, Username, FirstName, LastName, ActivationCode, TransactionID, ClientID) VALUES ('" & Request.QueryString("payer_email") & "','" & Request.QueryString("payer_email") & "','" & Request.QueryString("first_name") & "','" & Request.QueryString("last_name") & "','" & Request.QueryString("hash") & "','" & Request.QueryString("txn_id") & "','" & Request.QueryString("client_id") & "')")

Can somebody please help me?

Thank you

+2  A: 

Hi,

If the error states "Invalid column name 'Email' I would check:

  1. Does the column 'Email' exist in the database and in that format?

  2. What value are you inserting into the column? If Username works and Email doesn't, are they different types? Maybe Email doesn't except NULL values and Username does? If you are then trying to put a null e-mail address into Email then it won't work.

Other that looking at your database schema, there isn't much more I can guess from this.

Paul

Username and Email fields require the exact same data. So I am passing an email address into both columns. Also, I have just learned that FirstName and LastName and every other column doesnt work. BUT, i dont get errors when i add new columns. Its like it just doesnt let me add new columns any more.
lucifer
i cwnt even delete anything in my table. it wont let me. (still... no errors... it just doesnt do anything)
lucifer
A: 

I do not know if it has an email column in it because none of the damn programs let me connect to the database

Try downloading and connecting SqlDbx to your database using the same ODBC connection. It will allow you to view the schema of your database easily and to edit and execute queries.

http://www.sqldbx.com/ (free for personal use)

Microsoft also has a SQL Server management express tool that is also free

Stephen Perelson
thank you very much i appreciate that. SQL Server management express tool is one of the tools that are giving me major migraines at the moment lol
lucifer