on 1/25/01 1:12 PM, Robert ([EMAIL PROTECTED]) wrote:
> Still not working right though
>
> if($act=="ADD"){
> $sql="INSERT INTO ecomm (ID,part) VALUES ('$sid','$spp')";
> if(! mysql_query('$sql')){echo("Unable to add
> part.");mysql_close($db);exit();}
> }
Why the single quotes around $sql. It
This link is passed to the shopping cart type script where I want to put the spp and
the sid into the database.
http://tech2000/rfq.php?spp=MC68020RC12T&pkg=PGA&mfc=MOT&act=ADD&sid=583607ba7b565b6d699da58d7c7fe9ab
// Connect to Database ---
$db
ignore that last one :)
I goofed...
Still not working right though
if($act=="ADD"){
$sql="INSERT INTO ecomm (ID,part) VALUES ('$sid','$spp')";
if(! mysql_query('$sql')){echo("Unable to add part.");mysql_close($db);exit();}
}
just gives me "Unable to add part"
Warning: Supplied argument is not a valid MySQL-Link resource in
c:\inetpub\wwwroot\rfq.php on line 16
Unable to add part
//--- Add part --
if($act=="ADD"){
$sql="INSERT INTO ecomm (ID,part) VALUES $sql.="('$sid','$spp')";
if(! mysql_db_que
Alright, you have a textarea in a form, say some one
right this:
Today, during the meeting blah blah blah... (now they
want to start a new paragraph, so they press enter
twice.)
After the construction meeting blah blah blah...
Ok... Now the question. The addslashes() command
won't add the NUL
They are both set as text
they store numbers and letters from this link ( it's my local development
machine )
http://tech2000/rfq.php?spp=MC68020RC12E&pkg=PGA&mfc=MOT&act=ADD&sid=583607b
a7b565b6d699da58d7c7fe9ab
- Original Message -
From: "Darryl Friesen" <[EMAIL PROTECTED]>
To: "Robert
Warning: Wrong parameter count for mysql_db_query() in c:\inetpub\wwwroot\rfq.php on
line 15
Unable to add part.
line 15 is:
if(! mysql_db_query("$sql")){echo("Unable to add part.");mysql_close($db);exit();}
> It still didn't work.
> just says unable to add part
> > $sql = "INSERT INTO ecomm (ID,part) VALUES ('$sid','$spp')";
Another thought: Are ID and part character data of some sort? If not (i.e.
if ID is an int) then remove the single quotes.
- Darryl
Guess this would be more info
// Connect to Database ---
$db = mysql_pconnect("tech2000", "wwwguest", "guest");
if(!$db){echo("Unable to connect to database server.");exit();}
if(! @mysql_select_db("bruininv")){echo("Unable to select
database.");m
> It still didn't work.
> just says unable to add part
Remove the @ from @mysql_db_query and it will spit out the SQL error
explaining why the query fails. That should help for debugging.
- Darryl
--
Darryl Friesen, B.Sc
try this:
$db = mysql_connect(host,uid,pwd);
if($act=="ADD"){
$sql="INSERT INTO ecomm (ID,part) VALUES ('$sid','$spp')";
$res = mysql_db_query($dbname,$sql,$db);
if(!$res){
echo("Unable to add part.");
mysql_close($db);
exit();
}
}
you didn't specify $dbname
-Original Message-
Hello!
> I have a problem with a mysql query!
> after the query the result variable is "resource id 2"
> what is wrong!
Nothing.
Read the manual, even the mysq_fetch_array($result) function.
Mage
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [E
MaxClients in httpd.conf reduces your total server performance in case you
have not only db-actions but also images and plain files ...
if you use something other than ocilogon you open a persistant link that
might not be closed. (try using ocilogon instead of eg ociplogon)
close every connectio
It still didn't work.
just says unable to add part
$db = mysql_connect("tech2000", "wwwguest", "guest");
- Original Message -
From: "Darryl Friesen" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, January 25, 2001 2:02 PM
Subject: Re: [PHP-DB] insert into mysql
>
> > //-
Hi.
I have a problem with a mysql query!
after the query the result variable is "resource id 2"
what is wrong!
Thanks!
> You're INSERT query is wrong. Take the ',$db' off the end.
^^
Oops. That's "Your". Long day.
- Darryl
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators,
> //--- Add part --
> if($act=="ADD"){
> $sql="INSERT INTO ecomm (ID,part) VALUES ('$sid','$spp'),$db";
> if(! @mysql_db_query("$sql")){
>echo("Unable to add part."); mysql_close($db);exit();} }
>
> Why does this not work?
>
You're IN
//--- Add part --
if($act=="ADD"){
$sql="INSERT INTO ecomm (ID,part) VALUES ('$sid','$spp'),$db";
if(! @mysql_db_query("$sql")){echo("Unable to add part.");mysql_close($db);exit();}
}
Why does this not work?
Looks fine, now retrieve the rows from the query.
> -Original Message-
> From: Randy Johnson [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, January 25, 2001 12:46 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP-DB] query error
>
>
> When I run any kind of query this is the value of result
Thanks a million, works great now.
- Original Message -
From: "Mark Newnham" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, January 25, 2001 1:41 PM
Subject: RE: [PHP-DB] Help with loop
> $res = mysql_query("SELECT * FROM ecomm where ID ='$sid'",$db))
> if(!$res){ech
MaxClients inyour httpd.conf is a nice way to limit it. :)
Karsten Dambekalns wrote:
>
> On Thu, Jan 25, 2001 at 08:22:07PM +0100, Matthias Kopolt wrote:
> > Are you useing persistent connections (I had no real luck with them)?
> >
> > How do you connect to your DB over Multi Threaded Server (M
When I run any kind of query this is the value of result Resource id #2
Example
$result= mysql_query (" Select * from ACCT_TBL ") or die
("Error".mysql_error());
print result;
any ideas?
randy
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For
$res = mysql_query("SELECT * FROM ecomm where ID ='$sid'",$db))
if(!$res){echo("error preforming query: " . mysql_error());exit();}
//error trap
while( $row=mysql_fetch_array($res)){
$pno=$row["part"];
#
Mark Newnham
Application De
On Thu, Jan 25, 2001 at 08:22:07PM +0100, Matthias Kopolt wrote:
> Are you useing persistent connections (I had no real luck with them)?
>
> How do you connect to your DB over Multi Threaded Server (MTS) or Dedicated
> Server ?
I am just using phplib for the dirty stuff :) So I don't know exactl
Why does this spit out the same part over and over until it times out?
I have 2 tables in the same database
1: bruindba <---Parts database
specific_p
Are you useing persistent connections (I had no real luck with them)?
How do you connect to your DB over Multi Threaded Server (MTS) or Dedicated
Server ?
I think Oracles NET8 Config has a Parameter to limit this.
Check out the MasterIndex at
http://technet.oracle.com/doc/server.815/a68826/toc.
Hi!
I am using PHP to connect to an Oracle 8.1.5 database. Everything works
fine, but the load on the oracle server is insanely high. So I would like to
limit the number of connections. Is there something like the mysql
max_persistent_connections statement?
TIA,
Karsten
BTW: Has some used sqlre
The last time I sent a message to php-list-admin asking for stop this kind
of messages they took the email address off but I was fired of the list too.
Jayme.
http://www.conex.com.br/jjeffman
-Mensagem Original-
De: Jon Niola <[EMAIL PROTECTED]>
Para: <[EMAIL PROTECTED]>; <[EMAIL PROT
I've got an Access dbase and one of the field is memo.
Before showing on web side, I want to convert the memo field from
Windows-1250 codding to ISO-8859-2.
With text fields I do it with below script, but with memo it doesn't
work
const WIN = "ąęćłóśżźĄĘĆŁÓŚŻŹ"
const ISO = ""ąęćłóśżĽˇĆĘŁÓŚŻŹ"
Hello everybody,
I have problems concerning character sets.I use InterBase database.
I have data in columns with character set NONE, but the data is in fact in
win1250 coding. I have other columns with character set WIN1250. I want to
from these NONE columns to these WIN1250 columns, but InterB
Could someone please block this guy's address from the list? I am getting
sick of this crap
At 08:00 AM 1/25/01 -0800, Mike wrote:
>Hi. This is the qmail-send program at toye.php.net.
>I'm afraid I wasn't able to deliver your message to the following addresses.
>This is a permanent error; I've g
Addressed to: "Leo Kuiper" <[EMAIL PROTECTED]>
[EMAIL PROTECTED]
** Reply to note from "Leo Kuiper" <[EMAIL PROTECTED]> Thu, 25 Jan 2001 13:06:53
+0100
>
> Ok I'm kinda new to this list so I'm very sorry for those who've
> heard this question a million times.
>
> How to get binary
After I had to rebuild my linux server I started getting this
error while trying to connect to postgres.
This worked fine before, I first installed the stock RPM`s i.e PHP and
postgres
from the Redhat 6.2 Distribution. After getting this error I thought now is
a good opportunity to
upgrade to PHP
Hi. This is the qmail-send program at toye.php.net.
I'm afraid I wasn't able to deliver your message to the following addresses.
This is a permanent error; I've given up. Sorry it didn't work out.
<[EMAIL PROTECTED]>:
ezmlm responseezmlm-send: fatal: message already has a Mailing-List header (may
Hi. This is the qmail-send program at toye.php.net.
I'm afraid I wasn't able to deliver your message to the following addresses.
This is a permanent error; I've given up. Sorry it didn't work out.
<[EMAIL PROTECTED]>:
ezmlm-manage: fatal: message already has a Mailing-List header (maybe I should
Hi. This is the qmail-send program at toye.php.net.
I'm afraid I wasn't able to deliver your message to the following addresses.
This is a permanent error; I've given up. Sorry it didn't work out.
<[EMAIL PROTECTED]>:
ezmlm-manage: fatal: message already has a Mailing-List header (maybe I should
>INSERT INTO employees (first,last,address,position) VALUES
>('$(first)','$(last)','$(address)','$(position)')
>is because in WML variables are stored as $(first) and not just $first
like in
>HTHML.
>Somewhere between
>$sql = "INSERT INTO employees (first,last,address,position)
> > VALU
Ok I'm kinda new to this list so I'm very sorry for those who've heard this
question a million times.
How to get binary data (jpg file?) AND text from a database, BUT display it
on the same page?
I know the header-content-type blocks all this (either display text or jpg),
but there must be some w
Hi,
I am trying to update a MySQL database using a PHP script embeded in a WML
page. Here is my code:
The following is register2.php:
>
>
>
>
>
>
>
>
>
>
>
> Firs
39 matches
Mail list logo