[PHP-DB] MSSQL VIRTUAL TABLES
Hi, I am trying to do the following query in a MSSQL 2000 database: SELECT Order_Details.Qref, Order_Header.AgentRef FROM Order_Details, Order_Header WHERE Order_Details.Qref = Order_Header.Qref AND Order_Header.AgentRef = 48976 I get the following error: Syntax error converting the varchar value 'I7502203' to a column of data type int. Now this value 'I7502203' is in the Order_Header table in the AgentRef column (which is a varchar column). Obviously when the query is run the results will be put in a virtual table but why is it creating the virtual field of Order_Header.AgentRef as an int when in the original table it is a varchar? Can this be pre-set in the query? Any ideas would be handy Mark Loud CONFIDENTIALITY NOTICE The information contained in this e-mail is intended only for the confidential use of the above named recipient. If you are not the intended recipient or person responsible for delivering it to the intended recipient, you have received this communication in error and must not distribute or copy it. Please accept the sender's apologies, notify the sender immediately by return e-mail and delete this communication. Thank you. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Sessions and their function
Hi, I know this my sound stupid but here it goes.. Can sessions be used to pass variables from one page to the next to create persistent data? I have this working to a certain extent but can only pass a variable to my second page, but not from my second page onto the third. Also in my second page I cannot change the value of this variable i.e. bob = 100 on page 1, in page 2 I can display bob equalling 100 but then I want to a) alter the value of bob to 50 and b) send bob and its new value to third page. Can this be done by using sessions? Also how do you pass the session id of one page onto the next? do you pass it on the end of the page reference e.g. echo FORM METHOD=GET ACTION='msltest3.php'.SID.; Any help would be grateful even if it was to tell me that I have got the wrong idea about sessions altogehter. Thanks Mark CONFIDENTIALITY NOTICE The information contained in this e-mail is intended only for the confidential use of the above named recipient. If you are not the intended recipient or person responsible for delivering it to the intended recipient, you have received this communication in error and must not distribute or copy it. Please accept the sender's apologies, notify the sender immediately by return e-mail and delete this communication. Thank you. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php