Posts

Showing posts from January, 2019

Bootstrap 4 Footer Examples

Example 1: bootstrap 4 footer <!-- Footer --> <footer class= "page-footer font-small blue pt-4" > <!-- Footer Links --> <div class= "container-fluid text-center text-md-left" > <!-- Grid row --> <div class= "row" > <!-- Grid column --> <div class= "col-md-6 mt-md-0 mt-3" > <!-- Content --> <h5 class= "text-uppercase" >Footer Content</h5> <p>Here you can use rows and columns to organize your footer content.</p> </div> <!-- Grid column --> <hr class= "clearfix w-100 d-md-none pb-3" > <!-- Grid column --> <div class= "col-md-3 mb-md-0 mb-3" > <!-- Links --> <h5 class= "text-uppercase" >Links</h5> <ul class= "list-unstyled" > <li>

Clear Explanation Of The "theta Join" In Relational Algebra?

Answer : Leaving SQL aside for a moment... A relational operator takes one or more relations as parameters and results in a relation. Because a relation has no attributes with duplicate names by definition, relational operations theta join and natural join will both "remove the duplicate attributes." [A big problem with posting examples in SQL to explain relation operations, as you requested, is that the result of a SQL query is not a relation because, among other sins, it can have duplicate rows and/or columns.] The relational Cartesian product operation (results in a relation) differs from set Cartesian product (results in a set of pairs). The word 'Cartesian' isn't particularly helpful here. In fact, Codd called his primitive operator 'product'. The truly relational language Tutorial D lacks a product operator and product is not a primitive operator in the relational algebra proposed by co-author of Tutorial D, Hugh Darwen**. This is because th

Can I Use Ender Chests To Transfer Items From The End?

Answer : According to http://minecraft.wikia.com/wiki/Ender_Chest, it does work that way. If two Ender Chests are placed and two of an item was put in one, when the chest with the items in is opened, there will be one of the item in that chest and one of the same item in the other chests, acting as an image. This feature also works among the different worlds: Overworld, Nether, and the End. Yes , your items will be transported anywhere in the world, including The End, The Nether, or anywhere else. Be careful, though, that what you placed in an Ender Chest can only be picked up by you, and nobody else. So you can't transfer your items to your friend this way. Yup, they work between dimensions transferring itens.

Change Language Of Visual Studio 2017 RC

Image
Answer : You can only install a language pack at install time in VS 2017 RC. To install RC with a different language: Open the Visual Studio Installer. Find an addition under "Available" and click Install Click on the "Language packs" tab and select a language You can have multiple instances of VS 2017 side by side so this shouldn't interfere with your other installation. Disclosure: I work on Visual Studio at Microsoft. Go to Tools -> Options Select International Settings in Environment and on the right side of a screen you should see a combo with the list of installed language packages. (so in my case Czech, English and same as on MS Windows ) Click on Ok You have to restart Visual Studio to see the change... If you are polish (and got polish language settings) Narzędzia -> Opcje Ustawienia międzynarodowe in Środowisko Hope this helps! Have a great time in Poland! This should solve it: Open the Visual Studio Instal

A Putty Shortcut That Automatically Launches A Profile?

Answer : From the Putty FAQ: To run a PuTTY session saved under the name ‘mysession’, create a Windows shortcut that invokes PuTTY with a command line like \path\name\to\putty.exe -load "mysession" ---EDIT--- In Windows 7, the shortcut has to be in quotes like this: "\path\name\to\putty.exe" -load "mysession" I had referred to Putty Connection Manager as a useful addon, giving one click connects and tabbed windows, but it seems the app is dead and all the files removed from the hosting site. While checking into this, I found a fork of the project, called superputty (see below) and a reference to KiTTY - a Win32 native version of PuTTY with extra features so here you go: Superputty:https://github.com/jimradford/superputty KiTTY: http://kitty.9bis.com/ In windows use this target for putty shortcut, for save username and password. Then load a saved session or add to Task Manager: "C:\Program Files\PuTTY\putty.exe" -load "

A Sql Query Automatically Eliminates Duplicates Code Example

Example 1: sql delete duplicate -- Oracle DELETE films WHERE rowid NOT IN ( SELECT min ( rowid ) FROM films GROUP BY title , uk_release_date ) ; Example 2: how to query without duplicate rows in sql SELECT DISTINCT col1 , col2 . . . FROM table_name where Condition ; Example 3: how to remove duplicate in sql Distinct : helps to remove all the duplicate records when retrieving the records from a table . SELECT DISTINCT FIRST_NAME FROM VISITORS ; Example 4: sql delete duplicate rows but keep one # Step 1: Copy distinct values to temporary table CREATE TEMPORARY TABLE tmp_user ( SELECT id , name FROM user GROUP BY name ) ; # Step 2: Remove all rows from original table DELETE FROM user ; # Step 3: Remove all rows from original table INSERT INTO user ( SELECT * FROM tmp_user ) ; # Step 4: Remove temporary table DROP TABLE tmp_user ; Example 5: sql query to delete duplicate records --ID should be pri

