[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Phpgroupware-developers] proposal-branch; porting
From: |
Dave Hall |
Subject: |
Re: [Phpgroupware-developers] proposal-branch; porting |
Date: |
Wed, 21 Apr 2004 23:21:58 +0000 (GMT) |
Joseph Engo <address@hidden> wrote:
>
> sigurdne wrote:
>
> | How about $GLOBALS['phpgw']->db->db_addslashes()
>
> There are 2 things you can do for this. If you are getting your
> values from a form, safeargs will take care of adding slashes to it.
> Outside of that, you can just use addslashes() from PHP. To be
> honest, I can't remeber why we created our own function for handling
> this. Does anyone remeber ? :P
>
Cos mssql/sybase quotes with '' not \'.
See:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/acdata/ac_8_con_03_7mch.asp
and http://www.php.net/manual/en/ref.sybase.php
> | $GLOBALS['phpgw']->db->get_last_insert_id()
> |
> This is something I need to add. Its very easy to do for PostgreSQL,
> but MySQL is more of a pain. For now, I am just doing a select after
> I add the record.
That is so unreliable. The SELECT MAX(id) may occur after another
INSERT or DELETE operation. As last_insert_id() works fine in the
phplib db classes, I fail to see the problem. The 3 dbs which are
supported in 16 have the support included.
> Which will be fixed later once get_last_insert_id()
> is ported. AdoDB doesn't, from what I understand have something like
> this, or its something they removed over time for whatever reason.
Will all patches which have wider application be fed back up stream, or
a we taking a snap shot and forking ADOdb?
Cheers
Dave
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.2.3 (MingW32)
> Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
>
> iD8DBQFAhvP6tdiALSpS2cgqSvKgcU2M6A=
> =tR13
> -----END PGP SIGNATURE-----
>
>
>
> _______________________________________________
> Phpgroupware-developers mailing list
> address@hidden
> http://mail.gnu.org/mailman/listinfo/phpgroupware-developers
>
dave.hall.vcf
Description: Card for <dave.hall@mbox.com.au>