Find Jobs
Hire Freelancers

316088 add to select query

N/A

完了済み
投稿日: 約15年前

N/A

完了時にお支払い
We have a script that has an issue. The problem is if we created a work order for the same product 4 different times in a year then it's telling us to pull each item 4 times. So basically it's pulling up info for all the work orders for this product...and we need it tied to only the current work order that we are working on. The old code commented out didn't have this problem so i looked at it and i see this: LEFT JOIN work_order wo ON [login to view URL] = '$work_order_id' so that is what i think we are missing in the new code but i'm not a programmer and couldn't figure out where or how to put it. Here is the new code we have: $res_herbs = $db->query("SELECT [login to view URL], [login to view URL], [login to view URL], [login to view URL], [login to view URL], [login to view URL] FROM product p, pulling_herbs ph, lot l WHERE [login to view URL] IN ( SELECT [login to view URL] FROM pulling_herbs ph LEFT JOIN pulling g ON ph.pulling_id = [login to view URL] LEFT JOIN product p ON [login to view URL] = [login to view URL] LEFT JOIN lot l ON [login to view URL] = ph.lot_id WHERE [login to view URL] = '$sku' ) AND [login to view URL] IN ( SELECT [login to view URL] FROM pulling_herbs ph LEFT JOIN pulling g ON ph.pulling_id = [login to view URL] LEFT JOIN product p ON [login to view URL] = [login to view URL] WHERE [login to view URL] = '$sku' ) AND [login to view URL] = [login to view URL] AND [login to view URL] = ph.lot_id"); So to clarify we don't need anything taken away from the code...we just need it to only show the data that is tied to the [login to view URL] that we are currently working on.
プロジェクト ID: 2061887

プロジェクトについて

1個の提案
リモートプロジェクト
アクティブ 12年前

お金を稼ぎたいですか?

Freelancerで入札する利点

予算と期間を設定してください
仕事で報酬を得る
提案をご説明ください
登録して仕事に入札するのは無料です
アワード者:
ユーザーアバター
I can do it easily . Please see PMB. Thanks
$15 USD 1日以内
5.0 (54 レビュー)
4.9
4.9

クライアントについて

UNITED STATESのフラグ
Payson, United States
4.9
95
メンバー登録日:3月 18, 2005

クライアント確認

ありがとうございます!無料クレジットを受け取るリンクをメールしました。
メールを送信中に問題が発生しました。もう一度お試しください。
登録ユーザー 投稿された仕事の合計
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
プレビューを読み込み中
位置情報へのアクセスが許可されました。
あなたのログインセッションの有効期限がきれ、ログアウトされました。もう一度ログインしてください。