Menu

#157 SET DEFAULT missing quote detection

open
nobody
Tables (25)
5
2008-01-31
2008-01-22
romulous75
No

I am not sure if this is a bug, or weather it's just left open so it's more customisable :

If the user does not place quotes around a DEFAULT value in the text box, the query fails. I am sure this was not a problem before. (latest csv as of 05:30 GMT+0).

What's produced ?

ALTER TABLE "billing"."item_codes" ALTER COLUMN "tax_code" SET DEFAULT GST

Should come out as

ALTER TABLE "billing"."item_codes" ALTER COLUMN "tax_code" SET DEFAULT 'GST'

Discussion

  • J.Guillaume (ioguix) de Rorthais

    • labels: 383356 --> Tables
    • milestone: 788776 -->
     
  • J.Guillaume (ioguix) de Rorthais

    Logged In: YES
    user_id=1489394
    Originator: NO

    Hi,

    It's not a bug. This field should accept function, quoted value AND unquoted value (think numeric types).

    Well, numeric values could be quoted anyway, the engine will cast, but what about function ? what if your default value looks like a function call ? It's pretty hard to parse.

    However, we probably can handle that the same way we are getting values in the insert pages: with a Format column which let you choose between "Value" or "Expression"...

    Presently, I move this track to the feature requests for further discussions.

    Thanks.

     

Log in to post a comment.