Am i doing this wrong?


Posted on 16th Feb 2014 07:03 pm by admin

Im pulling from an Oracle database some info... one of which is a field count_pnums which is a NUMBER type field.
Code: <?php
$sql_E = "SELECT count_pnums, dist_pnums FROM pcsmgr.mvx_phone_history_io WHERE calldate BETWEEN '$tapit_sDate' AND '$tapit_eDate' AND extension = '$mvx_ext' AND calltype = '$calltype' AND callcat = '$callcat'";
$go_E = oci_parse($conn, $sql_E);
Did you know?Explore Trending and Topic pages for more stories like this.
oci_execute($go_E);
$all_count = "";
$unq_count = "";

while($row_E = oci_fetch_assoc($go_E))
{
$all_count += $row_E['COUNT_PNUMS'];

$unq_count += $row_E['DIST_PNUMS'];
}
if($unique == "All") // ECHO COUNTED PHONE CALLS
{
echo $all_count;
}
if($unique == "Unique") // ECHO DISTINCT PHONE CALLS
{
echo $unq_count;
}
?>

Any idea why my echo $all_count or echo $unq_count dont echo anything?
I'm sure all the variables used in the query contain the correct info. I dont know if my query is failing or if my $all_count+=$row_E.... isnt working.

Thanks!
No comments posted yet

Your Answer:

Login to answer
281 Like 18 Dislike
Previous forums Next forums
Other forums

Form validation with functions
Hi there

I am trying to make a very simple form validation function. I currently have the fol

How to know if online site made with PHP
Hello,
I see some sites that does not display extensions at all , for example:

www.site.co

Why use interfaces in PHP (OOP)
I am learning OOP in PHP and its been a pretty good learning experience so far. What I didn't unders

Help With editting and deleting form
So look at this image :

http://img194.imageshack.us/img194/8272/snapshot5f.png
This table

MySQL noob question
hi guys

I have a simple mysql table set up, along the lines of

Col 1 - Col 2 - Date_l

$action = "insert"; //$action = $_GET['action'];
$action = "insert";
//$action = $_GET['action'];

why is this invalid type? I am

The control with ID 'ace' requires a ScriptManager on the page
I'm trying to add a simple AlwaysVisibleControlExtender to my page, but it's not working. I get the

parsing error
can anyone explain this syntax error:

Parse error: syntax error, unexpected T_IF

The e

How to refresh a parent page from a modal popup
Hi,I have a modal popup in which I need to upload a file and store in the database should give a mes

listcube issue
Hi
I have a virtual cube ZREMOTE. I use Tcode "listcube" to retrieve contents. I use of the

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash