CodePudding user response:
Can the background SQL directly to you, or the front desk with computed columnsCodePudding user response:
Compute the column ofJanuary 1st of each year (date) (month) (year), take no. 1 month day each month, take the rest of days
Assuming that the field is work_date, you can define a computed columns, expression is
If (string (work_date, 'MM - DD)=' 01-01, string (work_date, '- DD YYYY - MM), the if (string (work_date,' DD ')='01 ", string (work_date,' MM - DD), string (work_date, 'DD')))
Have a try
CodePudding user response:
Many methods:1, don't know what you use database, general database support the view that the way you can use the view into data format you want, can be read directly program,
2, read directly from the table, generally use SQL statements to realize the transformation,
3, the advantages of PB is a data object, but through the moderator said, computed columns,
See you like that kind of,
So I tell you, if the database supports transformation, efficiency is the highest, after all, data conversion,
Transformation on the PB end, must have a minimum efficiency, and lower, is line processing,
If you have a little amount of data, it doesn't matter what kind of way,