|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stay one step ahead of the competition. Evaluate and give feedback
on some of the hottest web development tools on the market today.
Make your opinion heard! Click
Here
|
|
#1
|
|||
|
|||
|
Data not fully saved in database
Hi all,
I test submitting form data which then added to mySQL database. Numbers of characters submitted was more than 50 but only saved and displayed in database browser was 50. I tried setting field type first as Varchar, then changed to Longtext. But the result was the same. Any idea how to rectify this ? byte1100 |
|
#2
|
||||
|
||||
|
which application language processed the form?
because we'll need to move this thread to the appropriate forum |
|
#3
|
|||
|
|||
|
The language is Perl/CGI scripts.
|
|
#4
|
||||
|
||||
|
now we need sample data and the database specification ...
__________________
--Ax without exception, there is no rule ... The great thing about Object Oriented code is that it can make small, simple problems look like large, complex ones ![]() 09 F9 11 02 9D 74 E3 5B D8 41 56 C5 63 56 88 C0 Some people, when confronted with a problem, think "I know, I'll use regular expressions." Now they have two problems. -- Jamie Zawinski Detavil - the devil is in the detail, allegedly, and I use the term advisedly, allegedly ... oh, no, wait I did ... |
|
#5
|
|||
|
|||
|
let say data from web form reads:
Symmetrical fault calculation is demonstrated starting with calculations of source impedance, high voltage cable impedance, transformer impedance. but only saved in database browser as: Symmetrical fault calculation is demonstrated star... Perl script reads: $sql="INSERT INTO tbl_guestbook (feedback) VALUES ('$feedback')"; Database specifications: MySQL 4.1.11-Debian_4sarge5 Last edited by byte1100 : May 4th, 2008 at 08:16 PM. |
|
#6
|
|||
|
|||
|
Please show us the output from
Code:
SHOW CREATE TABLE tbl_guestbook\G I would also suggest posting a brief code snippet of how you're handling that data until it winds up in the SQL statement.
__________________
BookMooch.com : Give books away. Get books you want. |
|
#7
|
|||
|
|||
|
output from code SHOW CREATE TABLE tbl_guestbook :
Table Create Table tbl_guestbook CREATE TABLE `tbl_guestbook` (\n `feedback` longte... brief Perl snippet: my $dbh=DBI->connect ("DBI:mysql:$database:$host",$user,$pw,{RaiseError=>1}); $sql="INSERT INTO tbl_guestbook(feedback) VALUES ('$feedback')"; $sth=$dbh->do($sql); $dbh->disconnect; |
|
#8
|
|||
|
|||
|
I'm afraid that isn't going to do. You see how the CREATE TABLE statement is truncated? You must be using phpMyAdmin to do that...
|
|
#9
|
|||
|
|||
|
Actually, I have not used phpMyAdmin at all. What is seen in browser of database is the result of data handling by Perl script.
|
|
#10
|
||||
|
||||
|
the ellipsis '...' indicates that there's more data that what's being shown.
there should be an option for a print friendly version. what tool are you using to lookup the values in the database? |
|
#11
|
|||
|
|||
|
I use SQL to lookup for values. Have no problem with this.
But when contacting web host technical team, this is the answer. "The restriction set is not a server side one. This restriction was set by the user of the database during the creation process of the database tables." I checked the OPERATION setting in database, but nothing in there any option that allow me to remove the limitation. |
|
#12
|
||||
|
||||
|
I doubt this has anything to do with perl.
Quote:
What database browser? What about in a perl script that you write to query the db and display that information in a web page? Is that data still truncated? Post a screenshot. |
|
#13
|
||||
|