Use this variable:

$REMOTE_ADDR.

Such that:

$client_IP = $REMOTE_ADDR;
UPDATE clients SET ipaddr= $client_IP WHERE [EMAIL PROTECTED];

I hope this is useful for your code.

Mazhar Bilen

----- Original Message ----- From: "Laszlo Thoth" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, September 30, 2004 8:11 PM
Subject: client ip address



Is there a variable or function in MySQL which resolves to the connecting
client's IP address? I have SQL clients which will be connecting through a NAT
firewall. I want to keep a record of IP of the client that connected to it. It
would look something like this:


UPDATE clients SET ipaddr=INET_ATON( @CLIENT_IP ) WHERE [EMAIL PROTECTED];
                                    ^^^^^^^^^^
                                  what goes here?

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]




-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]



Reply via email to