Membership is FREE, giving all registered users unlimited access to every Acorn Domains feature, resource, and tool! Optional membership upgrades unlock exclusive benefits like profile signatures with links, banner placements, appearances in the weekly newsletter, and much more - customized to your membership level!

LateRooms CSV file - massive!

Status
Not open for further replies.
Joined
May 18, 2006
Posts
5,943
Reaction score
103
Just starting with Late Rooms - I have their England hotels .csv file (around 40mb) which I want to import into MySQL and then manipulate etc. However I just need certain areas of it, not the entire file - e.g. hotels in Birmingham.

Can anyone advise how I can extract just the lines (e.g. for Birmingham) I need from the file and save to make a new file for the region I'd like which is much smaller and easier to use?

I wonder why it's not possible to download an area specific or customised CSV file from them - all or nothing?!!

Thanks everyone. :)
 
You could do it in PHP.

Code:
if ($city == 'Birmingham') {
mysql code to enter into db }
else
{ echo 'Was not a brummy, so not added to the db'; }
 
Last edited:
Thanks all! :)

My Excel skills are basic, lol. I never liked the prog! ;)

Managed to use the sort command to make it alphabetical in the city portion, then removed the not required rows. Sorted and imported to MySQL. :D
 
Ok silly question time! DOH, lol!

Does anyone know if a manual link with my affiliate ID needs to be added to the booking links or is my affiliate link already included within the CSV file if visitors click through? :)

Thanks. :D

PS: Aha, just noticed in the Hotel URL link in the CSV file, e.g:

http://www.laterooms.com/en/p[[PARTNERID]]/hotel-reservations/75864_courtneys-of-gynn-square.aspx

- There's a [[PARTNERID]] section, which I presume you need to add an affiliate ID? Does this need manually altering/editing in?
 
Last edited:
In PHP you can do the following

Code:
$afflink = str_replace("YOUR PARTNER ID","[[PARTNERID]]",$linkvariablefromdb);
echo $afflink;

This will do it on the fly :)
 
Im Having issues importing my edited csv to mysql, I think it might be the fact i only have excel 2003 as when i go to save the file when I have got rid of all the hotels and citys I dont need it says some of the features will be lost if i save as a csv file, i ignored it and continue but when im importing it fails saying there is a eroor in my sql query
 
I'm using an import script now, after creating the MySQL DB, I empty the table, upload the CSV file, works nice and updates all hotels, etc, etc. :)

It's a steep learning curve though isn't it?! :cool:

PS: I have 2002 Excel, works ok here.
 
Yes, it says features might be lost etc, but it hasn't affected things.

I'm using 'old style' CSV with commas, try that. Create the database first for old style first then upload CSV file. :)
 
Laterooms CSV/XML expert on hand :)

p.s. watch out for character encoding issues when handling the CSV feed
 
p.s. watch out for character encoding issues when handling the CSV feed

Yeah, I've noticed some issues with certain characters. :D

For instance, the £ sign sometimes will be displayed as £7.00 etc.
 
Status
Not open for further replies.

The Rule #1

Do not insult any other member. Be polite and do business. Thank you!

Members online

Premium Members

New Threads

Our Mods' Businesses

*the exceptional businesses of our esteemed moderators
General chit-chat
Help Users
  • No one is chatting at the moment.
      There are no messages in the current room.
      Top Bottom