Update a record is updating the first record in the DB...HELP!

I am going over and over this again and cant find the problem.
i have a form that sends email to emails that are on a php mysql db however when i update certain records it always is updating the first record in the DB...i have looked over this so many times and cant see what is going wrong
the userid is not auto_increment but is based on the username (these are all unique)
i have uncluded the code to see if i am missing something
<?php require_once('../Connections/hostprop.php'); ?>
<?php
if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
  if (PHP_VERSION < 6) {
    $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
  $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);
  switch ($theType) {
    case "text":
      $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
      break;   
    case "long":
    case "int":
      $theValue = ($theValue != "") ? intval($theValue) : "NULL";
      break;
    case "double":
      $theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
      break;
    case "date":
      $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
      break;
    case "defined":
      $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
      break;
  return $theValue;
$editFormAction = $_SERVER['PHP_SELF'];
if (isset($_SERVER['QUERY_STRING'])) {
  $editFormAction .= "?" . htmlentities($_SERVER['QUERY_STRING']);
if ((isset($_POST["MM_update"])) && ($_POST["MM_update"] == "form1")) {
  $updateSQL = sprintf("UPDATE plus_signup SET email=%s, emailerSubject=%s, emailerContent=%s WHERE userid=%s",
                       GetSQLValueString($_POST['email'], "text"),
                       GetSQLValueString($_POST['emailerSubject'], "text"),
                       GetSQLValueString($_POST['emailerContent'], "text"),
                       GetSQLValueString($_POST['userid'], "text"));
  mysql_select_db($database_hostprop, $hostprop);
  $Result1 = mysql_query($updateSQL, $hostprop) or die(mysql_error());
      // Email Guarantor
          $to = $_POST['email'];
          $subject = "Email From Host Student Property";
          $message = "
          <html>
                    <head>
                              <title>Dear ".GetSQLValueString($_POST['userid'], "text")."</title>
                    </head>
                    <body>
                              <img src=\"http://www.hoststudent.co.uk/beta/images/hostlogo.gif\" alt=\"www.HostStudent.co.uk\" />
                              <h2>An Email From Host Students</h2>
                              <br /><br />
                              <table>
                                        <tr>
                                                  <td>Email Subject:</td>
                                        </tr>
                                        <tr>
                                                  <td>".GetSQLValueString($_POST['emailerSubject'], "text")."</td>
                                        </tr>
                                        <tr>
                                                  <td>Email Content</td>
                                        </tr>
                                        <tr>
                                                  <td>".GetSQLValueString($_POST['emailerContent'], "text")."</td>
                                        </tr>
                              </table>
                    </body>
          </html>
          // Always set content-type when sending HTML email
          $headers = "MIME-Version: 1.0" . "\r\n";
          $headers .= "Content-type:text/html;charset=iso-8859-1" . "\r\n";
          $headers .= 'From: HostStudent.co.uk <[email protected]>' . "\r\n";
          $send = mail($to,$subject,$message,$headers);
  $updateGoTo = "TenantEmailSent.php";
  if (isset($_SERVER['QUERY_STRING'])) {
    $updateGoTo .= (strpos($updateGoTo, '?')) ? "&" : "?";
    $updateGoTo .= $_SERVER['QUERY_STRING'];
  header(sprintf("Location: %s", $updateGoTo));
mysql_select_db($database_hostprop, $hostprop);
$query_Recordset1 = "SELECT userid, email, emailerSubject, emailerContent FROM plus_signup";
$Recordset1 = mysql_query($query_Recordset1, $hostprop) or die(mysql_error());
$row_Recordset1 = mysql_fetch_assoc($Recordset1);
$totalRows_Recordset1 = mysql_num_rows($Recordset1);
?>
<?
          session_start();
          if(!$_SESSION['loggedIn']) // If the user IS NOT logged in, forward them back to the login page
                    header("location:Login.html");
?>
   <script type="text/javascript">
function loadFields(Value) {
         var Guarantor = Value.split("|");
          var userid1 = Guarantor[0] ;
                      var GuName = Guarantor[1];
          var GuPhoneEmail = Guarantor[2] ;
          document.getElementById('userid1').value=userid1;
                      document.getElementById('GuName').value=GuName;
          document.getElementById('GuPhoneEmail').value=GuPhoneEmail;
</script>
<form action="<?php echo $editFormAction; ?>" method="post" name="form2" id="form2">
              <table align="center">
      <tr valign="baseline">
        <td nowrap="nowrap" align="right"> </td>
        <td><select name="userid" id="userid" onchange="loadFields(this.value)">
          <option value="Select Guarantor">Select Guarantor</option>
          <?php
do {
?>
<option value="<?php echo $row_Recordset1['userid'] . '|' . $row_Recordset1['GuName'] . '|' . $row_Recordset1['GuPhoneEmail'];?>"><?php echo $row_Recordset1['userid'] . " , " . $row_Recordset1['GuName'] . " , " . $row_Recordset1['GuPhoneEmail']; ?></option>
          <?php
} while ($row_Recordset1 = mysql_fetch_assoc($Recordset1));
  $rows = mysql_num_rows($Recordset1);
  if($rows > 0) {
      mysql_data_seek($Recordset1, 0);
            $row_Recordset1 = mysql_fetch_assoc($Recordset1);
?>
        </select></td>
      </tr>
      <tr valign="baseline">
        <td nowrap="nowrap" align="right">Tenant Name</td>
        <td><input type="text" name="userid1" id="userid1" readonly="readonly" value="<?php echo htmlentities($row_Recordset1['userid'], ENT_COMPAT, 'utf-8'); ?>" size="32" /></td>
      </tr>
      <tr valign="baseline">
        <td nowrap="nowrap" align="right">GuName:</td>
        <td><input type="text" name="GuName" id="GuName" readonly="readonly" value="<?php echo htmlentities($row_Recordset1['GuName'], ENT_COMPAT, 'utf-8'); ?>" size="32" /></td>
      </tr>
      <tr valign="baseline">
        <td nowrap="nowrap" align="right">GuPhoneEmail:</td>
        <td><input type="text" name="GuPhoneEmail" id="GuPhoneEmail" readonly="readonly" value="<?php echo htmlentities($row_Recordset1['GuPhoneEmail'], ENT_COMPAT, 'utf-8'); ?>" size="32" /></td>
      </tr>
      <tr valign="baseline">
        <td nowrap="nowrap" align="right">GuEmailerSubject:</td>
        <td><input type="text" name="GuEmailerSubject" value="" size="32" /></td>
      </tr>
      <tr valign="baseline">
        <td nowrap="nowrap" align="right">GuEmailerContent:</td>
        <td><textarea name="GuEmailerContent" cols="45" rows="5"> </textarea></td>
      </tr>
      <tr valign="baseline">
        <td nowrap="nowrap" align="right"> </td>
        <td><input type="submit" value="Send email" /></td>
      </tr>
      <tr valign="baseline">
        <td nowrap="nowrap" align="right"></td>
        <td> </td>
      </tr>
              </table>
    <input type="hidden" name="MM_update" value="form2" />
    <input type="hidden" name="userid" value="<?php echo $row_Recordset1['userid']; ?>" />
</form>

i have found the problem, there were two forms with the same name..
thanks

Similar Messages

  • Does re-running a MDM Initial Load restart from the first record?

    Is there a way to restart an Initial load?  I was running a new initial materials load in my ECC system for MDM (MDM_CLNT_EXTR) which was running a very long time (5 days).  The background job hit a bad piece of data and crashed.
    My question is: when I re-run my initial load job, will it start over from the first record, or will it pick up from the last material/IDOC and resume processing?  I would prefer not to re-process all 1.7M materials since the job was very near the end before it crashed.
    Thanks,
    Denis

    Hello,
    There are two modes which are available in Client Extractor, Initial and Delta.
    If you select Initial it will start from the first record, that you mention in the selection Criteria.
    In Delta mode, any new records created will be sent to MDM.
    For your issue, in the initial mode, select the Material Number from and to, which have not been updated in MDM.
    This is will ensure, that only the records that have not been sent.
    Regards,
    Abhishek

  • How to select the first record?

    Hi,
    Could anyone tell me how to select the first record of every
    group?
    ex, I want to find out every customer their first purcaseDate.
    CustomerID PurcaseDate Region
    A00000001 2001/01/01 AA
    A00000001 2001/02/02 AA
    A00000002 2001/03/01 AC
    A00000002 2001/05/07 AC
    A00000003 2001/03/05 DD
    result:
    A00000001 2001/01/01 AA
    A00000002 2001/03/01 AC
    A00000003 2001/03/05 DD
    Thanks

    Vincent,
    You could do it as Carl suggested, with a couple of
    corrections.  You would need to include the CustomNo column in
    the order by clause of your cursor.  You would also need to add
    a where clause to your update statement, otherwise everywhere
    Region in the table would be updated with the same value of the
    last CustomNo in the cursor, regardless of the CustomNo in the
    table.  See corrected code below:
    DECLARE
      CURSOR     cust
      IS
      SELECT     DISTINCT CustomNo, Region, Purchase_Date
      FROM       my_table
      ORDER BY   CustomNo, Purchase_Date, Region;
      c_customer VARCHAR2 (9) := '...';
      c_region   VARCHAR2 (2) := '..';
      cntr       NUMBER := 0;
    BEGIN
      FOR x IN cust
      LOOP
        IF x.CustomNo != c_customer
        THEN
          c_customer := x.CustomNo;
          c_region := x.Region;
        ELSE
          UPDATE my_table
          SET    Region = c_region
          WHERE  CustomNo = c_customer;
          cntr := cntr + 1;
          IF cntr = 25
          THEN
            COMMIT;
            cntr := 0;
          END IF;
        END IF;
      END LOOP;
      COMMIT;
    EXCEPTION
      WHEN OTHERS THEN 
        NULL;
    END;
    Another option is that you could just use one update statement,
    like this:
    UPDATE my_table a
    SET    Region =
           (SELECT DISTINCT Region
            FROM   my_table b
            WHERE  (CustomNo, Purchase_Date) IN
                   (SELECT   CustomNo, MIN (Purchase_Date)
                    FROM     my_table
                    GROUP BY CustomNo)
            AND    a.CustomNo = b.CustomNo)
    Barbara

  • Recording Audio Cuts off the first part of the region?

    Hi. When i record audio the regions show up after recording and i have to pull the beginning of the region back a bit so that i can see the full length of the audio recording. Its non destructive but very annyoing. How can i stop it doing this everytime? Thanks

    Thanks Mike for replying
    But the thing is; I want to perform a computation process on the list manager values to trim off the first part of the string. I have the dynamic lov for list manager. But when I insert/update list manager item values I don't want the first part of string in the database.
    Please help with the function. i was trying the below function but it doesn't work; errors out saying
    ORA-06550: line 16, column 14: PLS-00597: expression 'V_ARRAY_1' in the INTO list is of wrong type ORA-06550: line 17, column 9: PL/SQL: ORA-00904: : invalid identifier ORA-06550: line 15, column 7: PL/SQL: SQL Statement ignored
    {code}
    DECLARE
       v_array          apex_application_global.vc_arr2;
       v_array_1         apex_application_global.vc_arr2;
       v_string         VARCHAR2 (32767);
       BEGIN
       -- Convert delimited string to array
       v_array :=
          APEX_UTIL.
           string_to_table (:P3_LM_USES);
       FOR i IN 1 .. v_array.COUNT
       LOOP
          SELECT LTRIM (SUBSTR (v_array (i), INSTR (v_array (i), '..') + 2))
            INTO v_array_1
            FROM DUAL;
    v_string := HTMLDB_UTIL.table_to_string(v_array_1,':');
    apex_application.g_print_success_message := apex_application.g_print_success_message || v_string;
             END LOOP;
    RETURN (v_string);
    END;
    {code}
    Thanks,
    Orton

  • I've tried to update my i-Tunes version after the site suggested I should following my i-Pad being plugged into it for the first time. The update seemed successful but the program would not open at all despite switching off the PC and re-starting several

    I’ve tried to update my i-Tunes version after the site suggested I should following my i-Pad Air being plugged into it for the first time. The update seemed successful but the program would not open at all despite switching off the PC and re-starting several times. I then tried wiping the original software from the computer and re-downloading from scratch. Each time I tried the download failed with a message saying “Service “Apple Mobile Device” failed to start. Verify that you have sufficient privileges to start system services” At this stage, the only way forward was to “abort” the download. This I have done now four times and the same thing happens. When I did finally manage to get an i-Tunes shortcut on my desktop, the program wouldn’t open saying: “i-Tunes was not installed correctly. Please re-install i-Tunes. Error 7 (Windows error 193)” Any ideas to resolve this?

    Try the following user tip:
    Troubleshooting issues with iTunes for Windows updates

  • My MacBook Pro 10.6.8 prompted me of a new itunes update this morning, so i downloaded it. Since then itunes has been starting up randomly on its own, and starts playing the first song on the list. I quit itunes, and it keeps reopening.

    My MacBook Pro 10.6.8 prompted me of a new itunes update this morning, so i downloaded it. Since then itunes has been starting up randomly on its own, and starts playing the first song on the list. I pause the song, and it resumes it on its own again. I'm not joking. So, I end up quiting out of itunes; but, it starts right back up again on its own. After quiting out of the app a few times, it eventually stops reopening; however, about an hour later (or less) it opens again. HOW DO I MAKE IT STOP? I'm just about to delete itunes, because I've had enough of this crap. I hope someone can help. I've restarted the laptop, and it seemed like that fixed it, then itunes started up doing the same thing again an hour later. ituneshelper is unchecked; bluetooth is off; i only have speakers and a mouse plugged in (also charger).

    Read this Apple Discussion Thread and possible solutions. The audio jack has been the main culprit, also certain sync and automation settings including connected remotes.

  • Report without the first record using JasperReports

    Hi everyone,
    I�m using JasperReports127 but the first record is not being showed...
    I really don�t know why... Does someone had the same problem?!
    I follow this tutorial:
    http://developers.sun.com/prodtech/javatools/jscreator/learning/tutorials/2/reports.html
    Gustavo Callou

    I forgot to say that what ir really interesting is that in the iReport Aplication the report works fine... but in the jsc not...
    my setor.jrxml is bellow:
    <?xml version="1.0" encoding="UTF-8" ?>
    <!-- Created with iReport - A designer for JasperReports -->
    <!DOCTYPE jasperReport PUBLIC "//JasperReports//DTD Report Design//EN" "http://jasperreports.sourceforge.net/dtds/jasperreport.dtd">
    <jasperReport
              name="classic"
              columnCount="1"
              printOrder="Vertical"
              orientation="Portrait"
              pageWidth="595"
              pageHeight="842"
              columnWidth="535"
              columnSpacing="0"
              leftMargin="30"
              rightMargin="30"
              topMargin="20"
              bottomMargin="20"
              whenNoDataType="NoPages"
              isTitleNewPage="false"
              isSummaryNewPage="false">
         <property name="ireport.scriptlethandling" value="0" />
         <property name="ireport.encoding" value="UTF-8" />
         <import value="java.util.*" />
         <import value="net.sf.jasperreports.engine.*" />
         <import value="net.sf.jasperreports.engine.data.*" />
         <queryString><![CDATA[select *
    from tb_setor
    where tb_setor.incodigosetor > '0'
    order by tb_setor.vanome
    ]]></queryString>
         <field name="INCODIGOSETOR" class="java.math.BigDecimal"/>
         <field name="VANOME" class="java.lang.String"/>
         <field name="VARAMAL" class="java.lang.String"/>
              <background>
                   <band height="0" isSplitAllowed="true" >
                   </band>
              </background>
              <title>
                   <band height="50" isSplitAllowed="true" >
                        <staticText>
                             <reportElement
                                  x="61"
                                  y="5"
                                  width="412"
                                  height="40"
                                  key="staticText"/>
                             <box topBorder="None" topBorderColor="#000000" leftBorder="None" leftBorderColor="#000000" rightBorder="None" rightBorderColor="#000000" bottomBorder="None" bottomBorderColor="#000000"/>
                             <textElement textAlignment="Center">
                                  <font size="28" isBold="true"/>
                             </textElement>
                        <text><![CDATA[Setores]]></text>
                        </staticText>
                        <line direction="TopDown">
                             <reportElement
                                  x="0"
                                  y="48"
                                  width="534"
                                  height="0"
                                  forecolor="#000000"
                                  key="line"
                                  positionType="FixRelativeToBottom"/>
                             <graphicElement stretchType="NoStretch" pen="2Point"/>
                        </line>
                        <line direction="TopDown">
                             <reportElement
                                  x="0"
                                  y="3"
                                  width="534"
                                  height="0"
                                  forecolor="#000000"
                                  key="line"/>
                             <graphicElement stretchType="NoStretch" pen="2Point"/>
                        </line>
                   </band>
              </title>
              <pageHeader>
                   <band height="9" isSplitAllowed="true" >
                   </band>
              </pageHeader>
              <columnHeader>
                   <band height="20" isSplitAllowed="true" >
                        <rectangle radius="0" >
                             <reportElement
                                  mode="Opaque"
                                  x="1"
                                  y="1"
                                  width="534"
                                  height="17"
                                  forecolor="#000000"
                                  backcolor="#999999"
                                  key="element-22"/>
                             <graphicElement stretchType="NoStretch" pen="Thin"/>
                        </rectangle>
                        <staticText>
                             <reportElement
                                  x="0"
                                  y="1"
                                  width="267"
                                  height="16"
                                  forecolor="#FFFFFF"
                                  key="element-90"/>
                             <box topBorder="None" topBorderColor="#000000" leftBorder="None" leftBorderColor="#000000" leftPadding="2" rightBorder="None" rightBorderColor="#000000" rightPadding="2" bottomBorder="None" bottomBorderColor="#000000"/>
                             <textElement>
                                  <font fontName="" size="12"/>
                             </textElement>
                        <text><![CDATA[Setor]]></text>
                        </staticText>
                        <staticText>
                             <reportElement
                                  x="267"
                                  y="1"
                                  width="267"
                                  height="16"
                                  forecolor="#FFFFFF"
                                  key="element-90"/>
                             <box topBorder="None" topBorderColor="#000000" leftBorder="None" leftBorderColor="#000000" leftPadding="2" rightBorder="None" rightBorderColor="#000000" rightPadding="2" bottomBorder="None" bottomBorderColor="#000000"/>
                             <textElement>
                                  <font fontName="" size="12"/>
                             </textElement>
                        <text><![CDATA[Ramal]]></text>
                        </staticText>
                   </band>
              </columnHeader>
              <detail>
                   <band height="19" isSplitAllowed="true" >
                        <line direction="TopDown">
                             <reportElement
                                  x="0"
                                  y="17"
                                  width="535"
                                  height="0"
                                  forecolor="#808080"
                                  key="line"
                                  positionType="FixRelativeToBottom"/>
                             <graphicElement stretchType="NoStretch" pen="Thin"/>
                        </line>
                        <textField isStretchWithOverflow="true" pattern="" isBlankWhenNull="true" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" >
                             <reportElement
                                  x="0"
                                  y="1"
                                  width="267"
                                  height="15"
                                  key="textField"/>
                             <box topBorder="None" topBorderColor="#000000" leftBorder="None" leftBorderColor="#000000" leftPadding="2" rightBorder="None" rightBorderColor="#000000" rightPadding="2" bottomBorder="None" bottomBorderColor="#000000"/>
                             <textElement>
                                  <font fontName="Times-Roman" size="12"/>
                             </textElement>
                        <textFieldExpression class="java.lang.String"><![CDATA[$F{VANOME}]]></textFieldExpression>
                        </textField>
                        <textField isStretchWithOverflow="true" pattern="" isBlankWhenNull="true" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" >
                             <reportElement
                                  x="267"
                                  y="1"
                                  width="267"
                                  height="15"
                                  key="textField"/>
                             <box topBorder="None" topBorderColor="#000000" leftBorder="None" leftBorderColor="#000000" leftPadding="2" rightBorder="None" rightBorderColor="#000000" rightPadding="2" bottomBorder="None" bottomBorderColor="#000000"/>
                             <textElement>
                                  <font fontName="Times-Roman" size="12"/>
                             </textElement>
                        <textFieldExpression class="java.lang.String"><![CDATA[$F{VARAMAL}]]></textFieldExpression>
                        </textField>
                   </band>
              </detail>
              <columnFooter>
                   <band height="0" isSplitAllowed="true" >
                   </band>
              </columnFooter>
              <pageFooter>
                   <band height="27" isSplitAllowed="true" >
                        <textField isStretchWithOverflow="false" pattern="" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" >
                             <reportElement
                                  x="325"
                                  y="4"
                                  width="170"
                                  height="19"
                                  key="textField"/>
                             <box topBorder="None" topBorderColor="#000000" leftBorder="None" leftBorderColor="#000000" rightBorder="None" rightBorderColor="#000000" bottomBorder="None" bottomBorderColor="#000000"/>
                             <textElement textAlignment="Right">
                                  <font fontName="Helvetica" size="10"/>
                             </textElement>
                        <textFieldExpression class="java.lang.String"><![CDATA["Page " + $V{PAGE_NUMBER} + " of "]]></textFieldExpression>
                        </textField>
                        <textField isStretchWithOverflow="false" pattern="" isBlankWhenNull="false" evaluationTime="Report" hyperlinkType="None" hyperlinkTarget="Self" >
                             <reportElement
                                  x="499"
                                  y="4"
                                  width="36"
                                  height="19"
                                  forecolor="#000000"
                                  backcolor="#FFFFFF"
                                  key="textField"/>
                             <box topBorder="None" topBorderColor="#000000" leftBorder="None" leftBorderColor="#000000" rightBorder="None" rightBorderColor="#000000" bottomBorder="None" bottomBorderColor="#000000"/>
                             <textElement textAlignment="Left" verticalAlignment="Top" rotation="None" lineSpacing="Single">
                                  <font fontName="Helvetica" pdfFontName="Helvetica" size="10" isBold="false" isItalic="false" isUnderline="false" isPdfEmbedded ="false" pdfEncoding ="CP1252" isStrikeThrough="false" />
                             </textElement>
                        <textFieldExpression class="java.lang.String"><![CDATA["" + $V{PAGE_NUMBER}]]></textFieldExpression>
                        </textField>
                        <line direction="TopDown">
                             <reportElement
                                  x="0"
                                  y="1"
                                  width="535"
                                  height="0"
                                  forecolor="#000000"
                                  key="line"/>
                             <graphicElement stretchType="NoStretch" pen="2Point"/>
                        </line>
                        <textField isStretchWithOverflow="false" pattern="" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" >
                             <reportElement
                                  x="1"
                                  y="6"
                                  width="209"
                                  height="19"
                                  key="textField"/>
                             <box topBorder="None" topBorderColor="#000000" leftBorder="None" leftBorderColor="#000000" rightBorder="None" rightBorderColor="#000000" bottomBorder="None" bottomBorderColor="#000000"/>
                             <textElement>
                                  <font fontName="Times-Roman" size="10"/>
                             </textElement>
                        <textFieldExpression class="java.util.Date"><![CDATA[new Date()]]></textFieldExpression>
                        </textField>
                   </band>
              </pageFooter>
              <summary>
                   <band height="0" isSplitAllowed="true" >
                   </band>
              </summary>
    </jasperReport>

  • The detailRegion is always forced to populate the first record from the Master region

    Hi fellow Spry enthusiasts,
    My question is in regards the undesirable data population of
    the regiondetail on initial load. I have 2 sections, one which is
    my master region (which goes out and retrieves a bunch of records),
    and a related detailregion which reacts based on the master.
    However, every time I initiate a query of the master region to
    retrieve records, the detail region also responds and automatically
    grabs the FIRST record of the master region (which is undesirable
    in my case because I do not want the detail region to react UNTIL I
    select a record in the master region). Let me know if this makes
    sense.
    Psuedo Code:
    var moveRequestor = new
    Spry.Data.XMLDataSet("cfc/QueryThatReturnsABunchOfEmployeeRecords")>
    <span spry:region="moveRequestor">
    {EM_ID}
    {NAME}
    <span spry:detailregion="moveRequestor">
    {EM_ID}
    {NAME}
    {PHONE}

    This question was posted a while ago, and was one of the
    search results that came up when I was looking for my own answer. I
    had a nearly identical question and answered it here:
    Disabling
    default linked region and detailregiondisply until click
    Hopefully it will help others too!

  • Php page won't display the first record

    I have the following code, but it always skip the first row of the records pull from an Oracle table:
    include "utility_functions.php";
    // Form the query and execute it
    $sql = "select * from dept where cid=".$_GET['q'];
    $result_array = execute_sql_in_oracle ($sql);
    $result = $result_array["flag"];
    $cursor = $result_array["cursor"];
    if ($result == false){
      display_oracle_error_message($cursor);
      die("Client Query Failed.");
    // Display the query results
    echo "<ul class=\"nav\">";
    $values = oci_fetch_array ($cursor);
    //echo $values[0];
    // Fetch the result from the cursor one by one
    while ($values = oci_fetch_array($cursor)){
      $did = $values[0];
      $dname = $values[1];
      echo("<li><a href=\"showdetail.php?did=$did\">$dname</a></li> ");
    oci_free_statement($cursor);
    echo "</ul>";
    for example, I have the following in dept table:
    did    dname
    1     Business
    2     Education
    3     Math
    4     English
    It will only list: education, math, and english.  Any clues?

    What does execute_sql_in_oracle() do?
    Try following example code, such as from:
            http://www.php.net/manual/en/oci8.examples.php
            http://www.php.net/manual/en/function.oci-fetch-array.php
            http://www.php.net/manual/en/function.oci-bind-by-name.php
    It's extremely insecure (and slow) to do a query made up with string concatenation like:
      $sql = "select * from dept where cid=".$_GET['q'];
    You probably need to first sanitize $_GET to remove anything malicious.  Then you must use a bind variable on the sanitized result.

  • HT3669 Latest Mac OS Update Driver for Canon 9500 Pro causes text lines all to be printed over the first letter of the line?

    Anyone know how I can 'fix' the Mac OS printer driver for the Canon 9500 Pro - all my text lines end up with the whole line being printed over the first character of the line of text when printing PDFs. It has ruined a lot of work.

    I'd try this:
    Delete the current printer (reset the print system) Mac OS X: How to reset the printing system
    Delete all other Canon software and utilities from your computer.
    Do a factory reset on your printer
    Use Software Update to download the driver from Apple.
    Don't reinstall any other Canon Utilities.
    Make sure you don't have something mechanical stopping the paper from advancing.
    If the problem is really the driver, then you could look in Gutenprint for a different driver. Gutenprint for Mac OS X

  • How do I blank my BI Pub report parameter from returning the first record when output to HTML?

    Hi all.
    I have a report that has several parameters A, B, C D.
    I include these at the head of the rtf report.
    I run the report WITHOUT entering anything for parameters A & B.
    When the report generates (returning all the expected correct records), it enters into parameter fields A & B at the top of the report the first records’ A & B fields when they should be blank.
    IS there something I need to do in the rtf form field Help text along with the field name?
    ThanksForLoooking..
    Malc

    within the rtf of the report, within the form-field-help-text, this should work..
    <?xdofx:decode(<parameter name>,'','',<parameter name>)?>
    if the parameter is left blank, then don't put anything in the rtf field, otherwise put in anything that is selected in the parameter.
    or this..
    <?xdofx:if <parameter name>='' then 'All Params Included' else <parameter name> end if?>
    ..yet, when the parameter is left blank, the parameter field in the report generated is populated with whatever is in the first line of the parameter in the report.
    I also can't find anything in the old rdf that is causing this either.  Help!

  • Oracle Forms returns the first record in the database when performing query

    Once in a while when we query for a record on a form, say by first name Tom, then it returns the first record in the database. Other times it return the Tom's record. It only happens once in a while and if you close the form and reopen it and requery for Tom, then it brings Tom's record.
    Does anyone know the issue what could be happening. It just happens every now and then that it's hard to reproduce.
    ORacle Forms 10GR2
    ORacle Application Server 10.1.3
    thanks

    then it returns the first record in the databaseI'm not sure if i understand you correctly. Do you mean forms ignores the searc-condition you entered? I would check SYSTEM.LAST_QUERY at the moment this happens to check if the condition gets somehow lost.

  • How to take a value of the first record/occurrence and the last record?

    Hi experts
    Can anyone help me to tell me:
    How to make IP can take a value of the first record/occurrence and the last record in CSV file?
    I need to take the first and last to put StarTime of first record y StopTime of last record in the target file
    This is my Original CSV File
    20110820,220DNE0220,140.13 ,0.000 ,E01,0
    20110820,240FGC4280,103.80 ,0.000 ,E01,0
    20110821,220DNE0220,142.58 ,0.000 ,E01,0
    20110821,240FGC4280,88.70 ,0.000 ,E01,0
    20110822,220DNE0220,151.92 ,0.000 ,E01,0
    20110822,240FGC4280,91.47 ,0.000 ,E01,0
    Where:
    The firts field is date.
    I require it so my Target File
    20110820,20110822,140.13 ,0.000 ,E01,0
    20110820,20110822,103.80 ,0.000 ,E01,0
    20110820,20110822,142.58 ,0.000 ,E01,0
    20110820,20110822,88.70 ,0.000 ,E01,0
    20110820,20110822,151.92 ,0.000 ,E01,0
    20110820,20110822,91.47 ,0.000 ,E01,0
    Thaks..

    Hi lizcam,
    A. Use FCC at sender side, it will convert CSV to XML like this
    Input XML
    <documentName>
    <recordset>
    <record>
      <Time>20110820</Time>
      <ID>220DNE0220</ID>
      <Quan>140.13</Quan>
      <Volume>0.000</Volume>
      <Auc>E01</Auc>
      <No>0</No>
    </record>
    </recordset>
    </documentName>
    Create a target DT like this
    Output XML
    <recordset>
    <record>
      <StartTime>20110820</StartTime>
      <EndTime>20110822</EndTime>
      <Quan>140.13</Quan>
      <Volume>0.000</Volume>
      <Auc>E01</Auc>
      <No>0</No>
    </record>
    </recordset>
    In MM,
    1.Time -> CopyValue[0] -> StartTime
    2.Time -> below UDF -> EndTime
    3.Quan -> Quan
    4.Volume -> Volume
    5.Auc -> Auc
    6.No -> No
    UDF u2013 Execution type u2013 All values of Queue
    public void getLastTimeValue(String[] inputEndTime, ResultList result, Container container) throws StreamTransformationException{
    result.addValue(inputEndTime[inputEndTime.length-1]);
    B. At receiver use again FCC to convert XML to CSV.
    FYI. If you want to optimize more, you can use
    1.globalContainer concept OR
    2.u201CAttributes and Methodsu201D, declare are String. Store the EndTime using one UDF and write another UDF to retrieve it.
    Regards,
    Raghu_Vamsee

  • Opening a form and displaying the first record

    Any ideas on what the easiest solution would be to show the first record on a form when the form is opened? I've tried some of the ideas discussed in the FAQ section, but without success!!
    Thanks........GD

    Greg,
    Sorry, but there is no other solutions other than those described in the FAQ. I know that it is not very "user-friendly", but should work.
    Also if you search the forum's archive there were some concrete examples posted.
    Thanks,
    Dmitry

  • DB Adapter: Polling For New Records returns the First record multiple Times

    I Polling for New or Chnaged Records against DB2 on iSeries. The DB Adapter returns the first record from the Table multiple Times. If the Table has 5 records it displays the first record 5 times. I am using BPEL 10.1.3.1 Can anyone help me with this.

    Hi there,
    please check out the DBAdapter trouble-shooting guide:
    http://download-east.oracle.com/docs/cd/B31017_01/integrate.1013/b28994/app_trblshoot.htm#CIHFEHFA
    I am copying an entry from there into here:
    A.1.21 Some Queried Rows Appear Twice or Not at All in the Query Result
    Problem
    When you execute a query, you may get the correct number of rows, but some rows appear multiple times and others do not appear at all.
    This behavior is typically because the primary key is configured incorrectly. If the database adapter reads two different rows that it thinks are the same (for example, the same primary key), then it writes both rows into the same instance and the first row's values are overwritten by the second row's values.
    Solution
    Open Application Sources > TopLink > TopLink Mappings. In the Structure window, double-click PHONES. On the first page, you should see Primary Keys. Make sure that the correct columns are selected to make a unique constraint.
    Save and then edit the database partner link.
    Click Next to the end, and then click Finish and Close.
    Open your toplink_mappings.xml file. For the PHONES descriptor, you should see something like this:
    <primary-key-fields>
    <field>PHONES.ID1</field>
    <field>PHONES.ID2</field>
    </primary-key-fields>
    Thanks
    Steve

Maybe you are looking for

  • Downloading .3gp video to 6680

    When I download .3gp video clips they are saved to Notes as text, instead of to Gallery as a video file. No problem with .mp4 files. Is this a phone problem or WAP site problem?Message Edited by tomtmc on 30-Nov-2005 03:39 PM

  • 10.5.1 is out

    The 10.5.1 Update is recommended for all users running Mac OS X Leopard and includes general operating system fixes that enhance the stability, compatibility and security of your Mac. For detailed information on this update, please visit this website

  • Setup Assistant fails during file transfer and loops back to the beginnig

    I have a PPC G5 running 10.4.11 and just bought an Intel-based MacBook Pro. (I haven't gotten it to fully start up yet, so I'm not sure about the OS.) I've tried to use the Setup Assistant to migrate my files and applications from my desktop to the l

  • Search Engine Maybe APPLE?

    These little known facts about Google can hurt Apple i think. 1.Google is one of the most powerful companies a multimillion dollar empire to say the least could one day supreme leaders. 2. Googles homepage loads the fastest out of any search engine,I

  • Photoshop CS4 impressions: many problems

    I have been using CS4 for two days. It is slower than CS3, the interface is horrible and help does not work at all. I have posted elsewhere on the major bug that cursor outlines either vanish, go to a partial arc or freeze. This is really not good en