Is there a way to override the 'upload date' of a document?

Hi Squirro Team,

I am currently working on a project where I am building a squirro dashboard for a custumer. The custumer asked me if it would be possible to use the origin date as value for ‘sort by date’, instead of using the documents upload date. Is that theoretically possible?

Best regards!

Hello,

Thank you for your question. Yes, it is possible, but this depends if the origin date or created_at date is available in your data or not.

Setting the Date in the Data Loader
While there are a number of possibilities of data types and sources, if an original date field exits within your dataset, it may look like something like the screenshot below. Here we are in the process of adding a data source. The original date is found within the data’s created_at field. This may be named different field for your dataset under “Source Field”, so please have a look.

Please note the date time format, as a different format may cause issues in completing the data run. The strftime format here is %Y-%m-%dT%H:%M:%S.

Setting the Date through Pipelet
If the date is not available in the step above, you would have to determine if the original date can be retrieved somehow from the data, and then resolve if this date be extracted programmatically (for example: using regex to look for date patterns, etc.). If so, a pipelet can be built to determine the desired date and map the date to item["created_at"]. Please have a look at the structure of a Squirro item here.

If required, there is a Squirro Academy course on Pipelets available that can help guide you through the process of building one. Remember that once built and placed within the pipeline, the data must be rerun through the pipeline.

You will likely have more questions as you sort out the specifics to this request. Without knowing the datasource you are using and how it is set up, we can only provide a general view of what can be done. But I hope this information points you in the direction or inspires some ideas. Feel free to reach us with any more questions if you need further help.

Best regards,
Hubert Shon, Solutions Engineer

1 Like

Hello @TalitaAnthonio :wave:

It is theoretically feasible to arrange documents in your squirro dashboard based to their source date not according to when they were uploaded. You must make sure that the origin date field in your data source is present and correctly indexed in order to achieve this. You may then configure your dashboard so that this origin date field is used for sorting.

Hi,

I think Yes, it is feasible to arrange documents in your Squirro dashboard by their source date instead of the upload date. Ensure the origin date field in your data source is present and correctly indexed then configure your dashboard to use this origin date field for sorting.

Thanks