ColdFusion Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming Languages - MoreColdFusion 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 Dev Shed Forums Sponsor:
  #1  
Old October 6th, 2003, 12:50 PM
rahljosh rahljosh is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Posts: 3 rahljosh User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Data not writting to db

I have kind of an odd problem. When I submit a form, the data randomly doesn't write to the database. It sticks around long enough for me to validate that indeed information was imputed and is correct, but on the submition to the db, it is lost. It does it with random fields at random times. It doesn't seem to make a difference if I have default values or not.

An example of it is I have a Yes/No question with a comment box. If you answer No with no comment, it directs you to fill in the comment, that part works, but the answer to the Yes/No isn't always written to the db. Other times it is. I also have run into this problem with an address field. Sometimes it writes the address, other times it doesn't.

Any of you have any ideas on what would be causing this?

Thanks-

Here is the code for the input:
<td>Yes <input type=radio name="english_improve" value="Yes"></td><td>No<input type=radio name="english_improve" value="No" checked>


If the error checking is ok:
<CFtransaction action="begin" isolation="serializable">
<CFINSERT DATASOURCE="reports" TABLENAME="test_progress_reports">

Had the same problem before the error checking was there, so the problem isn't in that.

The address problem input looks like this: <INPUT type="text" name="school_Add" value="#sch_Add#" size=30></INPUT> same type of insert tag. The address is pulled from a different db, if its available, if not, the user enters it. Either way it doesn't always take.

Last edited by rahljosh : October 6th, 2003 at 02:39 PM.

Reply With Quote
  #2  
Old October 6th, 2003, 02:31 PM
drgroove's Avatar
drgroove drgroove is offline
Moderator Emeritus
Dev Shed God 5th Plane (7000 - 7499 posts)
 
Join Date: Feb 2002
Location: Scottsdale, AZ
Posts: 7,174 drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level)drgroove User rank is General 17th Grade (Above 100000 Reputation Level) 
Time spent in forums: 6 Days 23 h 48 m 33 sec
Reputation Power: 2131
Post the code you're using - it will help other users determine if the error is w/ your CFML or somewhere else.

Thanks.
__________________
DrGroove, Devshed Moderator | New to Devshed? Read the User Guide | Need ServiceNow consulting or ITIL process design? Connect with me on LinkedIn

Reply With Quote
  #3  
Old October 6th, 2003, 03:43 PM
rahljosh rahljosh is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Posts: 3 rahljosh User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Here is the code for the input:
<td>Yes <input type=radio name="english_improve" value="Yes"></td><td>No<input type=radio name="english_improve" value="No" checked>


If the error checking is ok:
<CFtransaction action="begin" isolation="serializable">
<CFINSERT DATASOURCE="reports" TABLENAME="test_progress_reports">

Had the same problem before the error checking was there, so the problem isn't in that.

The address problem input looks like this: <INPUT type="text" name="school_Add" value="#sch_Add#" size=30></INPUT> same type of insert tag. The address is pulled from a different db, if its available, if not, the user enters it. Either way it doesn't always take.

Reply With Quote
  #4  
Old October 6th, 2003, 10:40 PM
kiteless kiteless is offline
Moderator
Dev Shed God (5000 - 5499 posts)
 
Join Date: Jun 2002
Location: Raleigh, NC
Posts: 5,091 kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level) 
Time spent in forums: 2 Weeks 5 Days 2 h 53 m 27 sec
Reputation Power: 966
What database are you using? Are you sure it supports the "serializable" transaction mode?

Also, the use of CFINSERT is fraught with peril. It takes a little more work, but trust me and write out a SQL insert statement instead, things will work much more smoothly if you do.

Reply With Quote
  #5  
Old October 8th, 2003, 01:37 PM
rahljosh rahljosh is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Posts: 3 rahljosh User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
switched the insert statement to and actual insert SQL statement and made a huge difference. Thanks for the pointer on that one.

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreColdFusion Development > Data not writting to db

Developer Shed Advertisers and Affiliates



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 | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap