I inserted some info into my mysql database and I got the following error listed below. What does this mean and how can I fix it?
1 row(s) inserted.
Inserted row id: 1
Warning: #1265 Data truncated for column 'summary' at row 1
Here is my Mysql tables structure below.
CREATE TABLE mem_articles (
id INT UNSIGNED NOT NULL AUTO_INCREMEN...
Hi,everyone. I am working on a site with smarty templates using php and a mysql database.
This is a more specific question than my first one which asked how to pass methods to a class. I thought it would be easier to repackage the question than edit the old one.
I have written a paginator script for my image gallery which displays imag...
I was thinking of storing URL values in my database but I know some URL's sometimes get ridiculously long. I think my MySQL Database is Version 5.0.
I was thinking of using.
VARCHAR(255)
but this will only work for so long. So should I use.
TEXT
...
how do you code a search box like the one in Tags where you enter a tag name and all tags are showing immidiately without you press enter.
can someone link me a script or tutorial for that. is it javascript or jquery? does it involve ajax?
and does it search in the database for tags? or is it searching through a xml file with tags?
...
Hi
I'm building an app in CodeIgniter. I have an invoice form which uses jQuery to create new line items. The line items are formated as follows:
<input type="text" name="invoice[new_item_attributes][][description]" class="ui-corner-all text invDesc" title="Description" />
<input type="text" name="invoice[new_item_attributes][][qty]" c...
I was wondering how can I display a members article they created and show it to visitors all while displaying the members info that is associated with that article to the visitors.
I hope I explained it right?
Here is my mysql articles table.
CREATE TABLE authors_articles (
id INT UNSIGNED NOT NULL AUTO_INCREMENT,
author_id INT UNSIGN...
Okay I kind of know how to display the time with PHP and MySQL but I need a little help.
I want to display the time something like this in the example below.
August 5, 2010 @ 8:47:28 PM
Here is the code I have so far that is listed below.
date('F j, Y', strtotime($date_created))
...
what would be the efficient way of saving the following array using php (cakephp)?
each value needs to go into a new row in the table?
Array
(
[0] => 6786754654
[1] => 5643564545
[2] => 344544545
[3] => 233245654654
[4] => 453454654654
[5] => 6546542323
[6] => 654654654
[7] => 645654654
etc....
)
t...
hi. in SO you can search for tags without pressing enter.
i want to know:
are the tags retrieved from the database or from a XML file?
is ajax involved?
i am new at front end. if ajax is involved. how should i write the code?
i want it to access a php file which returns the data. but im not familiar with how it works practically.
...
Hi, I'm fairly new to my sql, and I need to know what is the default username for mysql, like in mssql you have 'sa'.
I can connect to the mysql command client but it does not ask me for a username.
...
I am trying to insert 10,000+ fields into my database? Is there a limit?
$sql = 'INSERT INTO `_'.$test.'` (`user`, `pass`) VALUES ' . preg_replace($test, $replace, $final_check) . ';';
mysql_query($sql) or die(mysql_error());
Every time I try to insert the data, it fails.
...
What is the configuration and code required to use mysql within a BlazeDS turnkey environment?
...
Hi All,
I've run into this really annoying behavior and I want to know if I'm doing something wrong, or if this is intentional (and if so, why).
Whenever I have a variable in php (5.3) that is of type double and I want to insert it into the database (MYSQL 5.0) in a field that is of type double, the value always gets rounded down to 6 ...
I have a bit of code that basically displays the last x (variable, but let's say x is 20 here) updates made in a given table. In one of the unit tests for it, I have this snippet:
EditedItem.push_to_queue(hiddennow)
#create some new entries and save them
20.times{ EditedItem.push_to_queue(random_item) }
Queue.get_entries.each{|entry| a...
I have a Select query which executes on a transactional table having more than 4 million records. Whenever I execute this query , I observe that all write and update operations on that particular transactional table become suspended and we start getting exceptions from java side that lock wait timeout exceeds , try restarting transaction...
I have a main form with a lot of inputs. The forms action is set to a php file.
After submitted the php-page shows up with all the inputs that the user typed into the form. The user has to re-check everything and hit an 'approve' button!
The problem is, I don't know how to do this...
I want to eventually put all data into a MySQL databa...
Is this right, because nothing happens when I hit the submit button:
<HTML>
<BODY>
<?php
$ok_button="<input type='submit' OnClick='document.forms['myForm'].submit();' value='approve!';"
echo $ok_button;
$form="<form name='myForm' action='myPhp.php'><input type='hidden' name='firstname' value='<?php echo $firstname;?>'></form>;"
?>
!!!A...
I have an extensive slow query log which was running for a few weeks. I would like to parse it, which would put the highest occurring queries at the top (with number of executions and average times of execution), and it goes from there in descending order.
What tool/command can I use to accomplish that?
...
Hi all,
I have the following problem at the moment.
I am using mySQL and Tomcat for my college project, and I am able to connect mySQL DB locally from a jsp page. However, if I try to use mySQL and server in my college, I got the following error
Exception: Communications link failure. The last packet sent successfully to the server was ...
Here are the tables:
sets: id INT
users: id INT
items: id INT
setid INT [an item only belongs to one set]
relationships: userid INT
itemid INT
relationship WHATEVER
Now, I have been trying to write an SQL query to do the following, without much success.
Given a ...