ICS iCalendar and large number of events - icalendar

I have an ICS generator gzip the results but still the files get VERY large. The ICS format clearly isn't made to contain large number of events. I looked at the spec and there doesn't seem to be a way to create "chunks". For example, have an ICS per month of the year with an "index" file in front or a way to "link" to the previous month which would allow me to do something like:
https://mywebsite.com/calendar => 307 => https://mywebsite.com/calendar/202205.ics
Where https://mywebsite.com/calendar/202205.ics would then link to https://mywebsite.com/calendar/202204.ics, etc.
Are there any of such techniques possible with ICS? That would also make it possible to keep read-only data of past events and the ability to static host all these without the need to every time update it with a new static file.
Is there maybe a different calendar format better suited for this that is still compatible with Google Calendar, Outlook and other popular calendar apps?

Related

When exporting facebook messenger data, is it possible to convert the filename into datetime?

I am not sure if this is even possible. I have used the export feature on FB to download Messages and all of the file names are basically a long string of numbers. I've searched all over the web to see if there is a way to decode the file name from FB Msgr files. I am trying to get the Date and Time of when the file was sent from a file name.
As an example, here is one of the file names: "17571372_428718127480452_853371653_o_428718127480452.jpg"
I've tried an Epoch & Unix Timestamp Conversion Tool on each of the sections of numbers with no luck. I happen to know what time and date this specific file was sent, but not the others that I have. SO I am using it as a baseline. The time and date is Mar 26, 2017 5:17:15pm.
Thanks for any help or advice!

Using a holiday calendar in kdb?

has anyone ever implemented a holiday calendar in kdb?
it's pretty easy to exclude weekends or to create a function to get nextweekday or previous weekday, but what if you want to also take into account public holidays / bank holidays?
What have people done in order to account for this?
A rudimentary way is to create a file with known bank holidays across LDN & NY let's say - but is there a more automated way?
You may want to take a look at holiday.q on Github. Note that NYSE rules change from time to time so you may need to make some adjustments to bring that code up to date.
Most places will have purchased some form of calendar data product (.e.g Copp Clark). From that you'd build a suite of functions for getPrevBizDay etc, and you'd do it for all regions. It will also have future holidays.
Alternatively I'm sure there are some open source holiday data downloads you could scrape from the web and from them you could manually put together a table (perhaps it would be an annual once-off process to update it for the next year).

Convert Timespan data from CSV to KML

Working with GoogleEarth, I am able to import CSV data that contains long, lat, name, etc., but I am unable to get Google Earth Pro to recognize timespan (begin, end) information.
I found an online App called EarthPoint, that allows me to convert a CSV file into KML that includes the timespan data, but that app is limited in its ability to recognize additional fields. Thus, I am unable to apply style templates to the EarthPoint imported data, as there is nothing for Google Earth to latch onto.
So I am looking for either a different app, that imports all three (geo, time, description), from either CSV, or straight from a spreadsheet app like Excel.
And barring the existence of such an app, I would simply like to know if there is a way to specify the headers so that Google Earth will reecognize the time series data for what it is.

Exporting a log from iPhone application

One of the features in my application is a log where a user can add log entries. I want to make it possible to for the user to export this data. However I do not know which format I should use for this. The data looks like this:
A date, distance, duration, maximum four category names. What I want is to make it possible to send it on mail or open it with dropbox using the URL scheme if the user has dropbox.
I have read about CSV format but I don't know if that is a good file format? My main concern is that the user do not have to have a fixed number of categories (could be between 1-4 categories)
Seeing as the columns of data to be exported will be dynamic in total, it will depend on what the user selects - and there's nothing wrong with this.
I think .csv is fine for this purpose as well - but you need to ask yourself... what will the user be doing with the data? You could either offer multiple file export formats or whatever is the best-for-purpose format, depending on what your average user will do with it.
CSV (comma separated values) is simple (and adds very little overhead - the commas), but not terribly flexible. This is good for importing to MSFT Excel, for instance.
You should consider using XML (the same underlying format used for plists) which is a very flexible (future proof should you wish to add additional columns in the future) and well supported format.

Connecting nodes to multiple dates

I have company website, with many offices around the world (around 50 offices).
The company want to create a gift giveaway with the employees in a specific company each specific day.
For example:
Office 1: will do the giveaway the days: 1/1/2010, 7/1/2010, 15/1/2010, etc...
Office 2: the days: 2/1/2010, 9/1/2010, 19/1/2010, etc...
Office 3: ....
Office 50: ...
(the days are setup manually to specific offices, no need of an algorithm here)
I have a node per Office, it's a CCK content type with details of each office (location, phone, email, etc), now I need to assign those days to the offices.
But my problem here is that I don't need to create events (or at least node events) because I don't need to store any data in the event. Just need to say: Office 1? Yes, days 1/1/2010, 7/1/2010, etc...
Nothing else, just to know the dates.
And, if possible, make them available to display in the calendar module.
What is your suggestion?
Withs CCK and date module you can create date fields, but if you have many fields you want to add, this might not be the best solution.
You have two general ways of solving this issue. Either you need store each date. This could be done with date field, not sure if it can handle multiple values, node reference or similar. This is inefective it some ways, but will make it easy to generate calendar view.
You could also write a string with as the date info and let php convert it to dates. This route will make it easier to create and store the data, but will make it a lot harder to get things integrated with calendar.
The fatest / easiest solution would probably be node reference with a date module, combined with a script to create all the nodes need. Instead of making them inside Drupal.
You could also create a custom module that stores this info for you. It would be a more longterm solution and require more work to integrate it with views and date/calendar modules.
There are many ways to go about this, but it really depends on your need, skill and time
Why not use a plain old CCK text field with a good clear description of what it's for and how to format it with something in the help section to back it up?
Use a text area (multiple rows) and apply the default input format that converts lines line breaks. I like to use the mark down filter too.
You could also use multiple single line fields in place of a text area...
This assumes your users are smart enough to enter the correct info of course but that's what the help and description are for. If your users can't be trusted to enter the content in correctly then yes, go for something that forces them to do so.
Ok I've found the solution myself and I want to share it with you:
Created three content types:
Office: with data of the office
Days: with a node per day (365 * year)
and Giveaway: with two node-reference fields, one for Office and another for Day.
(Days must be populated manually using a script that fills the upcoming 2 years or so).
So I can fill only Giveaway content type, and that's enough.
And then only the views are remaining.