Add test demo
Corrected a bug on type judging.
Add Postgre supporting.
Some modifies.