Re: syntax help~~~
| From: | Coconut Ming | Date: | Sun, 05 Aug 2001 21:22:20 +0000 |
| Subject: | Re: syntax help~~~ | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-61354@lists.php.net to get a copy of this message | ||
Hi..
It is not workable too... thanks.....
"Andreas D. Landmark" wrote:
> At 05.08.2001 12:49, Coconut Ming wrote:
> >Hi
> > I am having the problem in the coding below
> >
> ><?
> >
> >mysql_connect('localhost','123','123') or die ("Unable
> >to connect to SQL
> >Server");
> >mysql_select_db('Helpwatch') or die ("Unable to select database");
> >
> >$temp = $username."watch";
> >$watchlist_query = mysql_query("Create Table "$temp"(WId int Not Null
> >auto_increment, QId int not null, Primary Key (WId));");
> >?>
> >
> >but I can't do that.. Because of the syntax error, the coding I have
> >underline is where the parser told me that is an error there.
> >I have playing around with it for 2 hours and more... but I cant solve
> >it.. Anyway help is greatly appreciated.
> >Thanks in advance.
>
> Your underlining doesn't show verywell in plain text, but anyhow, your
> line $watchlist_query ... is missing to .'s...
>
> Create Table "$temp", should be Create Table " . $temp . ", that way
> you'll
> concatenate the string in the way you want them to (and the code should work).
>
> --
> Andreas D Landmark / noXtension
> Real Time, adj.:
> Here and now, as opposed to fake time, which only occurs there
> and then.