In this Gist will show you how to get parents of a list of child from an Oracle database.
Let's start with the table below:
| Child | Parent |
|---|---|
| 1 | NULL |
| 2 | 1 |
| 3 | 2 |
| 4 | 3 |
| import scrapy | |
| import csv | |
| import re | |
| class PrayerTimesSpider(scrapy.Spider): | |
| name = 'prayer_times' | |
| start_urls = [ | |
| 'https://habous.gov.ma/prieres/horaire_hijri_2.php?ville=58', # Casablanca city | |
| 'https://habous.gov.ma/prieres/horaire_hijri_2.php?ville=142' # Agdz city | |
| ] |
| Add-Type @" | |
| using System; | |
| using System.Runtime.InteropServices; | |
| public class NativeMethods { | |
| [DllImport("user32.dll")] | |
| public static extern void mouse_event(uint dwFlags, uint dx, uint dy, uint dwData, UIntPtr dwExtraInfo); | |
| } | |
| "@ |
| <?php | |
| use EasyCorp\Bundle\EasyAdminBundle\Controller\AbstractCrudController; | |
| class BaseAdminCrudController extends AbstractCrudController | |
| { | |
| public function edit(AdminContext $context) | |
| { | |
| $event = new BeforeCrudActionEvent($context); | |
| $this->container->get('event_dispatcher')->dispatch($event); |
In this Gist will show you how to get parents of a list of child from an Oracle database.
Let's start with the table below:
| Child | Parent |
|---|---|
| 1 | NULL |
| 2 | 1 |
| 3 | 2 |
| 4 | 3 |
| var buttons = $('div[role=dialog]').find('button:contains(Follow)').filter(function() { | |
| return $(this).text().toLowerCase() === 'follow'; | |
| }); | |
| $.each(buttons, function(idx, itm) { | |
| var secondes = Math.floor((Math.random() * 10) + 3); | |
| setTimeout(function() { | |
| $(itm).trigger('click'); | |
| }, duration = secondes * 1000); |
| fgrep -vf /path/to/file1 /path/to/file2 |
| id,username,fullname,emails,fbPage,externalUrl,biography,followedBy,follows,isPrivate,isVerified,isBusinessAccount,businessCategory,businessEmail,businessPhone,businessAddressStreet,businessAddressZipcode,businessAddressCity,businessAddressRegion,businessAddressCountryCode,hashtags | |
| 5734709815,tasteititalian,Taste IT,,,https://m.facebook.com/TasteItitaliantakeaway/,"‼️The first independent Italian Gelateria in Greater Manchester ‼️ | |
| Stonebaked pizza 🍕 artisan gelato 🍦 baked pasta 🍝 tasty arancini.",430,146,0,0,1,Restaurants,[email protected],441616980410,69 BLACKFRIARS ROAD,M3 7DB,City of Salford,,GB,pizzauk | |
| 3667203339,mobipizzeria,🇮🇹Mobile Wood Fired Pizza🇬🇧,,,https://www.facebook.com/mobipizzeria/,"Mobile pop-up wood fired pizza UK-wide. | |
| We cater for weddings, corporate events, private parties, birthdays, festivals, concerts, fetes, and many more",7486,3492,0,0,1,Restaurants,[email protected],443300100270,,SG191RB,St Neots,,GB,pizzauk | |
| 2986836082,zialuciapizza,Zia Lucia,,,http://www.zialucia.com/, |
| -- Table that store hotels reviews | |
| CREATE TABLE hotels_reviews ( | |
| id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, | |
| review TEXT NOT NULL | |
| ); | |
| -- As SQLite index content on a virtual table, | |
| -- We need to create a virtual table for hotels_reviews | |
| -- I use the last extension fts5 for full text searching https://www.sqlite.org/fts5.html | |
| -- I use the "porter" tokenizer, check this link for definition: https://www.sqlite.org/fts3.html#tokenizer |
| var secondes = Math.floor((Math.random() * 10) + 3); | |
| var duration = secondes; | |
| $('#activity-popup-dialog-body').find('.not-following').find('button.follow-button').each(function() { | |
| var _this = this; | |
| setTimeout(function() { | |
| $(_this).trigger('click'); | |
| }, duration * 1000); | |
| duration += secondes; |
| .mar-left-5 { | |
| margin-left: 5px; | |
| } | |
| .mar-left-10 { | |
| margin-left: 10px; | |
| } | |
| .mar-left-15 { | |
| margin-left: 15px; |