benjancewicz Posted July 9, 2007 Share Posted July 9, 2007 So, I've got this script for building a CSV file (from a form) that I'm trying to pick apart and figure out.Here's the form: http://www.fatherhood.org/magicform.aspHere's the code from magiformprocess.asp ''''''''''''''''''''''''''''''''''''''''''This gets all the values entered in the form.'''''''''''''''''''''''''''''''''''''''''strAdminEmail = Request.Form("AdminEmail")strUserEmail = Request.Form("UserEmail")strtext = Request.Form("Text")'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''Store data in database'''''''''''''''''''''''''''''''''''''''''set conn = db.ActiveConnectionfor each thing in split(strUserEmail, ",") thing = trim(thing) set RS = conn.execute("INSERT INTO magicform.csv(UserEmail, Text) VALUES(" & NIB(StrUserEmail) & ", " & NIB(StrText) & "); Select @@Identity as Identifier ") set rsID = rs.NextRecordset intIDvalue = rsID("Identifier")nextkill connIf len(intIDvalue) > 0 Then URL = replace(URL, "[iD_HERE]",intIDvalue)Else Response.Write "There was a problem getting intIDvalue "End If But, I get this error: Tell a Friend Tell a Friend Email This Page to a Friend Email Print This Page PrintMicrosoft OLE DB Provider for SQL Server error '80040e37'Invalid object name 'magicform.csv'./magicformprocess.asp, line 164 What am I doing wrong? Link to comment Share on other sites More sharing options...
pulpfiction Posted July 9, 2007 Share Posted July 9, 2007 Not really sure, but think its because of period [.]in the table name. did you have similar trouble before with the table name? try INSERT INTO [magicform.csv](UserEmail......Also try to print out the SQL query and see if its in the correct format. Link to comment Share on other sites More sharing options...
justsomeguy Posted July 9, 2007 Share Posted July 9, 2007 And make sure the connection string is correct, the error message indicates that it cannot find the CSV file, so the connection string might not be correct. This page has an example of a DSN-less connection to a CSV file:http://www.simongibson.com/intranet/adooledb/ Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.