FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » getting amount of deleted rows from: $result=odbc_exec($conn, 'delete from....');
Show: Today's Messages :: Polls :: Message Navigator
Switch to threaded view of this topic Create a new topic Submit Reply
getting amount of deleted rows from: $result=odbc_exec($conn, 'delete from....'); [message #169489] Wed, 15 September 2010 09:21 Go to next message
jodleren is currently offline  jodleren
Messages: 7
Registered: September 2010
Karma: 0
Junior Member
As the header says:

$result=odbc_exec($conn, 'delete from....');
echo ".... rows deleted";

I want to know how much I deleted.... probably very simple, but hard
to find :)

Sonnich
Re: getting amount of deleted rows from: $result=odbc_exec($conn, 'delete from....'); [message #169491 is a reply to message #169489] Wed, 15 September 2010 09:22 Go to previous messageGo to next message
jodleren is currently offline  jodleren
Messages: 7
Registered: September 2010
Karma: 0
Junior Member
On Sep 15, 12:21 pm, jodleren <sonn...@hot.ee> wrote:
> As the header says:
>
> $result=odbc_exec($conn, 'delete from....');
> echo ".... rows deleted";
>
> I want to know how much I deleted.... probably very simple, but hard
> to find :)
>
> Sonnich

It is Oracle btw
Re: getting amount of deleted rows from: $result=odbc_exec($conn, 'delete from....'); [message #169493 is a reply to message #169491] Wed, 15 September 2010 11:38 Go to previous messageGo to next message
Jerry Stuckle is currently offline  Jerry Stuckle
Messages: 2598
Registered: September 2010
Karma: 0
Senior Member
On 9/15/2010 5:22 AM, jodleren wrote:
> On Sep 15, 12:21 pm, jodleren<sonn...@hot.ee> wrote:
>> As the header says:
>>
>> $result=odbc_exec($conn, 'delete from....');
>> echo ".... rows deleted";
>>
>> I want to know how much I deleted.... probably very simple, but hard
>> to find :)
>>
>> Sonnich
>
> It is Oracle btw

Does Oracle provide this information?

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex(at)attglobal(dot)net
==================
Re: getting amount of deleted rows from: $result=odbc_exec($conn, 'delete from....'); [message #169494 is a reply to message #169493] Wed, 15 September 2010 11:50 Go to previous messageGo to next message
jodleren is currently offline  jodleren
Messages: 7
Registered: September 2010
Karma: 0
Junior Member
On Sep 15, 2:38 pm, Jerry Stuckle <jstuck...@attglobal.net> wrote:
> On 9/15/2010 5:22 AM, jodleren wrote:
>
>> On Sep 15, 12:21 pm, jodleren<sonn...@hot.ee>  wrote:
>>> As the header says:
>
>>> $result=odbc_exec($conn, 'delete from....');
>>> echo ".... rows deleted";
>
>>> I want to know how much I deleted.... probably very simple, but hard
>>> to find :)
>
>>> Sonnich
>
>> It is Oracle btw
>
> Does Oracle provide this information?

For update and delete it return a number of "rows affected". That is
all I want :)
Re: getting amount of deleted rows from: $result=odbc_exec($conn, 'delete from....'); [message #169495 is a reply to message #169489] Wed, 15 September 2010 12:03 Go to previous messageGo to next message
Captain Paralytic is currently offline  Captain Paralytic
Messages: 204
Registered: September 2010
Karma: 0
Senior Member
On 15 Sep, 10:21, jodleren <sonn...@hot.ee> wrote:
> As the header says:
>
> $result=odbc_exec($conn, 'delete from....');
> echo ".... rows deleted";
>
> I want to know how much I deleted.... probably very simple, but hard
> to find :)
>
> Sonnich

Oh it was just SOOOO hard to find.

I had top search google for
php odbc rows deleted
and lo and behold a link to
http://php.net/manual/en/function.odbc-num-rows.php
as the second site reference with the abstract:
This function calls SQLRowCount, which according to the ODBC
Specification returns "the number of rows affected by an UPDATE,
INSERT, or DELETE statement;

Wow that was so hard I had better go and lay down for a rest.
Re: getting amount of deleted rows from: $result=odbc_exec($conn, 'delete from....'); [message #169496 is a reply to message #169494] Wed, 15 September 2010 12:05 Go to previous messageGo to next message
Willem Bogaerts is currently offline  Willem Bogaerts
Messages: 8
Registered: September 2010
Karma: 0
Junior Member
>>>> $result=odbc_exec($conn, 'delete from....');
>>>> echo ".... rows deleted";
>>
>>>> I want to know how much I deleted.... probably very simple, but hard
>>>> to find :)
>>
>>> It is Oracle btw

