Monday, July 09, 2018

Stock and Geography New Data Types have AI Support


I think you must have specific versions of Office 365 for you to work with these new data types.

Microsoft is excited but I am not, as I may have to pay up for (or upgrade subscription) something I may only use to see what it can do.

The nice thing about these are they are AI Powered and they search things out of Microsoft Knowledge Graph, the service that powerss their search engine, Bing.

What it does is it has a context and the search is in this context.

These are shots of Excel sheet with the Geography data type from the above link.




Tuesday, July 03, 2018

September 25: Moving from Rome to Orvieto

September 25: As per our tour itinerary, we are moving to Orvieto in Umbria

As I continued to have throat problems and mild fever, we decided to call a doctor to the hotel. Our tour director had found this doctor (Dott. Guerreiro Andrea) on Saturday and he promptly showed up at the hotel this Monday morning. He looked at me, tapped my chest and looked into my throat and prescribed me some antibiotics and cough medicine. He had a pleasant personality and could speak English quite fluently. Since it is more like a home visit, the visit charges were 100 euros. The pharmacy was close by and Zithromax was a common enough FDA approved antibiotic which means four more days sans vin.

We had our lunch at Lampada one more time as it had guaranteed vegetarian dishes. As usual I was not disappointed.

Orvieto is about 75 miles north of Rome. We left Rome around 2:30 PM and we arrived at one of the entrances of Orvieto. It has a couple of entrances from the highway and this is not the main entrance but where tourist buses park.

We carried out suitcases on the cobbled streets of Orvieto under shades of oak and chestnut trees. Orvieto is about 1000' above sea level and I recall the road to the hotel was steep as well part of the way.

We arrived at the Grand Hotel Italia situated almost in the center of this historic town. The hotel, as I recall, was comfortable. Room assigned to us was on the 3rd floor. There was a lift as well, but we took the stairs. The hotel staff were friendly. I especially liked the coffee and breakfast room at the entrance where one could have different brews and of course the famous wines of Umbria.
The rooms were spacious, and our window commanded the view of roof tops and the narrow streets down below.

Today was supposed to be an exciting day and we were going to experience the making of pasta at one of the local restaurants called Zeppelin. It appears that this restaurant excels in this activity.

Here are some photos of the day and later a few videos.

Lampada Buffet




Orvieto Municipal Building


The Dodecagonal Bell Tower and Church of St. Andrea and Bartholomew


Group entering Zeppelin

Getting seated and wine is coming in..




Singing after wine and pasta ...


Pasta making with the chef


More photos here:

From Rome to Orvieto:
https://youtu.be/jdldKMHdd9M



Pasta 2 KneadingRolling

Pasta 3 PreppingCutting 







Wednesday, June 20, 2018

Using a Pivot() operator in SQL Server

Pivot() is a relational operator that changes a table-valued expression into another table. It rotates the table-valued expression by turning the unique values from one column  in the expression into multiple columns in the output and performs aggregations where they are required on any remaining column values that are wanted in the final output.

This is the syntax from MSDN for the PIVOT operator.
------------
SELECT
    [first pivoted column] AS
    [second pivoted column] AS
    ... 
    [last pivoted column] AS  
FROM 
    (
------------
Let us take an example frrom Northwind database. Here is a query that Selects lastname of employee and Unitprice from the Order Details table for UnitPrice greater than 50 and Quantity>10.


Pivot_0.png

You can see that Employees figure in many orders (have order details) with different UnitPrices. Now if you want to aggreegate the average Unitprice of articles sold by each employee (or a chosen number of employees) you need to do an aggregate.

For the above query we cannot directly use the PIVOT operator and we need to create an ALIAS as shown. PriceTable is the ALIAS for this query
----------
Select * FROM
(SELECT        Employees.LastName, [Order Details].UnitPrice
FROM            Employees INNER JOIN
                         Orders ON Employees.EmployeeID = Orders.EmployeeID INNER JOIN
                         [Order Details] ON Orders.OrderID = [Order Details].OrderID INNER JOIN
                         Products ON [Order Details].ProductID = Products.ProductID
WHERE [Order Details].UnitPrice >50.00 and [Order Details].Quantity>10)
as PriceTable
-----------
Nothing is changed as far as the Query return is concerned but we now have an  ALIAS.

Now we create a table which aggregates the average of UnitPrice for some named Employees using their LastName from the PriceTable as shown here.
----------
Select * FROM
(SELECT        Employees.LastName, [Order Details].UnitPrice
FROM            Employees INNER JOIN
                         Orders ON Employees.EmployeeID = Orders.EmployeeID INNER JOIN
                         [Order Details] ON Orders.OrderID = [Order Details].OrderID INNER JOIN
                         Products ON [Order Details].ProductID = Products.ProductID
WHERE [Order Details].UnitPrice >50.00 and [Order Details].Quantity>10)
as PriceTable
Pivot(Avg(UnitPrice) For LastName in ([King], [Davolio], [Fuller],[Peacock],[Suyama]))
as StudentPivot
----------------
When you run this the response is a table that has the values we were looking for:




Tuesday, June 19, 2018

Historic meeting that may change the shape of things to come


The historic meeting and the follow up signing is nothing short of a miracle considering the events that preceded the meeting.

Ok, the meeting is over, the deal is done. What is the deal? It is heavily discussed in the media. It was surprising that at the time it was signed very little was known about the contents and the TV announcers were using words like 'something' was signed.

It appears the wording is still broad, and it is said to be 'Complete'. One must wait and see how it turns out. Our hopes are that it will result in lasting peace and scenes of Hiroshima, Chernobyl and Fukushima are just nightmares from which we woke up.



Here are some pictures taken on that day from a TV screen with a Microsoft Lumia phone. Watch the body language and the emotions on the faces.














 If you missed the signing, here it is.

DMCA.com Protection Status