Re: TableName with space
| From: | Richard Lynch | Date: | Tue, 05 Jun 2007 22:07:09 +0000 |
| Subject: | Re: TableName with space | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-256130@lists.php.net to get a copy of this message | ||
On Mon, June 4, 2007 11:51 pm, karthi keyan wrote:
> How can I create a table with spaces "Order details" in MSSQL using
> PHP?
> I am able to create manually the table name with space by providing
> the name in Double Quotes. Is there a way out to do this using PHP?
If it worked manually with double quotes, then it probably would work
in PHP with double quotes...
$query = "create table \"Dumb Idea\" (dumb_id int)";
PHP pretty much just passes the query to the MSSQL program, and it's
up to MSSQL to accept/reject it.
If that doesn't work, try ` in place of \"
I think it's daft to create table names with spaces, but there ya go.
--
Some people have a "gift" link here.
Know what I want?
I want you to buy a CD from some indie artist.
http://cdbaby.com/browse/from/lynch
Yeah, I get a buck. So?