Jump to content

jenniferG

Members
  • Posts

    55
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

jenniferG's Achievements

Member

Member (2/5)

0

Reputation

  1. We have built a "create statement" and when we put any line after line 27, when we run it gives me an error at Line 28. we hjave tried to find the statement werror and are stumped. Even if I put a rint $QCRT at line 28, we get an error. Thanks Jennifer <?php $QCR="CREATE TABLE MSDSTEST( INDEXA INTEGER AUTO_INCREMENT, PROD_NAME varchar( 40 ) , LIST_PRICE varchar( 25 ) , SHORT_DESC text, LONG_DESC text, MFGR varchar( 20 ), PRIORITY int( 4 ), HTML varchar( 30 ), THUMBNAIL varchar( 30 ), IMAGE varchar( 30 ), CATGY_1 varchar( 20 ), CATGY_2 varchar( 20 ), CATGY_3 varchar( 20 ), PARTNUM varchar( 20 ), NEWITEM int( 4 ), ACTIVE int( 4 ), DELIVERY varchar( 15 ), DETAIL int( 3 ) , ENROLL int( 10 ), ID int( 11 ), ID_MAJOR int( 4 ), ORDERCODE varchar( 25 ), ARO varchar( 20 ), ENTERED date, PRIMARY KEY(INDEXA))" //any statement here causes a statement error at line 28--// ?>
  2. We are tryng to add a sort [$SORT] clause to these queries and afterwards theydo not work. Syntax problem? ======================================================== $SORT='ORDER BY MFGR,CATGY_1'; $selectall="SELECT * FROM $tablename . $SORT"; $selectcat="SELECT * FROM $tablename WHERE CATGY_1 = '" . $CATGY_1 . "' . $SORT "; $selectmfg="SELECT * FROM $tablename WHERE MFGR = '" . $MFGR . "' . $SORT"; $selectboth="SELECT * FROM $tablename WHERE CATGY_1 = '" . $CATGY_1 . "' AND MFGR = '" . $MFGR ."' .$SORT"; ========================================================= Thanks Jennifer
  3. We are trying to concaenate multiple spaces tpo one space with the following: $instr= 'John Smith'; $xx=str_replace('/\s+/',' ',$instr); print $xx; exit; it removes all spaces and returns $xx as one string. Jennifer
  4. I'm sorry, we are lookoing for help with the syntax to do this/
  5. we have two tables, pimclients and pimcontacts with a common column clientname. clientname is unique in pimclients. we want to set the value of clientindex in pimcontacts equal to the value of indexa in pimclients where the columns clientname matches. Thanks, Jennifer G
  6. This is probably silly, but in the below script, does $FIND contain the count or do I have to do something in addition? The manual covers just mysql command line querys. /* $NOUNITQUERY="SELECT COUNT(*) FROM SISTOCK WHERE CAMERAMODEL='$CAMERAMODEL'"; $FIND= mysql_query($NOUNITQUERY); */ Thanks, Jennifer
  7. we have a table sistock with column cameramodel varchar(30) and try to set default value to blank with the following: ALTER TABLE SISTOCK CHANGE COLUMN CAMERAMODEL CAMERAMODEL ENUM ('INSTOCK', 'BACKORDER','SERVICE','OBSOLETE') DEFAULT ''; and we get an error at the mysql prompt; Thanks, Jennifer
  8. I hpe ypou keep this forium-Its a welcome edition Jennifer
  9. I may have phrased this wrong. I have a column [columnA] defined in a table as enum(...................); what I want to do is query the database and get back an array containing the enumerated values attrributed to that specific column. Jennifer
  10. Is there anyway in PHP 4 to create an array containing the enumerated values of a column?. ie: columna enum('val1','val2','val3'); we want to generate an array where: array[0]='val1' array[1]='val2' array[3]='val3' Thanks, Jennifer
  11. we have two variables to use in a query: $INDEX is an Integer and $MAINDATE=date('YMD'); is the below the correct syntax? $SHOWLINK="$MYURL$MYDIR/showdata2.php?INDEXB='$INDEX'" . "&SI='$MAINDATE'"; Thanks, Jennifer Good
  12. I need to set a var in Javascript that will give me the selected value of a list box from the listbox ID. ie: I have a list box with NAME="camera" and ID="camera" and I need to get the selected value so I can build a querystring for anAJAX query. Thanks, Natalie
  13. we have the below code doing an AJAX call and when the response is made, the redirect call in red below does not redirect the browser. if we replace t with a alert box, that displays fine, so we are gretting to the command. Thanks Jennifer function fetch(){ var ORG = document.getElementById("ORG").value; var SCN = document.getElementById("SCN").value; var PWD = document.getElementById("PWD").value; var PARAMS = "ORG=" + ORG + "&SCN=" + SCN + "&PWD=" + PWD; var myConn = new XHConn(); if (!myConn) { alert("XHConn creation failed."); } var fnWhenDone = function (XMLHTTPRequestObject) { if( XMLHTTPRequestObject.responseText=='INVALID') {document.getElementById("PWD").value = 'INVALID';} else {window.href="http://msdsimaging.com/atmelpim/pim_main.php";} }; myConn.connect("ajaxpwdverify2.php", "POST", PARAMS,fnWhenDone); }
  14. we hava a login page that sends form variables to a php page that sends the response.text back to the original page to a text field with ID='password' so that if the field data is not correct, it says INVALID in the password text field. so far,so good. If the data is correct, the php code executes a header('location: URL') command, but the target page ,is displayed as text in the text box, instead of control being vectored to the target page. Thanks, Jennifer
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.