Orbixx Posted July 8, 2008 Share Posted July 8, 2008 Hi, Just a bit confused as to Harold's tep_db functions... How would one select a single value from a database table? I currently have something like: $manufacturer_name_query = tep_db_query("select manufacturers_name from manufacturers where manufacturers_id = '" . $HTTP_GET_VARS['manufacturers_id'] . "'"); $manu_name = tep_db_fetch_array($manufacturer_name_query); $value = $manu_name['0']; But it doesn't seem to be working. I'm quite confused. Could someone provide me with the correct code? Thanks. Link to comment Share on other sites More sharing options...
spooks Posted July 8, 2008 Share Posted July 8, 2008 There are books available on sql, if you follow rules they give it would work. Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
Orbixx Posted July 8, 2008 Author Share Posted July 8, 2008 No books on osCommerce's internal SQL functions. I understand SQL relatively well to perform a query, I would just rather understand the tep_db functions to keep everything in-line with the code of OSC than spiral off into my own style. I'd prefer it if you could help me, instead of informing me of the amazingly obvious. Link to comment Share on other sites More sharing options...
spooks Posted July 8, 2008 Share Posted July 8, 2008 No books on osCommerce's internal SQL functions. I understand SQL relatively well to perform a query, I would just rather understand the tep_db functions to keep everything in-line with the code of OSC than spiral off into my own style. I'd prefer it if you could help me, instead of informing me of the amazingly obvious. You know sql!! But you cant see your error!!! :blink: Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
Orbixx Posted July 8, 2008 Author Share Posted July 8, 2008 Afford me the kindness of pointing it out. I tend to miss simple things. Link to comment Share on other sites More sharing options...
Orbixx Posted July 8, 2008 Author Share Posted July 8, 2008 Fixed it by myself. Thanks for your help, twat. Link to comment Share on other sites More sharing options...
lindsayanng Posted July 8, 2008 Share Posted July 8, 2008 it would be helpfull to others if you posted the fix though.. for those of us who also could not see the error. A great place for newbies to start Road Map to oscommerce File Structure DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways! HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you Proud Memeber of the CODE BREAKERS CLUB!! Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.