Android Change Background Drawable Programmatically Code Example

Example: android studio setbackground RelativeLayout layout = ( RelativeLayout ) findViewById ( R . id . background ) ; layout . setBackgroundResource ( R . drawable . ready ) ;

80 Inches In Cm Code Example

Example: inch to cm 1 inch = 2.54 cm

Bootstrap 4 Sticky-top Margin-top

Answer : Try: .sticky-top { top: 0.5em; }

Cd Command In Ubuntu Code Example

Example 1: linux change directory // change directory in terminal cd folder_name/subfolder_name // go up one directory level cd .. // back to previous directory cd - // return to home directory cd Example 2: navigate to a directory linux /* File & Directory Commands To navigate into the root directory, use */ "cd /" /* To navigate to your home directory, use */ "cd" /*or*/ "cd ~" /* To navigate up one directory level, use*/ "cd .." /* To navigate to the previous directory ( or back ) , use */ "cd -" Example 3: ubuntu navigate to directory in windows cd /mnt/e/username/folder1/folder2

Opa The Expanse Code Example

Example: OPA in expanse Outer Planets Alliance The Outer Planets Alliance ( OPA ) is a loosely affiliated network borrowing or associating under a core common ideology that started its life as a labor union or advocacy group , fighting for the interests of inhabitants of the Belt , often in direct conflict with the inner planets ' Earth - Mars Coalition Navy .

Clear Table Sql Code Example

Example 1: query to empty table data in sql server TRUNCATE TABLE table_name; Example 2: empty an sql table TRUNCATE TABLE table_name; Example 3: delete all records from table DELETE FROM table_name; Example 4: sql delete DELETE FROM table_name WHERE condition; -- Ex. DELETE FROM Customers WHERE CustomerName='Mustafa Mbari'; Example 5: sql delete where in -- Deletes all records where `columnName` matches the values in brackets. DELETE FROM tableName WHERE columnName IN ('val1', 'val2', 'val3'); Example 6: delete query public function deletedata(){ $this->db->where('id', 2); $this->db->delete('table_name'); }

ASCII Code For The TAB Character? (Want To Be Able To Input Tabs Into A Web Page Textbox)

Answer : Didn't read most of you post, sorry. But just fixing on the final little question what is the ASCII key code for Tab? ASCII value for tab is 9 (decimal or hex), so try Alt + ( Numpad 0 , Numpad 9 ). But, I've just tested doing so in this very edit box and it doesn't work, but it does in notepad, MS Word, etc. I wonder why...? Anyway, if you really need a tab somewhere odd, try copying one from notepad and pasting it where you need it - that's what I tend to do. Edit If you're doing this for it to be displayed on a website (which is what I think you're implying), a tab character may be ignored because HTML tends to ignore whitespace (outside of pre blocks, etc). If it is HTML you could also use the HTML entity version &#09; as well, but this will function in the same way. The code is ALT + 0 0 9 However, I don't think it will accomplish what you are after. Hope this helps you -- you have quite a long question :-) Wikipedia

Android App - Adding A "share" Button To Share The App On Social Networks

Answer : Solution 1: Launch ACTION_SEND Intent When launching a SEND intent, you should usually wrap it in a chooser (through createChooser(Intent, CharSequence)), which will give the proper interface for the user to pick how to send your data and allow you to specify a prompt indicating what they are doing. Intent intent = new Intent(); intent.setAction(Intent.ACTION_SEND); # change the type of data you need to share, # for image use "image/*" intent.setType("text/plain"); intent.putExtra(Intent.EXTRA_TEXT, URL_TO_SHARE); startActivity(Intent.createChooser(intent, "Share")); Solution 2: Use ShareActionProvider If you are just looking to add a Share button in Overflow Menu, also have a look at ShareActionProvider. public boolean onCreateOptionsMenu(Menu menu) { getMenuInflater().inflate(R.menu.share, menu); MenuItem item = menu.findItem(R.id.share_item); actionProvider = (ShareActionProvider) item.getActionProvider(); // Cre

Android InstrumentationTestCase GetFilesDir() Returns Null

