Posts

Showing posts from 2017

How to add a bootstrap table with fixed header and scrollable body

I am pretty sure that everyone is familiar with bootstrap CSS, if not please take a look(bootstrap). Now Bootstrap has lots of different components and table styling is one of them and they have plenty of different styling options. Now sometimes if we have to display a large amount of data inside a table, the user will have to scroll till the end of the table and after few scroll, they can not see the table header. There is a way to fix this. Please follow the below steps. Step1: Create a bootstrap table first <table class="table table-fixed">   <colgroup></colgroup>   <colgroup class=""></colgroup>   <thead>   <tr>     <th>       <label>         ##       </label>     </th>     <th>       <label class="">         ###       </label>     </th>   </tr>   </thead>   <tbody id="fixed-height">       <tr>         &

Upgrade Postgres 9.4 to 9.6 in MAC.

Postgres 9.6.1 is the current Postgres version, if you want to upgrade the Postgres version in mac it very easy now using homebrew. Just follow the below steps Step 1: Turn PostgreSQL off first:     $ launchctl unload ~/Library/LaunchAgents/homebrew.mxcl.postgresql.plist     # or, if you're running a current version of Homebrew     $ brew services stop postgresql Step 2: Update brew and upgrade Postgres     $ brew update && brew upgrade postgresql Step 3: Initialize the new empty database     $ initdb /usr/local/var/postgres9.6.1 -E utf8 Step 4: When we update check the currently available version of the system     $ ls /usr/local/Cellar/postgresql/ Which gives you output something like this: 9.4, 9.5.0, 9.6.1 If you have more than two, that’s ok, just get the most recent one (9.6.1) and the last before 9.5.0. Remember that version for the next step. Step 5: Upgrade the version $ pg_upgrade \   -d /usr/local/var/postgres \   -D /usr/local/var/postgre