return $data = DB::select("SELECT orders.*,SUM(products.`product_price`*order_product.`qty`) AS 'total' ,users.`name`,orders.created_at as 'date'
FROM orders INNER JOIN order_product ON
orders.`id` = order_product.`order_id`
INNER JOIN products ON
products.`id` = order_product.`product_id`
INNER JOIN users ON
users.`id` = orders.`user_id`
GROUP BY orders.`id`
")-paginate(10);
Antwort
Sie einen Syntaxfehler in Ihrem Code haben, ist es >
fehlt, sollte es
->paginate(10);
und nicht
-paginate(10);
Stackoverflow, debuggen Sie Ihren Code seit 2008. – Amarnasan
Es ist wie/r/PHPhelp :-D – mazedlx
Wenn die Antwort lautet: "Es ist ein Tippfehler." Dann ist die beste Antwort, um die Frage als off-topic zu markieren/vote, um die Frage zu schließen: Tippfehler. – mickmackusa
- 1. Call to undefined function simplexml_load_string()
- 2. Call to undefined function exif_imagetype()
- 3. Call to undefined function curl_init()
- 4. Call to undefined function Laravel
- 5. Call to undefined function start()
- 6. Call to undefined function mysqli()
- 7. Call to undefined function get_header()
- 8. Call to undefined function filter_var()
- 9. Call to undefined function array_column()
- 10. Call to undefined function ssh2_connect()
- 11. Call to undefined function iconv_get_encoding()
- 12. CakePHP - Fatal error: Call to undefined function
- 13. Call to undefined function set_flashdata() in codeigniter
- 14. Fatal error: Call to undefined function openssl_random_pseudo_bytes()
- 15. Fatal error: Call to undefined function mysqli_connect
- 16. Fatal error: Call to undefined function ldap_connect()
- 17. FatalErrorException: Call to undefined function link_to_route()
- 18. WooCommerce error: Call to undefined function array_replace_recursive()
- 19. Docker PHP5.6 Call to undefined function bindtextdomain()
- 20. Einrollen richtig (Call to undefined function curl_init())
- 21. Oracle 11g Call to undefined function oci_connect()
- 22. "Call to undefined function finfo_open()" Bluemix
- 23. Call to undefined function mcrypt_decrypt() - CometChat Laravel
- 24. Codeigniter error: Call to undefined function mysql_pconnect()
- 25. Fatal error: Call to undefined function tep_session_name()
- 26. Call to undefined function sqlsrv_connect() - Fehlerbehebung
- 27. Fatal error: Call to undefined function import_request_variables()
- 28. Fatal error: Call to undefined function MySQLi_Result()
- 29. Fatal error: Call to undefined function random_bytes()
- 30. Libsodium "Call to undefined function sodium_randombytes_buf"
Bitte erarbeiten und formatieren Sie Ihre Frage gelesen . https://StackOverflow.com/Help/how-to-ask –
In der Zukunft, bitte eigentlich * stellen Sie eine Frage * anstatt nur Ihren Code und eine Fehlermeldung. – rickdenhaan
Eigentlich ziehe ich es vor, direkt zur (offensichtlichen) Fehlermeldung zu gehen: "Hallo mein Herr, guten Morgen, mein Name ist J. Ahmed, PHP-Entwickler, und ich entwickle ein Online-Tool für Kuhmanagement und mitten in meiner Arbeit Ich habe die folgende Fehlermeldung auf meinem 17 "Bildschirm bekommen: *** Können Sie herausfinden, warum ich einen solchen Fehler bekommen habe, und mir geholfen habe, ihn zu reparieren?" " – Amarnasan