Jump to content

AzeS

Members
  • Posts

    88
  • Joined

  • Last visited

Profile Information

  • Gender
    Not Telling

Recent Profile Visitors

1,850 profile views

AzeS's Achievements

Advanced Member

Advanced Member (4/5)

0

Reputation

7

Community Answers

  1. As soon as i have generated proper income ill donate a little SOLVED BY BARAND BITCHES!
  2. Corrected and checked. I want to smash my head in to the keyboard untill it all stops ;-; Error: array(3) { ["lead"]=> string(15) "support@web.web" ["comment"]=> string(5) "send:" ["text"]=> string(4) "text" } PDOException: SQLSTATE[HY093]: Invalid parameter number in /var/www/html/**/**.php: 1732 Stack trace: #0 /var/www/html/**/**.php(1732): PDOStatement->execute(Array) #1 /var/www/html/**/**/**/**.php(23): **->crm(0, 1, Array) #2 /var/www/html/**/**.php(1): require_once('/var/www/html/C...') #3 {main} Fehler bei migration in die Datenbank, bitte informieren Sie einen Administrator. 05-20-2019 09:31:07 Error throwing, Adjusted Code: try { $sql = $this->Db->prepare("UPDATE ** SET data = CASE WHEN data IS NULL THEN :f ELSE (CONCAT(data,:f)) END WHERE lead=:e"); $preset = array(':e' => $data["lead"], ':f' => $data["comment"] . $data["text"]); $sql->execute(array(':e' => $data["lead"], ':f' => $data["comment"] . $data["text"])); } catch (PDOException $e) { $this->report("crm_err: " . $e); return $e . " Fehler bei migration in die Datenbank, bitte informieren Sie einen Administrator. " . $current_date_frep . var_dump($data); } Initiating Code: echo *->crm(0,1,array('lead' => "support@web.web", 'comment' => "send:",'text' => "text")) . "<br>"; echo *->crm(0,1,array('lead' => "support@web.web", 'comment' => "recv:",'text' => "text")) . "<br>"; The strange thing is, that there isnt even a number in transfer to the PDO execution, so where does it get the parameter?!
  3. Exception: PDOException: SQLSTATE[HY093]: Invalid parameter number in *.php:1732 Stack trace: #0 *.php(1732): PDOStatement->execute(Array) #1 crm_for.php(23): *->crm(0, 1, Array) #2 *.php(1): require_once('/var/www/html/C...') #3 {main} Hello fellow people, i need a rant. An error is appearing in my new CRM system. there are No Numeric values in transfer on the pdo statement but the compiler isn't on my side. the following SQL Statement is for concating an intitated Null value in the CRM table i have a workaround but its inefficiant and dataconsuming. I would like to estimate if there is an null value and overrite it with general text for later sentiment analysis. Error throwing Code: try { $sql = $this->Db->prepare("UPDATE *** SET data =(CASE WHEN (NULL) THEN :f ELSE (CONCAT(data,:f)) END) WHERE lead=:e"); $preset = array(':e' => $data["lead"], ':f' => $data["comment"] . $data["text"]); $sql->execute(array(':e' => $data["lead"], ':f' => $data["comment"] . $data["text"])); } catch (PDOException $e) { $this->report("crm_err: " . $e); return $e . " Fehler bei migration in die Datenbank, bitte informieren Sie einen Administrator." . $current_date_frep; } return "Ihr Text wurde erfolgreich in die Datenbank migriert, weiter so!" . var_dump($preset); break; Initiating Code: echo *->crm(0,1,array('lead' => "account", 'comment' => "send:",'text' => "text")) . "<br>"; echo *->crm(0,1,array('lead' => "account", 'comment' => "recv:",'text' => "text")) . "<br>";
  4. What am i doing wrong in the code ? i've read that i might do something wrong with the echo phrase, but i don't get what exacatly it is. <input type="Text" name="sen_add_dat_bil_fir" maxlength="200" required="True" placeholder="Firstname" value="<?php if (isset($_SESSION['user'])) { echo $curd->word($userRow['fname_bil'], 'UTF-8'); } else { if (!empty($_SESSION['auto_fill']['bil_adr'])) { echo $crud->word($_SESSION['auto_fill']['bil_adr']['cos_fis'], 'UTF-8'); } } ?>">
  5. I going with VARCHAR for now... i let this thread open for thruther suggestions
  6. changed that, im sorry, i cant decide between stack and stock But in genaral it works, but not with the negative value
  7. Roughly speaking; Locate the emails of the recieving people and remove them, or simplie dont do email lists like : $email_to = "jhewitt@amleo.com,some@other.com,yet@another.net"; in the first place, im no expert in this but, if i would do that, i would create a simple mail funktion and an for each loop that reads an array with all the recievers and then sends them by triggering the function you might use http://php.net/manual/de/class.thread.php if you have a massive ammount of emails.
  8. private function update_item($ID,$QUA) { $sql = $this->db->prepare("SELECT stack,time FROM items WHERE ID=:e"); $sql->execute(array(':e' => $ID)); $res = $sql->fetch(PDO::FETCH_ASSOC); echo $res['stack'] - $QUA; if (count($res)) { if ($res['stack'] == 0 || $res['stack'] > 0 || $res['stack'] - $QUA > 0 || $res['stack'] - $QUA == 0 ) { echo "HERE1"; $sql = $this->db->prepare("UPDATE items SET stack=:f, dod=:g, position=:h WHERE ID=:e"); $pa = $res['time'] + 4; $pb = $res['time'] + 8; $dod = "This item is not there Maybe in. " . $pa . "-" . $pb . " OT's it's there."; $sql->execute(array(':f' => $res['stack'] - $QUA, ':g' => $dod, ':h' => 0, ':e' => $ID)); return 1; } else { echo "HERE1"; $sql = $this->db->prepare("UPDATE items SET stack=:f WHERE ID=:e"); $sql->execute(array(':f' => $res['stack'] - $QUA, ':e' => $ID)); return 1; } } return 0; } Changed that, ill set up an try catch with report as soon as the project is done... Struct: CREATE TABLE `items` ( `ID` int(255) NOT NULL AUTO_INCREMENT, `ESTABLISHED` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, `current_owner` int(11) NOT NULL, `revid` int(255) NOT NULL, `itepiclrg` varchar(255) DEFAULT NULL, `itepicsml` varchar(255) DEFAULT NULL, `itename` varchar(90) NOT NULL, `itevalue0` float NOT NULL, `itevalue1` float NOT NULL, `detailsstr` text NOT NULL, `detailssub` text NOT NULL, `weight` int(5) NOT NULL, `original` varchar(3) NOT NULL, `locationid` int(11) NOT NULL, `dod` text, `position` int(1) DEFAULT NULL, `reward` int(6) DEFAULT NULL, `size` varchar(14) DEFAULT NULL, `stack` int(5) DEFAULT NULL, `time` int(2) DEFAULT NULL, `CANCELED` int(1) NOT NULL DEFAULT '0', `CNCELED_SINCE` datetime DEFAULT NULL, PRIMARY KEY (`PID`) ) ENGINE=InnoDB AUTO_INCREMENT=29 DEFAULT CHARSET=latin1
  9. like a differrent sender each time or what ?
  10. \--_The Annoying one_--/

  11. `stock` int(5) DEFAULT NULL ENGINE=InnoDB AUTO_INCREMENT=29 DEFAULT CHARSET=latin1 Better ?
  12. dbtest.items.stock015129171.50004.5000ENUM('0','15')
  13. Dear Community, I can not make a positive value through subtraction into a negative one. I have already checked the if query itself and the invoice in the execution, I hope you can help me, greetings AzeS. private function update_item($ID,$QUA) { $sql = $this->db->prepare("SELECT stack,time FROM items WHERE ID=:e"); $sql->execute(array(':e' => $ID)); $res = $sql->fetch(PDO::FETCH_ASSOC); echo $res['stack'] - $QUA; if (count($res)) { if ($res['stack'] == 0 || $res['stack'] > 0 || $res['stack'] - $QUA > 0 || $res['stack'] - $QUA == 0 ) { echo "HERE1"; $sql = $this->db->prepare("UPDATE items SET stack=:f AND dod=:g AND position=:h WHERE ID=:e"); $pa = $res['time'] + 4; $pb = $res['time'] + 8; $dod = "This item is not there Maybe in. " . $pa . "-" . $pb . " OT's it's there."; $sql->execute(array(':f' => $res['stack'] - $QUA, ':g' => $dod, ':h' => 0, ':e' => $ID)); return 1; } else { echo "HERE1"; $sql = $this->db->prepare("UPDATE items SET stack=:f WHERE ID=:e"); $sql->execute(array(':f' => $res['stack'] - $QUA, ':e' => $ID)); return 1; } } return 0; }
  14. http://stackoverflow.com/questions/17242346/php-session-lost-after-redirect
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.