Answer : I think that you are right with keeping your test data separate from tested application. You can fix problem with Null by creating files directory for Instrumentation app by executing the following commands adb shell cd /data/data/<package_id_of_instrumentation_app> mkdir files You can do above only on emulator or rooted device. Then test from your question will not fail. I did it and also uploaded file named tst.txt to files dir, all below tests were successful: assertNotNull(getInstrumentation().getContext().getFilesDir()); assertNotNull(getInstrumentation().getContext().openFileInput("tst.txt")); assertNotNull(getInstrumentation().getContext().openFileOutput("out.txt", Context.MODE_PRIVATE)); But I think more convenient way to provide data to test project is to use assets of test project where you can simply save some files and open them: assertNotNull(getInstrumentation().getContext().getAssets().open("asset.txt"))

Fcfs Disk Scheduling Program In C Code Example

Example: fcfs disk scheduling in c /* This code is contributed by : Tanishq Vyas (github : https://github.com/tanishqvyas) */ # include <stdlib.h> # include <stdio.h> # include <unistd.h> //Header file for sleep() # include <pthread.h> int main ( int argc , char const * argv [ ] ) { int range , queue_size , cur_pos , cur_seek_time , total_seek_time = 0 ; printf ( "Enter the max range of disk : " ) ; scanf ( "%d" , & range ) ; printf ( "Enter the queue size : " ) ; scanf ( "%d" , & queue_size ) ; int req_queue [ queue_size ] ; printf ( "Enter the queue of disk portions to be read : " ) ; for ( int i = 0 ; i < queue_size ; i ++ ) { scanf ( "%d " , & req_queue [ i ] ) ; } int hold ; scanf ( "%d" , & hold ) ; printf ( "Enter the initial head position :

Bootstrap Textarea Form Size Code Example

Example 1: input with bootstrap < form > < div class = " form-group " > < label for = " exampleInputEmail1 " > Email address </ label > < input type = " email " class = " form-control " > < small id = " emailHelp " class = " form-text text-muted " > Hello, World </ small > </ div > </ form > Example 2: bootsrap textbox < form > < div class = " form-group " > < label for = " exampleFormControlInput1 " > Email address </ label > < input type = " email " class = " form-control " id = " exampleFormControlInput1 " placeholder = " name@example.com " > </ div > < div class = " form-group " > < label for = " exampleFormControlSelect1 " > Example select </ label > < select cla

AngularJS Toastr Example

Example 1: angular toastr npm install ngx-toastr --save npm install @angular/animations --save // angular.json "styles": [ "styles.scss", "node_modules/ngx-toastr/toastr.css" // try adding '../' if you're // using angular cli before 6 ] // app.module import { CommonModule } from '@angular/common'; import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; import { ToastrModule } from 'ngx-toastr'; imports: [ CommonModule, BrowserAnimationsModule, // required animations module ToastrModule.forRoot(), // ToastrModule added ], // component import { ToastrService } from 'ngx-toastr'; constructor(private toastr: ToastrService) {} showSuccess() { this.toastr.success('Hello world!', 'Toastr fun!'); } Example 2: angular toast npm install ngx-toastr --save

Bukkit Events List Code Example

Example: bukkit event list You can find it on the javadocs, http://jd.bukkit.org/

Tmux Switch Panes Code Example

Example: tmux basic commands Ctrl + b c Create a new window ( with shell ) Ctrl + b w Choose window from a list Ctrl + b 0 Switch to window 0 ( by number ) Ctrl + b , Rename the current window Ctrl + b % Split current pane horizontally into two panes Ctrl + b " Split current pane vertically into two panes Ctrl + b o Go to the next pane Ctrl + b ; Toggle between the current and previous pane Ctrl + b x Close the current pane

Insertion Sort Algorithm In A Singly Linked List In C Code Example

Example: insertion singly linked list in c /** * C program to insert a new node at the beginning of a Singly Linked List */ # include <stdio.h> # include <stdlib.h> /* Structure of a node */ struct node { int data ; // Data struct node * next ; // Address } * head ; void createList ( int n ) ; void insertNodeAtBeginning ( int data ) ; void displayList ( ) ; int main ( ) { int n , data ; /* * Create a singly linked list of n nodes */ printf ( "Enter the total number of nodes: " ) ; scanf ( "%d" , & n ) ; createList ( n ) ; printf ( "\nData in the list \n" ) ; displayList ( ) ; /* * Insert data at the beginning of the singly linked list */ printf ( "\nEnter data to insert at beginning of the list: " ) ; scanf ( "%d" , & data ) ; insertNodeAtBeginning ( data ) ; printf ( "