how to split column name declarations in sql create statement?
I have trimmed create statement only to the column declarations:
`user,id` PRIMARY KEY NOT NULL, [col,1] NOT NULL, "another,col" UNIQUE,
'`and`,''another'',"one"' INTEGER, and_so_on
The caveat is that commas are not only between columns declarations but may be in the column names. (Yes, I know that it is bad habit to place them into column names.)
effect should be like this:
array (
`user,id` PRIMARY KEY NOT NULL,
[col,1] NOT NULL,
"another,col" UNIQUE,
'`and`,开发者_如何学Python''another'',"one"' INTEGER,
and_so_on
)
If you're looking to split names into components, why not use an underscore? user_id
, col_1
, another_col
, and_another_one
.
精彩评论