ainoy31 Posted October 18, 2007 Share Posted October 18, 2007 Hello- I receive the following message: Warning: pg_query() [function.pg-query]: Query failed: ERROR: missing FROM-clause entry for table "rate" My query is: $sq = "SELECT rate.dest_zip FROM rate, bols, rate_carriers INNER JOIN bols ON bols.rid = rate.rid INNER JOIN rate ON rate.rid = rate_carriers.rid WHERE b.pro_num = '$pn'"; $result = pg_query($sq) or die("Error: Could not find destination zip"); I have looked over this many times and do not know why I am getting this. Much appreciation... Quote Link to comment https://forums.phpfreaks.com/topic/73870-pg_query-issue/ Share on other sites More sharing options...
btherl Posted October 19, 2007 Share Posted October 19, 2007 That's quite an odd query. Did you mean this: $sq = "SELECT rate.dest_zip FROM rate_carriers INNER JOIN bols ON bols.rid = rate.rid INNER JOIN rate ON rate.rid = rate_carriers.rid WHERE b.pro_num = '$pn'"; $result = pg_query($sq) or die("Error: Could not find destination zip"); Quote Link to comment https://forums.phpfreaks.com/topic/73870-pg_query-issue/#findComment-372829 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.