Re: Help with php to MySql...



Marcin's right, 'a query like that is just begging to be automated'
but, in any event, writing the query something like this would make
those kind of mistakes much easier to spot;

$query = "INSERT INTO table
(
value1, //you can even add comments
value2,
value3
)
VALUES
(
'value1',
'value2',
'value3'
);";

mysql_query($query) etc

.



Relevant Pages

  • Re: Help with php to MySql...
    ... echo "POST"; ... Then add an "or die" statement to the end of your query - something ...
    (comp.lang.php)
  • Re: XPath question
    ... You can abstract the XML structure a little more by creating a structure ... You can then query for the node you desire with a similar XPath query: ... This XPath query can be plugged into the SelectSingleNode method because it ... > What syntax can I use to return the node containing Value3? ...
    (microsoft.public.sqlserver.xml)
  • Summing Fields by Given Period
    ... I need a query that can sum up the values of Value1, ... Value2, Value3 for a particular Object_ID, for a given ...
    (microsoft.public.access.queries)
  • Re: Replace Null
    ... the ISNULL function will replace any instance of a NULL in ... column "Value3" with "-". ... > How can i replace Null with a blank field in the select query? ...
    (microsoft.public.sqlserver.programming)
  • Re: random selection
    ... into consideration when writing the querry. ... query requirement. ... >I'm also surprised that you're joining on posteddate... ... I have written the following script to select ...
    (microsoft.public.sqlserver.server)