SQL Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsDatabaseSQL Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
  #1  
Old March 10th, 2004, 11:26 AM
LostProgrammer LostProgrammer is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: Birmingham, AL
Posts: 6 LostProgrammer User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Cant add more than one word to database record

My page takes inputted text from the user and adds it to a record in the database. Only the first word is added to the field if more words are entered. The field type is nvarchar so I dont understand why it wont capture the rest of the text. My statement looks like: SQL = "Insert into Individual (AirRequest) Values('" & Request.Form("AirRequest") & "')". What am I doing wrong? I just discovered it does this for all of the text inputs that my form contains. All multiple word inputs are adding only the first word to the field. Am I using the wrong field type? I have another page that is almost identical but it is inserting all words entered in the text boxes. I cant find a difference in the codes.

Reply With Quote
  #2  
Old March 10th, 2004, 11:31 AM
Memnoch's Avatar
Memnoch Memnoch is offline
Unholy Moderator
ASP Free God 14th Plane (11500 - 11999 posts)
 
Join Date: Oct 2003
Location: In hell, where did you think?
Posts: 11,776 Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level) 
Time spent in forums: 3 Weeks 5 Days 8 h 27 m 42 sec
Reputation Power: 470
What is the length of the field in the database?
What is the length of the text you are trying to enter?
What does the sql statement display when you do a response.write on it?

Reply With Quote
  #3  
Old March 10th, 2004, 11:49 AM
LostProgrammer LostProgrammer is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: Birmingham, AL
Posts: 6 LostProgrammer User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Quote:
Originally Posted by Memnoch
What is the length of the field in the database?
What is the length of the text you are trying to enter?
What does the sql statement display when you do a response.write on it?


The length of the db field is 500. The length of the text is anything over one word, it does not matter what length. There are 3 pages: the first takes in all the info from the user, the next simply spits out the inputted info just as a confirmation, then the third actually submits it to the db and spits out what should look just like what was shown on the confirmation but at this point it is actually displaying what has been inserted using rs("AirRequest"). On the confirmation page(the page just before the insert to db page) I did a response.write(Request.Form("AirRequest")) at the very end of the page. It came back with all of the words I entered in that text box. Then I did the Response.Write at the very beginning of the next page that inserts the record. It did not contain the rest of the text after the first word. There has been no data manipulation at this point, just simply carrying the value from one page to the next and it's losing data. Its driving me crazy!

Reply With Quote
  #4  
Old March 10th, 2004, 12:09 PM
Memnoch's Avatar
Memnoch Memnoch is offline
Unholy Moderator
ASP Free God 14th Plane (11500 - 11999 posts)
 
Join Date: Oct 2003
Location: In hell, where did you think?
Posts: 11,776 Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level) 
Time spent in forums: 3 Weeks 5 Days 8 h 27 m 42 sec
Reputation Power: 470
does the text contain any special characters? such as (') or (")?
what are the words that are needing to be entered?
And
What is actually being shown and entered into the database?

Reply With Quote
  #5  
Old March 10th, 2004, 12:20 PM
LostProgrammer LostProgrammer is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: Birmingham, AL
Posts: 6 LostProgrammer User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Quote:
Originally Posted by Memnoch
does the text contain any special characters? such as (') or (")?
what are the words that are needing to be entered?
And
What is actually being shown and entered into the database?


I entered the following text into the text box: Why wont you work for the love. On the confirmation page it all comes through but then I click continue and what is entered in the DB as well as shown on the final page is just: Why
But whatever I enter in the text box the only thing that finally goes through is the first word.

Reply With Quote
  #6  
Old March 10th, 2004, 12:30 PM
LostProgrammer LostProgrammer is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: Birmingham, AL
Posts: 6 LostProgrammer User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Quote:
Originally Posted by LostProgrammer
I entered the following text into the text box: Why wont you work for the love. On the confirmation page it all comes through but then I click continue and what is entered in the DB as well as shown on the final page is just: Why
But whatever I enter in the text box the only thing that finally goes through is the first word.


Just wanted to reiterate that this problem is happening before it even hits the DB and tries to insert. I did the response.write on the final page before the SQL connection and it still came back with just the one word. Then I did it at the end of the confirmation page just before it and all the words were there. So carrying the value from one page to the next is somehow making it drop all words after the first. thanks for your help

Reply With Quote
Reply

Viewing: ASP Free ForumsDatabaseSQL Development > Cant add more than one word to database record


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway
Stay green...Green IT