Mongodb does not start

Whenever I try to use start mongo db using the command "mongo" it shows me the following error. I have removed the mongod.lock file from the /var/mongo/ directory but still I am facing this error. MongoDB shell version: 2.4.8 connecting to: test

SQL Server equivalent of the Postgres query

select column from table order by row_number() over () limit 1000 offset 200; I have the above query in PostgreSQL. I want the SQL Server equivalent of the above. I tried the one below: select top 1000 offset 200 column from table order by row_number

Javascript problem with IE11

My app was working fine till IE9, now it stopped working when I upgraded it to IE11. Here is a sample html and js . ISSUE In the first run ie. on load it works well. But when I select PDA brand, second dropdown's all options went blank. In console th

RVM will not download Ruby

I tried installing Ruby 1.9.3 through RVM while I was in a public Wifi that didn't allow FTP. This broke the download but since then rvm install 1.9.3 skips "fetching" and therefore I can't install 1.9.3. I tried uninstall and remove with RVM bu

SharedPreferences Editor commit takes so long

i try to make a configuration activity using PreferenceActivity... i found some working examples like "WiFi Advanced Configuration Editor" and "Wifi Config Editor Pro" but the code i wrote waits for 10-15 seconds on the line

Sprintf () with automatic memory allocation?

I'm searching for a sprintf()-like implementation of a function that automatically allocates required memory. So I want to say char* my_str = dynamic_sprintf( "Hello %s, this is a %.*s nice %05d string", a, b, c, d ); and my_str retrieves the ad

AWSS3TransferUtilityErrorDomain Code = 2 on ios

AWSS3TransferUtilityErrorDomain Code=2 getting this error when uploading reaches 100% on iOS while android is working fine. I am using react-native-s3. but it seems to be an issue with sdk or my bucket policy but I don't know how to fix this. More in

PyQt - Inheriting QLabel

i wanna inherit QLabel to add there click event processing. I'm trying this code: class NewLabel(QtGui.QLabel): def __init__(self, parent): QtGui.QLabel.__init__(self, parent) def clickEvent(self, event): print 'Label clicked!' But after clicking I h

Jquery disables previous radio buttons in Yii2

<?= $form->field($model, 'status')->radioList(array('1'=>'Approved','2'=>'Digital','3'=>'CDP','4'=>'Print','5'=>'Other Process','6'=>'Packing','7'=>'Dispatch',)); ?> I'm trying to implement status update form. I want to kn

How to manage the code downloaded in GAE?

Is there a way to manage interactively (view/delete) config and code of an application in google app engine? I understand that the deployment approach is versioned batch upload, but can i at least download back a collection of uploaded files of curre

Constant Score Query

My understanding of Constant Score Query in elasticsearch is that boost factor would be assigned as score for every matching query. The documentation says: A query that wraps a filter or another query and simply returns a constant score equal to the

How to add a php file link in the menu

I am the begineer in WP trying to convert my HTML site to Wordpress theme. Everything working fine but i want to link one page having name contact-us.php in my theme root directory , i want to link this page with contact us menu in the header.The way

Bundle Identifier differs from the previous batch identifier

So this really put headache on my head and I finally gave up and posted question here. I am trying to update one of my client Application in iTune store and we are facing below error while uploading to App store. So, I already tried couple of solutio

Converting a CGPoint to NSValue

In CABasicAnimation.fromValue I want to convert a CGPoint to a "class" so I used NSValue valueWithPoint but in device mode or simulator one is not working... need to use NSMakePoint or CGPointMake if in device or simulator.There is a UIKit addit

Dependencies of OOP class methods

It is OK to have methods depend one on each other inside a class, methods that are encapsulated together? Does this affect unit testing? or the term Unit is addressing to the whole class and not to the class own methods. It is OK to do something like

Android firebase retrieves data in listview error

i am stuck in my code to retrieve firebase data in listview using Model Class. I have to retrieve data in list view when i use String Class instead of Model Class so data is showing but when i use Model Class app is stopping and close here is error g

Malloc, string pointers and Valgrind

My program is like this (main.c): #include <stdlib.h> #include <stdio.h> void main(){ char *first="hello "; char *second="world!"; char *seq=(char *)malloc((strlen(first)+1)*sizeof(char)); strcat(strcpy(seq,first),second);

Count specifying the value through the columns in r

I have a table that looks something like this: v1 v2 v3 pos neg pos pos pos pos neg neg neg I want to create another column which has the winner between other three columns v1 v2 v3 v4 pos neg pos pos pos pos pos pos neg neg neg neg Another possibili

Use of aggregated functions in JPA

I have the folowing situation. I want to retrieve a list of bids between time t1 and time t2. Then from this list i want to retrieve winning bid i.e maximum bid price. I have written the following JPA query. SELECT b FROM Bid b WHERE b.bidAmt = (SELE

Bubbling action in Ember

I am relatively new to Ember so forgive me if the answer to this question is obvious. I started a new job recently and I thought their approach to action bubbling was...curious. This is a big application with a lot of deeply nested components. To bub

Normal Alert Dialog in Android

The alert dialog appears as a custom alert dialog like the white one. How to make the alert dialog appear normal? Black and blue. AlertDialog.Builder builder = new AlertDialog.Builder(this) AlertDialog.Builder builder = new AlertDialog.Builder(this)

Add Library AndEngine

I got AndEngine from github and did as follows: And i got AndEnginePhysicsBox2DExtension and did: After that i added the libraries to my App I then imported But then when i press OK and open the properties of my app i get this How can i fix this prob

C pipes not communicating

I have a coding assignment wherein I am to set up a ring of processes using fork(), and then pass a message through the ring. now, the apparent issue at this point is that I cannot pass a message from the initial process to its directly connected chi

Printing of the pyramidal pattern of the characters

I need to print an array of characters in a pyramid shape. What I have so far is this: char[] chars = {'F', 'E', 'L', 'I', 'Z', ' ', 'A', 'N','I', 'V', 'E', 'R', 'S', 'A', 'R', 'I', 'O'}; int length = chars.length; for (int i = 1; i < length; i += 2)