Bitz-N-Bitez

Sometimes Life Is Like This

NoComment

Real Estate Recovery

fredgraph

One of the things not highlighted during the last campaign season is that real estate prices have generally recovered. The fiscal crisis was not the making of President Obama. It was the inheritance of a disaster that came to fruition in the tale end of President George W. Bush.

patton

A Poem by Rudyard

 THE WRATH OF THE AWAKENED SAXON
by Rudyard Kipling

It was not part of their blood,
It came to them very late,
With long arrears to make good,
When the Saxon began to hate.

They were not easily moved,
They were icy — willing to wait
Till every count should be proved,
Ere the Saxon began to hate.

Their voices were even and low.
Their eyes were level and straight.
There was neither sign nor show
When the Saxon began to hate.

It was not preached to the crowd.
It was not taught by the state.
No man spoke it aloud
When the Saxon began to hate.

It was not suddently bred.
It will not swiftly abate.
Through the chilled years ahead,
When Time shall count from the date
That the Saxon began to hate.

Trumps Inaugural Speech : America First

God Bless The USA

What Is Truth ?

Wonderful dustup twixt Trump and CNN today.  Trump refused their question and called their organization Fake News today in a press conference.   That is certainly atypical for a presidential presser.

Apparently CNN went first last night with a story that the Russians had blackmail material on Trump and then told everyone where to find the scandalous potential blackmail material over at Buzzfeed.  ( I always thought blackmail only works if you do not release it first. )  Buzzfeed allegedly purports to have a classified doc from the presidential security briefing wherein a Russian source confirms, among other things, they have secret footage of Donald hiring hookers to piss on a bed where Obama slept in the Ritz Carlton in Russia.

But the stuff in those docs allegedly started as a bizarre internet fiction writing last year, it got picked up by a former MI6 guy doing opposition research against Trump at the time and later allegedly fed to John McCain as this former MI6 guys secret sleuthing info.  McCain has allegedly admitted getting it from this chap and passing it to FBI. Someone apparently added parts to the original fiction article about getting it from Russian intelligence sources and secret recordings etc.

That whole backstory came out all over the internet…….

So now everyone is blaming everyone and running for cover and credibility. CNN is claiming their info about the doc in the briefing comes from “multiple sources” and “four sources”.   They use the number of unnamed anonymous sources to rebut a conflicting report from NBC that used only “one source”.  The old “I have more unnamed anonymous sources than you have” credibility measure.

All of this is a pure distraction.   The real issue here is how does anyone know what was discussed in a top secret classified presidential briefing ?   Much less how do “multiple” or “four” or maybe five people have info to share on this.   If the press were telling the truth and this many people with actual knowledge of a classified presidential security briefing were talking to the press about what was said and presented in that meeting this would be scandal beyond measure for intelligence organizations and classified data policies.

I still have more faith in our intelligence organizations than that.   Pravda was never this bad.

Good News For Disabled Americans

On December 13, 2016 President Obama signed the “Special Needs Trust Fairness Act” into law. This law makes a simple amendment to 42 U.S.C. 1396p(d)(4)(A)adding the phrase “the individual” so that it now reads.

(A) A trust containing the assets of an individual under age 65 who is disabled (as defined in section 1382c(a)(3) of this title) and which is established for the benefit of such individual by the individual, a parent, grandparent, legal guardian of the individual, or a court if the State will receive all amounts remaining in the trust upon the death of such individual up to an amount equal to the total medical assistance paid on behalf of the individual under a State plan under this subchapter.

This simple change now allows physically disabled but mentally competent people to establish their own Special Needs Trusts. Previously this could only be done if their parent or grandparent did it, or if they were incompetent their guardian could, or perhaps via a court order.

The net is that more disabled people can benefit from the Special Needs Trust’s ability to shelter assets from the draconian limits imposed by SSI and Medicaid.   With the usual caveat that upon their death all assets in the Special Needs Trust revert to Medicaid, or at least enough to repay Medicaid for all of its expenditures for the beneficiary over the lifetime of the beneficiary.

Postgres : Convert entire row to text with type conversion

One of the neat ways you can use postgres type conversion is to display an entire row in a format suitable for using in a subsequent insert etc.   That is comma delimited, quoted as needed between two parenthesis.

First lets document the customer table in this sample dvdrental database.

CREATE TABLE customer (

customer_id integer DEFAULT nextval('customer_customer_id_seq'::regclass) NOT NULL,
store_id smallint NOT NULL,
first_name character varying(45) NOT NULL,
last_name character varying(45) NOT NULL,
email character varying(50),
address_id smallint NOT NULL,
activebool boolean DEFAULT true NOT NULL,
create_date date DEFAULT ('now'::text)::date NOT NULL,
last_update timestamp without time zone DEFAULT now(),
active integer

);

Now lets produce the rows converting the whole row to text as follows….

dvdrental=# select t::text from customer t limit 5;
t
-------------------------------------------------------------------------------------------------------
(524,1,Jared,Ely,jared.ely@sakilacustomer.org,530,t,2006-02-14,"2013-05-26 14:49:45.738",1)
(1,1,Mary,Smith,mary.smith@sakilacustomer.org,5,t,2006-02-14,"2013-05-26 14:49:45.738",1)
(2,1,Patricia,Johnson,patricia.johnson@sakilacustomer.org,6,t,2006-02-14,"2013-05-26 14:49:45.738",1)
(3,1,Linda,Williams,linda.williams@sakilacustomer.org,7,t,2006-02-14,"2013-05-26 14:49:45.738",1)
(4,2,Barbara,Jones,barbara.jones@sakilacustomer.org,8,t,2006-02-14,"2013-05-26 14:49:45.738",1)
(5 rows)

dvdrental=#

While I don’t have an immediate need for this conversion, its still a fascinating little postgres trick.

SQLServer on Ubuntu Restore Tests

Just for fun I decided to test how portable backup files made on the Windows version of SQLServer restore into the Linux version of SQLServer.  I used the wizard built in to my SQL2016 SSMS software connected to the Linux version running on Ubuntu 16 on Amazon EC to run the restore.  The restore was uneventful.  I chose the AdventureWorks2012 database simply because its what I found lying around in the directory I first looked in on my laptop.

The script version of what the wizard generated is as follows…..


USE [master]
RESTORE DATABASE [AdventureWorks2012] FROM DISK = N'C:\home\ubuntu\AdventureWorks2012-Full Database Backup.bak' WITH FILE = 1, MOVE N'AdventureWorks2012_Data' TO N'C:\var\opt\mssql\data\AdventureWorks2012_Data.mdf', MOVE N'AdventureWorks2012_Log' TO N'C:\var\opt\mssql\data\AdventureWorks2012_log.ldf', NOUNLOAD, STATS = 5

GO

 

Interestingly the tool browsed the directory structure ok but for some reason could not find my backup file, even when saying “all files” and no it wasn’t perms or anything.  I manually typed in the file name to the wizard browser and it worked fine.   I am NOT using the recommended version of SSMS for connecting to Linux on purpose.   I want to find out what breaks if I don’t…. 🙂