EDIT: Copied wrong part of function into this question, below is the appropriate one.
$values = mysql_query("SELECT lname, fname, email, dtelephone, etelephone, contactwhen, thursday,
friday, saturday, sunday, monday, comments FROM volunteers_2009 WHERE venue_id = $venue_id");
while ($rowr = mysql_fetch_row($values)) {
for ($j=0;$...
Duplicate: mysqli or PDO - what are the pros and cons?
I'm looking to move a website from mysql to either mysqli or pdo as primarily a learning tool, but also for performance increases if possible.
I have read through http://php.net/manual/en/mysqli.overview.php and it seems like both would suit my needs, but it doesn't lean stro...
I'm getting this error
Traceback (most recent call last):
File "/home/<username>/flup/server/fcgi_base.py", line 558, in run
File "/home/<username>/flup/server/fcgi_base.py", line 1116, in handler
File "/home/<username>/python/django/django/core/handlers/wsgi.py", line 241, in __call__
response = self.get_response(request)
F...
I am using MySql 5.1 Database.
I have created a Project database. (Temnplate Database)
and want to Create a copy of the same database from the Application, every time, User Creates A new Project.
How can I copy and Create a New Database of same structure.??
What is the Command to do so???
Thanks a Lot for Help.
...
MySQL doesn't seem to have deffering constraints until the end of a transaction implemented yet. If so, what's the best way to switch parents in two child records?
For instance if we have some UI slots that each user can place items in. How should be switch items in user's slots, given that slotid is FK in item table and it there's uni...
I am contemplating a switch from MySQL to PostgreSQL.
What are your tips, tricks and gotchas for working with PostgreSQL?
What should a MySQLer look out for?
See also: How different is PostgreSQL to MySQL?
See also: Migrate from MySQL to PostgreSQL
Note - I don't think this is a duplicate. In particular the type of answers are ...
I have one database, with one table, with a particular field which has descriptions of various clothing. These descriptions often contain umlauts or similar characters.
I am retrieving this fields from two different php fields, and I am not doing anything to the data, yet it displays inconsistently.
In file1, it will display correctly ...
How can I make this two queries in one ?
$query = "SELECT * FROM `amb_prod` WHERE idAmbiente='".$ambId."';";
$result_set = mysql_query($query);
while($member = mysql_fetch_array($result_set)){
$query2 = "SELECT * FROM `produto`, `pt` WHERE
produto.refPT = pt.ref AND
produto.refPT = $member['idProduto'] ;";
$result...
I've been trying to figure out how to properly setup DreamWeaver in such a way that I can create WordPress themes. Right now I'm running WordPress on localhost, accessing it via DreamWeaver. Then I'm using LiveView on the actual WordPress code and modifying the files in the theme folder.
What I'd really like to do, and I'm not sure if t...
Hypothetical example:
I have an SQL table that contains a billion or so transactions:
| Cost | DateTime |
| 1.00 | 2009-01-02 |
| 2.00 | 2009-01-03 |
| 2.00 | 2009-01-04 |
| 3.00 | 2009-01-05 |
| 1.00 | 2009-01-06 |
...
What I want is to pair down the data so that I only see the cost transitions:
| Cost | DateTime |
| 1.00 | 2...
Can we configure MySQL 4 with XAMPP? The latest version of XAMPP comes with MySQL5
...
I'm trying to insert a string into a MySQL database. I can insert it by running the query on the server, but when I try to use my C# source file to insert "Iñtërnâtiônàlizætiøn", I get "Iñtërnâtiônà lizætiøn". I've tried adding it as a parameter and adding ;charset=utf8 to my connection string, but no look. The table in the databas...
I want to run a query like this in MySQL:
select * from table where column1 like '%searchdata%'
But I want to use a parameter to pass in the search text. Is this possible? This doesn't seem to work:
select * from table where column1 like '%?Parameter%'
...
I need to write setup scripts for MySQL (usually run using 'source [file]' from mysql console) that depend partly on existing data, and there are differences in environments, meaning that sometimes script does fail. A common case is that a 'SET' statement with a select (to locate an id) fails to find anything; console sets value to NULL....
Hello,
I am asking if it is not only possible to pull data from a MySQL table, but also display each row in either a table or a DIV, preferably a DIV. How would I do so?
Table:
ID |BodyText |Title |
1 |Hello World1 |Title1 |
2 |Hello World2 |Title2 |
etc..
I'd like to put each row into a DIV that...
Given the following code:
// Connect to MySQL up here
$example_query = $database->prepare('SELECT * FROM table2');
if ($example_query === false) die('prepare failed');
$query = $database->prepare('SELECT * FROM table1');
$query->execute();
while ($results = $query->fetch())
{
$example_query = $database->prepare('SELECT * FROM tabl...
I'm working on a site where users submit photos which can be viewed one by one on a page.
There is another page where you see smaller versions of multiple photos.
When user clicks any of these smaller photos they get the large version page, pressing "next" will take them to another photo in that category.
I would very much like newer ...
For our company intranet, built in PHP and MySQL, I want to add an area where employees can post a short profile of themselves - a couple of paragraphs of text and an image.
What's the best way to convert this kind of plain text input to HTML paragraphs, bulleted lists, links, etc?
Clarification: This content will be displayed in a mod...
after i have finished with my result set from a active record query in a codeigniter model, should i use $query->free_result() or does activerecord automatically do that?
...
Given a time (eg. currently 4:24pm on Tuesday), I'd like to be able to select all businesses that are currently open out of a set of businesses.
I have the open and close times for every business for every day of the week
Let's assume a business can open/close only on 00, 15, 30, 45 minute marks of each hour
I'm assuming the same sche...