mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-03 08:41:39 +09:00
Support SQL expressions in the "default" attribute of XML query
This commit is contained in:
parent
ad293fa4d0
commit
978aecd7a8
1 changed files with 6 additions and 0 deletions
|
|
@ -383,6 +383,12 @@ class VariableBase
|
|||
}
|
||||
}
|
||||
|
||||
// If the default value is any other kind of SQL expression, return it as is.
|
||||
if (isset($column) && preg_match('/^[A-Z_]+\([^)]+\)/', $this->default))
|
||||
{
|
||||
return [true, $this->default];
|
||||
}
|
||||
|
||||
// Otherwise, just return the literal value.
|
||||
return [false, $this->default];
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue