Dear Wiki user, You have subscribed to a wiki page or wiki category on "Jakarta-velocity Wiki" for change notification.
The following page has been changed by Stephen Popp: http://wiki.apache.org/jakarta-velocity/VelocityCommaIfNeeded ------------------------------------------------------------------------------ - How can I easily create a comma seperated list if items? + How can I easily create a comma separated list if items? I first ran into this problem while using Velocity to create SQL statements. - The comma seperated list of Table Columns can not have a trailing comma. + The comma separated list of Table Columns can not have a trailing comma. To VM_global_library.vm add the '''commaIfNeeded''' macro: {{{ @@ -17, +17 @@ #end }}} - Use the '''commaIfNeeded''' Macro to create a comma seperated list: + Use the '''commaIfNeeded''' Macro to create a comma separated list: {{{ #foreach ($column in ${Table.ColumnList}) p_${column.Name} IN "${Table.Name}"."${column.Name}"%Type#commaIfNeeded( $velocityCount $Table.ColumnList ) --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]