Better ask in an oracle newsgroup. Oracle could have variables or
functions to read such things.

Good luck,
--
Willem Bogaerts

Application smith
Kratz B.V.
http://www.kratz.nl/
Re: getting amount of deleted rows from: $result=odbc_exec($conn, 'delete from....'); [message #169497 is a reply to message #169495] Wed, 15 September 2010 12:50 Go to previous messageGo to next message
jodleren is currently offline  jodleren
Messages: 7
Registered: September 2010
Karma: 0
Junior Member
On Sep 15, 3:03 pm, Captain Paralytic <paul_laut...@yahoo.com> wrote:
> On 15 Sep, 10:21, jodleren <sonn...@hot.ee> wrote:
>
>> As the header says:
>
>> $result=odbc_exec($conn, 'delete from....');
>> echo ".... rows deleted";
>
>> I want to know how much I deleted.... probably very simple, but hard
>> to find :)
>
>> Sonnich
>
> Oh it was just SOOOO hard to find.
>
> I had top search google for
> php odbc rows deleted
> and lo and behold a link tohttp://php.net/manual/en/function.odbc-num-rows.php
> as the second site reference with the abstract:
> This function calls SQLRowCount, which according to the ODBC
> Specification returns "the number of rows affected by an UPDATE,
> INSERT, or DELETE statement;
>
> Wow that was so hard I had better go and lay down for a rest.

Not funny.
You know, that as programmer you might know the solution, but with new
language you are lost. You have an idea, but cannot build it yet.
From my previous expireinces, I always get the "rows affected", so
reading it out here like this is new to.
Therefore, if you dont know what to look for, it is pretty hard to
find.

Thanks for the help btw

Sonnich
Re: getting amount of deleted rows from: $result=odbc_exec($conn, 'delete from....'); [message #169498 is a reply to message #169497] Wed, 15 September 2010 13:10 Go to previous messageGo to next message
Luuk is currently offline  Luuk
Messages: 329
Registered: September 2010
Karma: 0
Senior Member
On 15-09-10 14:50, jodleren wrote:
> Therefore, if you dont know what to look for, it is pretty hard to
> find.
>
> Thanks for the help btw
>
> Sonnich

http://www.google.com/support/websearch/bin/answer.py?hl=en&answer=1344 79

or

http://tinyurl.com/ddfhx2

might help

--
Luuk
Re: getting amount of deleted rows from: $result=odbc_exec($conn, 'delete from....'); [message #169499 is a reply to message #169497] Wed, 15 September 2010 13:53 Go to previous message
Captain Paralytic is currently offline  Captain Paralytic
Messages: 204
Registered: September 2010
Karma: 0
Senior Member
On 15 Sep, 13:50, jodleren <sonn...@hot.ee> wrote:
> On Sep 15, 3:03 pm, Captain Paralytic <paul_laut...@yahoo.com> wrote:
>
>
>
>
>
>> On 15 Sep, 10:21, jodleren <sonn...@hot.ee> wrote:
>
>>> As the header says:
>
>>> $result=odbc_exec($conn, 'delete from....');
>>> echo ".... rows deleted";
>
>>> I want to know how much I deleted.... probably very simple, but hard
>>> to find :)
>
>>> Sonnich
>
>> Oh it was just SOOOO hard to find.
>
>> I had top search google for
>> php odbc rows deleted
>> and lo and behold a link tohttp://php.net/manual/en/function.odbc-num-rows.php
>> as the second site reference with the abstract:
>> This function calls SQLRowCount, which according to the ODBC
>> Specification returns "the number of rows affected by an UPDATE,
>> INSERT, or DELETE statement;
>
>> Wow that was so hard I had better go and lay down for a rest.
>
> Not funny.
> You know, that as programmer you might know the solution, but with new
> language you are lost. You have an idea, but cannot build it yet.
> From my previous expireinces, I always get the "rows affected", so
> reading it out here like this is new to.
> Therefore, if you dont know what to look for, it is pretty hard to
> find.
All I did was took the key words from your post. I didn't know the
answer as I have never used odbc in php. I just used a bit of common
sense and thought:
"the guy is using ODBC in PHP and he wants a count of ROWS DELETED"

So I had no more idea of "what to look for" than you did!

In fact:
php odbc rows affected
also works.
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Last element in an array?
Next Topic: Removing insignificant decimal characters?
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Fri Nov 22 23:26:09 GMT 2024

Total time taken to generate the page: 0.02511 seconds