The only issue I see and maybe why they'd disable it is so you don't do a
crazy join that ends up returning 8 billion rows. But they should be
able to manage that with query execution time timeouts or something and
you can do the same thing with bad implied inner joins in the WHERE
clause
if that helps, but just to add to the
list of how *some* people do it.
Good luck!
-TG
- Original Message -
From: listread listr...@cze.com
To: php-db@lists.php.net
Date: Mon, 02 Nov 2009 07:16:23 -0600
Subject: [PHP-DB] How to: Include identifier with a query
Greetings!
We are searching
good to try to structure things so you have a predictable and
controllable way so you know whether you're going to be getting GET or
POST data. Some cases required 'either' but in general, one or the other
should be good enough if your code is structured properly.
-TG
- Original Message
of the script execution isn't a
big deal. But you won't be able to pass the connection information via
session variables.
-TG
- Original Message -
From: Fred Silsbee fredsils...@yahoo.com
To: php-db@lists.php.net
Date: Thu, 25 Dec 2008 15:57:13 -0800 (PST)
Subject: [PHP-DB] is there any
their
database guys who don't want to work.
-TG
- Original Message -
From: Fergus Gibson [EMAIL PROTECTED]
To: php-db@lists.php.net
Date: Sun, 9 Nov 2008 11:09:22 -0800
Subject: Re: [PHP-DB] Joomla MySQL query performance affected by anything
non-server related?
On Wed, Nov 5, 2008 at 2:17 PM
about optimization, but I need some
solid evidence to throw at this web host so they'll listen to me. They're
usually really awesome, but this case is causing me to lose my hair.
Thanks in advance!
-TG
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http
me nuts. They get traffic,
but it shouldn't be so much that it's causing issues ilke this.
Shouldn't have to make such radical changes for this site. All I can think
is that it's an issue with their server and/or other customers on the same
shared server.
-TG
- Original Message
- Original Message -
From: Afan Pasalic [EMAIL PROTECTED]
To: TG [EMAIL PROTECTED]
Cc: php-db@lists.php.net
Date: Wed, 05 Nov 2008 17:07:46 -0600
Subject: Re: [PHP-DB] Joomla MySQL query performance affected by anything
non-server related?
TG wrote:
Been getting the occasional
you're in a good position since your company is small.
Probably can't do too much that's going to cause a mess in the future. hah
Good luck!
-TG
- Original Message -
From: Jason Pruim [EMAIL PROTECTED]
To: php-db@lists.php.net
Date: Mon, 20 Oct 2008 07:59:36 -0400
Subject: [PHP-DB
server is on another server, if you have a Windows
machine you can use a program like WinSQL Lite or Navicat to connection to
the MySQL server (if it allows remote connections).
phpMyAdmin is probably the easiest option though.
-TG
- Original Message -
From: Nasreen Laghari [EMAIL
You might check the google documents api:
http://code.google.com/apis/documents/overview.html
-TG
- Original Message -
From: ioannes [EMAIL PROTECTED]
To: php-db@lists.php.net
Date: Wed, 26 Dec 2007 23:59:12 +
Subject: [PHP-DB] Download google spreadsheet
I would like to get
-them are used to be
explicit with a name.
-TG
- Original Message -
From: Gary Wardell [EMAIL PROTECTED]
To: php-db@lists.php.net
Date: Thu, 13 Dec 2007 19:33:57 -0500
Subject: RE: [PHP-DB] UPDATE syntax
Hi,
I'm a beginner at PHP and MySql but a long time MS SQL server user.
Maybe
for allowing non-unique input into the
database, depending on the circumstances.
-TG
- Original Message -
From: OKi98 [EMAIL PROTECTED]
To: T K [EMAIL PROTECTED]
Cc: php-db@lists.php.net
Date: Fri, 05 Oct 2007 10:34:50 +0200
Subject: Re: [PHP-DB] Prevention for multiple submissions from
The most common method I've seen is with Javascript. onsubmit, disable
submit button.
As a backup, in case the user's JS is disabled, you might consider the unique
ID thing.
-TG
- Original Message -
From: T K [EMAIL PROTECTED]
To: php-db@lists.php.net
Date: Thu, 4 Oct 2007 20:09:01
WHERE
DepartmentID IS NULL.
-TG
- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED], php-db@lists.php.net
Date: Wed, 3 Oct 2007 05:21:06 -0500
Subject: [PHP] the opposite of a join?
I have a company table and a contacts table. In the contacts table, there
is a field
. Always
willing to learn new things if they are, indeed, better.
-TG
- Original Message -
From: Bob Chatman [EMAIL PROTECTED]
To: TG [EMAIL PROTECTED]
Cc: nhadie [EMAIL PROTECTED], php-db@lists.php.net
Date: Fri, 28 Sep 2007 23:23:41 -0700
Subject: Re: [PHP-DB] newbie help
storing for your customers and your
customer's customers? And what other data do you need to store for
whatever your webapp does?
-TG
- Original Message -
From: nhadie [EMAIL PROTECTED]
To: php-db@lists.php.net
Date: Fri, 28 Sep 2007 23:49:23 +0800
Subject: Re: [PHP-DB] newbie help
);
Something like that.
-TG
- Original Message -
From: Derek [EMAIL PROTECTED]
To: php-db@lists.php.net
Date: Thu, 27 Sep 2007 16:42:10 -0500
Subject: [PHP-DB] Updating 2 Databases from a single form
Hello,
I was wondering if there is anyway to first connect to two databases
simeltaneously
and dirty example, not adhering to any real design
scheme. My normal code is a bit prettier than this, but you get the idea.
-TG
- Original Message -
From: endro mei a. [EMAIL PROTECTED]
To: php-db@lists.php.net
Date: Wed, 26 Sep 2007 17:26:04 +0700
Subject: [PHP-DB] Delete one table
= should (if I recall) be faster than LIKE
comparisons. So if you really meant to use =, do that instead.
Let me know if any of that's unclear. I know I get some kooky ideas
sometimes. Also, anyone see anything I screwed up or have thoughts on this
matter?
Good luck!
-TG
- Original
%'
AND listing_approved IN ('1', '2')
ORDER BY name ASC
Good luck!
-TG
- Original Message -
From: ron.php [EMAIL PROTECTED]
To: php-db@lists.php.net
Date: Sat, 15 Sep 2007 15:04:59 -0400
Subject: [PHP-DB] Query syntax
$query=SELECT * FROM table WHERE listing_type LIKE '%$listing_type
SELECT MIN(id), MAX(id) FROM mytable
:)
Hope that helps!
-TG
= = = Original message = = =
I have a table where I need to figure out the very first ID and the
very last ID, so here is what I wrote:
$first_query = SELECT id FROM mytable ORDER BY id LIMIT 1;
$first_result = mysql_query
= ld.LeadID
(actually a lot of the time you can leave out the as and just do Leads l)
Fun times..
-TG
= = = Original message = = =
[EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
SELECT MIN(id), MAX(id) FROM mytable
As an aside, is you are using associative arrays, be sure to use
/last, then put everyone else
after the Bobs sorted by first/last.
If you don't put DESC on the 'Cats', it looks like it'll put the 'Cats' at the
bottom of the list.
Also refer to the user comments here:
http://dev.mysql.com/doc/refman/4.1/en/sorting-rows.html
good luck!
-TG
= = = Original
or an underscore (_).
mysql SELECT 'a word a' REGEXP '[[::]]word[[::]]'; - 1
mysql SELECT 'a xword a' REGEXP '[[::]]word[[::]]'; - 0
-TG
= = = Original message = = =
Hi all,
I'm setting up a database search on a site, where I will essentially be
BOOLEAN searching about 6 database fields
(n, strtotime($subscription_begins));
http://us3.php.net/manual/en/function.date.php
-TG
= = = Original message = = =
I have a $subscription_begins variable. It the date type. -MM-DD
How may I find out the month value (1 to 12) of this variable?
Ron
Try this as your SQL. It should give you all the results, then you can use PHP
to sort it all out.
SELECT * FROM egw_cal WHERE cal_category='501' and cal_id in (SELECT cal_id
FROM egw_cal_dates where cal_start $tstamp)
-TG
= = = Original message = = =
Hello Everyone
Got a simple
to ask.
-TG
= = = Original message = = =
Hello,
I need to query two different tables and create one BIG array.
I can query both tables, but can't find a way to combine the results in one
array.
The problem comes in with the second table. It has a weird layout.
The second table only has four
too, I'm just not fully
groking the situation I think.
-TG
$name = $row['NAME'];
$business = $row['BUSINESS'];
$address = $row['ADDRESS'];
$city = $row['CITY'];
$phone = $row['PHONE'];
$contactname = $row['CONTACT_NAME'];
$contactvalue = $row['CONTACT_VALUE'];
$bigarray
If all you want is a unique list of adr_one_region codes, then use the
DISTINCT keyword in your SQL:
SELECT DISTINCT adr_one_region FROM egw_addressbook WHERE cat_id='8' ORDER BY
adr_one_region
-TG
= = = Original message = = =
Hello everyone
I'm back working on the website again... I'm
change what appears
in your results. This only affects the sorting:
select * from sometable order by if(ifnull(somecolumn, '') = '',
'', somecolumn)
Hope that helps.
-TG
= = = Original message = = =
I have this column in mysql:
A
F
D
[ empty ]
A
C
If I do an order
change what appears
in your results. This only affects the sorting:
select * from sometable order by if(ifnull(somecolumn, '') = '',
'', somecolumn)
Hope that helps.
-TG
= = = Original message = = =
I have this column in mysql:
A
F
D
[ empty ]
A
C
If I do an order
chance of typos.
BTW: In my example, realistically you could probably shorten the morphed value
to ZZ or ZZZ unless you think you'll values in your database that will
start with and get bumped lower on the sorting.
-TG
= = = Original message = = =
In case the blank is a null or is really
random data sources I had to from
time to time.
http://adodb.sourceforge.net/
Sorry I don't have time to look for good examples, but maybe the documentation
will help out some and get you on the right path.
-TG
= = = Original message = = =
I cannot connect to my MSSQL server.
I use
need to use the mysql_affected_rows() either unless you want
to test for zero results and display an error message, like I believe you
wanted to do.
-TG
= = = Original message = = =
Hi,
The below mentioned code works fine. Connects to the database, fetches the
result, and displays neatly
the database check.
You could probably get the last inserted ID number as well and pass that to the
PHP script if you want to check specific records right after they're inserted.
-TG
= = = Original message = = =
I have an Access database connecting via ODBC to a local MySQL machine
and doing
and unsubscribe using one
of your email addresses and see if that solves the problem.
-TG
On 7/7/06, Karl James [EMAIL PROTECTED] wrote:
Team,
I am still receiving duplicate emails.
I check with my ISP and they tell me it is
Not their problem. I tried to check the headers
But I am
queries are better than one.
-TG
= = = Original message = = =
I see they call mysql_query twice which doesn't look like I'm gaining
anything over running the 2 queries:
SELECT count(*) as MyCount FROM aTable
SELECT * FROM aTable LIMIT 5
But I suppose I need to time it for my app.
http://us3
it, but
ultimately it's not worth the bending over backwards for (do I remember right
that you can do it with crosstab queries? don't even know if MySQL will do
those properly). Easier just to do it with one of the methods above.
Good luck!
-TG
= = = Original message = = =
I want select
many 30 minute
periods have occurred between the timestamp and now and update the gold then.
The cron job is preferrable but if you're looking for alternate ideas, there's
one for ya.
Good luck!
-TG
= = = Original message = = =
Hi there.
I've posted this up on both this list, and the mysql
['Title'];
$publisher = $dvddata['Publisher'];
$comments = $dvddata['Comments'];
foreach ($comments as $comment) {
// do whatever
}
}
There are other ways to handle this.. this might be one of the easier ones (if
I'm understanding your problem correctly).
-TG
= = = Original message
guessing
it's not going to really be feasible for you to do this... not easily at least.
-TG
= = = Original message = = =
Hi all,
I am developing the site using php and mysql. I have to add the url at
google site through php code.
If any one have idea about it, please help me.
Regards
Manoj
PHP.
Good luck!
-TG
= = = Original message = = =
I am trying to write a script to handle event registration. Most of the
people that will be registering are already in the database, but not all,
and those that are may not have current information.
Here is my latest effort, or at least
.. and figure out how to read XLS files that way.
The Excel Object Model might help you with the proper properties/methods/etc:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dv_wrcore/html/wrgrfexcelworkbookobject.asp
Good luck.
-TG
= = = Original message = = =
Dear All,
Have you
.
-TG
= = = Original message = = =
I know this may be a bit off-topic, but I would like to use the PEAR library
to implement some of my database functions. Unfortunately, the PEAR
documentation is woefully incomplete and as a result i've been unable to
install it properly. Here's the procedure i
something a
little more automated.
Without more info though, it's hard to say exactly what can be done.
Hope that helps a little bit.
-TG
= = = Original message = = =
My dear beloved friends,
I have a catalog of products that a product provider gave, sadly for me, in
this CSV file there are many
Haha.. oh yeah.. DISTINCT works too.. in this case you'd get a list of all
totally 100% unique records.
If you had an auto_increment column though, you'd want to exclude it from the
list.
-TG
= = = Original message = = =
SELECT DISTINCT * FROM `tablename`
On Wednesday 01 March 2006 7:24
that's the
keyword that would have done it for me.
I appreciate the help guys! Best of luck to both of you (and anyone else I
inadvertantly missed who may have responded).
-TG
= = = Original message = = =
Me again,
Sorry for the rtfm stuff, I googled around and found this:
http://bugs.mysql.com
H:i:s, mktime($hour, $minute - 90, $second, $month, $day,
$year));
It will even adjust for leap years I believe. You can add/subtract/etc any of
those items and it's smart enough to figure out what the correct resulting
date/time would be.
-TG
= = = Original message = = =
?php
echo date(Y-m
of things to doublecheck. If anyone has any
comments, criticisms, information, etc... I'd love to hear them.
We're running MySQL 4.1.11-standard.
Thanks!
-TG
___
Sent by ePrompter, the premier email notification software.
Free download
header(Last-Modified: . gmdate(D, d M Y H:i:s) . GMT); // always
modified
header(Cache-Control: no-store, no-cache, must-revalidate); // HTTP/1.1
header(Cache-Control: post-check=0, pre-check=0, false); // HTTP/1.1
header(Pragma: no-cache); // HTTP/1.0
good luck!
-TG
= = = Original message
did that part 'normal')
ApptTime: HH:MM [AM|PM]
Thanks for the response though Stephen... always worth going over the simple
stuff first. :)
-TG
= = = Original message = = =
Could you not just add:
ORDER BY ApptDate, ApptTime
To the end of your SQL - this will order the set by date then time
%H:%i:%s')
duh... hah. Thanks! I knew it was something simple.
-TG
--
What's wrong with [using] this?
mysql select str_to_date('2005-10-27 07:00 PM', '%Y-%m-%d %l:%i %p');
+-+
| str_to_date('2005-10-27 07:00 PM', '%Y-%m-%d
type=submit
/form
?php
if (isset($_POST['testarea'])) {
echo nl2br($_POST['testarea']);
}
?
Look at the source code after you submit if you have any doubts/questions.
-TG
= = = Original message = = =
use the nl2br() function to convert the newlines to br
bastien
From: Alex Major [EMAIL
= SELECTED;
else
$selected = ;
echo option value='$i'$selected$selectMonthText/option\n;
echo /select\n;
-TG
= = = Original message = = =
I am trying to format the month portion of a date that I am trying to
pull from MySQL to be placed into a drop down menu to modify the date.
I
guessing.
Let us know if you find anything else out.
-TG
= = = Original message = = =
After adding echo mysql_error(); I get the same result. I tried changing
the query to include 109fh7 (a table which doesn't exist) and got the same
result as with 109fh6. Changing to 109fh5 does pull up
think you get the idea
I'm trying to convey.
-TG
= = = Original message = = =
I have table and insert data using song_id, that means one artist can have
many song_ids. my question is how can I query distinct artist with his/her
song_id while I will not get duplicate data like duplicate artist
to do though, definitely check out serialize (unless
someone knows something I don't).
Serialize() should do essentially what's being proposed below, just without
having to figure out what string may not be in your array.
good luck!
-TG
= = = Original message = = =
if you just have a simple
.
-TG
= = = Original message = = =
Yes, this has been mentioned in this thread. But with serialize/
unserialize, you can run into other problems that may be more
confusing/difficult to troubleshoot. e.g.:
http://www.php.net/serialize
As you can see, the original array :
$arr[20041001103319
better ways of doing this, I'm all for hearing it. Please opine
or criticize what I've posted above too. I want to learn as well.
-TG
Code:
?php
/**
*~DBSanitizeData() prepares data for inserting/updating into or selecting from
* MySQL by making sure that string data is properly escaped so
. Now off to find my newer version and make sure I
chaned it there too.
-TG
= = = Original message = = =
no !!!
mysql_real_escape_string()
anyhow.. good luck with your security endeavors!
On 8/25/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
I'm pretty amateur at this too, but have done
but will make your case
sensitivity issue moot.
HTH
-TG
= = = Original message = = =
Hi there everyone,
I have a little problem, I have a search where people can search the address
of a property BUT the search is case sensitive, I don~t WANT it to be. I~m
using MySQL and PHP and I generally
. Down here it says Cargo System databases you'll
find examples that might help. Sorry to be vague, but hopefully it's a start
for you. Once you get it configured, it should work fairly fluidly.
-TG
= = = Original message = = =
I have been asked by my client to use SQL Server for my php
-assuming what your configuration is. Mind giving us more
detail on the process you're trying to fix? Users connects to web server, web
server makes ODBC connection (by what means?), etc..
-TG
= = = Original message = = =
Hi,
I have an intranet application that I wrote in PHP that has worked great
handles the connection.
Don't know if that helps, but that's the next place I'd check, unless someone
else has better insight.
-TG
= = = Original message = = =
Thanks for the response!
Yes, believe it or not it does work, or at least did on IIS 5. When I
turn on Integrated Security on the web
actually Akron and not some suburb of Chicago or
something, then you're going to have to tell it yourself. I think this is the
best solution for you.
Best of luck!
-TG
= = = Original message = = =
Hi there everyone,
I~m using the following code to populate cities from a huge database
address.
Good luck Matt!
-TG
= = = Original message = = =
We have about 20,000 addresses in our database.
If my users are filling out a form that requires an address already in our
database I have to make sure they enter it in a format already in the db
(such as West Road not West Rd.). I
a string?)
If so, the === should work I believe. It should compare variable types as well
as values so it shouldn't convert 0002 to just 2 before doing the evaluation.
Good luck!
-TG
= = = Original message = = =
Hi List,
I was comparing two values, a current value with a new value to build
68 matches
Mail list logo