BBQ Linux install drivers

Below approaches were tried to install the NVidia run driver in the Arch Linux.

Approach 1 :

The NVIDIA package includes an automatic configuration tool to create an Xorg server configuration file (xorg.conf) and can be run by:

# nvidia-xconfig

This command will auto-detect and create (or edit, if already present) the /etc/X11/xorg.conf configuration according to present hardware.

If there are instances of DRI, ensure they are commented out:

#    Load        "dri"

Double check your /etc/X11/xorg.conf to make sure your default depth, horizontal sync, vertical refresh, and resolutions are acceptable.

Installation using official repositories

pacman -S foobar

Installation using the custom repositories
makepkg -sri


Approach 2 :

Run the .run file provided by Nvidia.

Before that the X Server needs to be stopped.

systemctl start example.service

systemctl stop X

run the .run file

the restart the server X using systemctl start X



Android: Filling a table from resource file using xml (SQLite)

Good link.

Cleanest way to build an SQL string in Java

Properties file can be used:

update_query=UPDATE user_table SET name=? WHERE id=?

Then with the help of a simple utility class:

public class Queries {

    private static final String propFileName = "";
    private static Properties props;

    public static Properties getQueries() throws SQLException {
    	InputStream is = 
    		Queries.class.getResourceAsStream("/" + propFileName);
    	if (is == null){
    		throw new SQLException("Unable to load property file: " + propFileName);
    	if(props == null){
    		props = new Properties();
    		try {
    		} catch (IOException e) {
    			throw new SQLException("Unable to load property file: " + propFileName + "\n" + e.getMessage());
    	return props;

    public static String getQuery(String query) throws SQLException{
    	return getQueries().getProperty(query);


you might use your queries as follows:

PreparedStatement stm = c.prepareStatement(Queries.getQuery("update_query"));

All credits to the guy who gave the answer.

Source : StackOverflow

Week’s favorite links

Like every other week this week was full of news

  • Maya steps back from the UPA Coalition for neglecting UP( More like probably neglecting her!).
  • Karan Johar started blogging. His blog is is called “My first blog”( I expected a name which had Shah Rukh in it). Surely these guys are a threat for amateur blogger like me.
  • RGV’s new post made me think he should start making comedy films instead of films related to the Underworld.
  • Nuclear deal,Left threatens to copy the Maya style. Manmohan has got a new watch. To start the countdown for the fall of the government.
  • Shreesanth fights again! This time with the Ashoka hotel guys. ( He’s such a showoff).
  • Gorkaland strike.( Before the clash began I was thinking gorkas were the hindi name for Watchmen). Thank God my doubt was cleared.

I could only find these links. I’ll be adding more later.