Parameter of git-commit command that adds the current staging area to the last commit and allows you to (by default) edit previously used commit message or (if other options were given) reuse it or even discard it and write a new one.
I accidentally amended my previous commit. The commit should have been separate to keep history of the changes I made to a particular file.
Is there a way to undo that last commit? If I do something ..
When I've worked a bit with my source code, I did my usual thing commit and then I pushed to a remote repository. But then I noticed I forgot to organize my imports in the source code. So I do the ame..
I'm looking for a counter-part of git commit --amend in Mercurial, i.e. a way to modify the commit which my working copy is linked to. I'm only interested in the last commit, not an arbitrary earlier ..
Is there a way to amend a commit without vi (or your $EDITOR) popping up with the option to modify your commit message, but simply reusing the previous message?..
This is similar to Stream data with Node.js, but I don't feel that question was answered sufficiently.
I'm trying to use a jQuery ajax call (get, load, getJSON) to transfer data between a page and a ..
Is there any way, in Windows 7 Professional, to run a batch script (e.g., a .BAT file) when the user clicks on "shutdown" (not a batch file scheduled to shut down the machine, just one that runs only ..
I want to use the jQuery UI sortable function to allow users to set an order and then on change, write it to the database and update it. Can someone write an example on how this would be done?..
I have source in a bunch of subdirectories like:
src/widgets/apple.cpp
src/widgets/knob.cpp
src/tests/blend.cpp
src/ui/flash.cpp
In the root of the project I want to generate a single Makefile usin..
I am pretty new to go and I was playing with this notify package.
At first I had code that looked like this:
func doit(w http.ResponseWriter, r *http.Request) {
notify.Post("my_event", "Hello Wo..
For example, I have a RESTful service called Purchase Service. Should I name my repository:
purchaserestservice
purchase-rest-service
purchase_rest_service
or something else?
What's the convention..
I'm getting the same results from
select length(column_name) from table
as
select dbms_lob.getlength(column_name) from table
However, the answers to
this question seem to favor using dbms_lob.g..
It's possible to use following method for content's setting of a web-view
loadData(String data, String mimeType, String encoding)
How to handle the problem with unknown encoding of html data?!
Is th..
Is there a way to get npm to unbuild all the modules under node_modules? Something like npm rebuild that removes all build artifacts but doesn't rebuild them?..
I have an HTML form that a user can input text into a title field, I then have php creating an HTML file called title.html
My problem is that users can input spaces and apostrophes into the title fie..
UPDATE
The supposed duplicate is a question on being stucking in "Waiting For Debugger" when executing Run, while this question is on being stucking in "Waiting For Debugger" when executing Debug, the..
I've build a react-native application and suddenly I get this error message on my terminal during run of the command react-native run-ios.
The same code work fine 10 minutes ago and suddenly I get thi..
I am storing the last login time in MySQL in, datetime-type filed. When users logs in, I want to get the difference between the last login time and the current time (which I get using NOW()).
How can..
I have a multi-line string literal that I want to do an operation on each line, like so:
inputString = """Line 1
Line 2
Line 3"""
I want to do something like the following:
for line in inputString..
This code generates error:
IndexError: invalid index to scalar variable.
at the line: results.append(RMSPE(np.expm1(y_train[testcv]), [y[1] for y in y_test]))
How to fix it?
import pandas as pd
i..
I am working with Spring Framework 4.0.7, together with MVC and Rest
I can work in peace with:
@Controller
ResponseEntity<T>
For example:
@Controller
@RequestMapping("/person")
@Profile("..
Is it possible to launch any arbitrary iPhone application from within another app?, For example in my application if I want the user to push a button and launch right into the Phone app (close the cur..
I am trying to convert a date with individual parts such as 12, 1, 2007 into a datetime in SQL Server 2005. I have tried the following:
CAST(DATEPART(year, DATE)+'-'+ DATEPART(month, DATE) +'-'+ DATE..
I'm attempting to send a XMLHttpRequest to a paste site. I'm sending an object containing all the fields that the api requires, but I keep getting this issue. I have read over the issue, and I thought..
At the risk of stepping into holy war territory, What are the strengths and weaknesses of these popular DI/IoC frameworks, and could one easily be considered the best? ..:
Ninject
Unity
Castle.Wind..
Note: This question is not about making a custom dropdown. It's only about possibilities of styling <option> elements within the select element in CSS
How can I style <option>s of a <s..
Running the following code, I get an exception:
using (var client = new Pop3Client())
{
client.Connect(provider.ServerWithoutPort, provider.Port, true);
}
The Exception I get:
The remote certi..
I've just started working with Cassandra (datastax), version 2.1.3 and cqlsh version 5.0.1.
Cassandra starts up fine and the cluster is operational instantly.
Cqlsh is not working (on any of the nod..
The code below displays a Google map and search results when you enter an address and hit the submit button. I've been playing with it to try
and force the page to completely refresh or reload once y..
I have an iframe and in order to access parent element I implemented following code:
window.parent.document.getElementById('parentPrice').innerHTML
How to get the same result using jquery?
UPDATE: ..
I am very new to python. I was trying to pass value from one method to another within the class. I searched about the issue but i could not get proper solution. Because in my code, "if" is calling cla..
I am using the following code to plot a bar-chart:
import matplotlib.pyplot as pls
my_df.plot(x='my_timestampe', y='col_A', kind='bar')
plt.show()
The plot works fine. However, I want to improve ..
I am using the <video> tag, and I want to use any URL from YouTube in it.
I have this http://jsfiddle.net/wCrNw/ but it's not working.
I have checked this Show Youtube video source into HTML5 vi..
How can I get the HTML source in a variable using the Selenium module with Python?
I wanted to do something like this:
from selenium import webdriver
browser = webdriver.Firefox()
browser.get("http..
I'm getting the following error when trying to install an android platform on a Cordova project. I've been following this guide: https://cordova.apache.org/docs/en/latest/guide/cli/
Error occurs when..
I'm using T-SQL with ASP.NET, and c# and i'm pretty new to SQL.
I was wondering how i could combine the results of two queries
Query1:
SELECT tableA.Id, tableA.Name, [tableB].Username AS Owner, [t..
While trying to overlay a new line to a existing ggplot I am getting the following error:
Error: ggplot2 doesn't know how to deal with data of class uneval
The first part of my code works fine. B..
I am having a problem parsing simple JSON strings. I have checked them on JSONLint and it shows that they are valid. But when I try to parse them using either JSON.parse or the jQuery alternative it g..
Are there any major differences in performance between http and https? I seem to recall reading that HTTPS can be a fifth as fast as HTTP. Is this valid with the current generation webservers/browse..
How to configure nicely Spring Boot application packaged as executable jar as a Service in the Linux system? Is this recommended approach, or should I convert this app to war and install it into Tomca..
The server is sending a string in this format: 18:00:00. This is a time-of-day value independent of any date. How to convert it to 6:00PM in Javascript? I could prepend today's date as a string to the..
How can I reference the script element that loaded the javascript that is currently running?
Here's the situation. I have a "master" script being loaded high in the page, first thing under the HEAD t..
I am using the Long primitive type which increments by 1 whenever my 'generateNumber'method called. What happens if Long reaches to his maximum limit? will throw any exception or will reset to minimum..
How do you get matplotlib.pyplot to "forget" previous plots
I am trying to plot multiple time using matplotlib.pyplot
The code looks like this:
def plottest():
import numpy as np
import mat..
In a 3-row layout:
the top row should be sized according to its contents
the bottom row should have a fixed height in pixels
the middle row should expand to fill the container
The problem is that ..
I need to determine the number of days in a month for a given date in SQL Server.
Is there a built-in function? If not, what should I use as the user-defined function?..
I'm wondering how I could create one of those nifty console counters in Python as in certain C/C++-programs.
I've got a loop doing things and the current output is along the lines of:
Doing thing 0
..
I have this simple code:
import re, sys
f = open('findallEX.txt', 'r')
lines = f.readlines()
match = re.findall('[A-Z]+', lines)
print match
I don't know why I am getting the error:
'expected ..
I want to execute a script inside a subdirectory/superdirectory (I need to be inside this sub/super-directory first). I can't get subprocess to enter my subdirectory:
tducin@localhost:~/Projekty/test..
Currently there is a plethora of websocket libraries for node.js, the most popular seem to be:
https://github.com/Worlize/WebSocket-Node
https://github.com/einaros/ws
https://github.com/LearnBoost/e..
I want to do a condition in an AngularJS template. I fetch a video list from the Youtube API. Some of the videos are in 16:9 ratio and some are in 4:3 ratio.
I want to make a condition like this:
if..
I choose to use "Jenkins's own user database" security realm for user login as I couldn't use LDAP in my company. And Google's OpenID has issue when you decided to change the hostname or port number ..
I have a desktop application with a database embedded in it. When I execute my program I need to check that specific table exists, or create it if not.
Given a Connection object named conn for my dat..
I am looking for a way in LINQ to match the follow SQL Query.
Select max(uid) as uid, Serial_Number from Table Group BY Serial_Number
Really looking for some help on this one. The above query gets..
doStuff(document.getElementById("myCircle1" "myCircle2" "myCircle3" "myCircle4"));
This doesn't work, so do I need a comma or semi-colon to make this work?..
I'm making a Java application with an application-logic-thread and a database-access-thread.
Both of them persist for the entire lifetime of the application and both need to be running at the same tim..
I am trying to use Angular Material Autocomplete component in my Angular 2 project. I added the following to my template.
<md-input-container>
<input mdInput placeholder="Category" [mdAut..
I'd like to know if it's possible to generate a SELECT COUNT(*) FROM TABLE statement in SQLAlchemy without explicitly asking for it with execute().
If I use:
session.query(table).count()
then it gen..
hi can anyone please help me with this fetching from database of int values im having difficulty in fetching int values , it works for varchar but not int can someone help me out please
if (int.TryP..
The following code:
<?php
try {
$dbh = new PDO("mysql:host=$hostname;dbname=$dbname", $username, $password);
echo "Connection is successful!<br/>";
$sql = "SELECT * FROM users";
..
I'm familiar with Unix shell scripting, but new to windows scripting.
I have a list of strings containing str1, str2, str3...str10. I want to do like this:
for string in string_list
do
var = stri..
I've got BroadcastReceiver class:
public class IntentReceiver extends BroadcastReceiver {
final String tag = "Intent Intercepter";
@Override
public void onReceive(Context context, Inten..
What's the simplest way to get an environment variable from a docker container that has not been declared in the Dockerfile?
For instance, an environment variable that has been set through some docke..
I have a div container and have defined its style as follows:
div#tbl-container
{
width: 600px;
overflow: auto;
scrollbar-base-color:#ffeaff
}
This gives me both horizontal and ..
How can I only allow certain characters in a Visual C# textbox? Users should be able to input the following characters into a text box, and everything else should be blocked: 0-9, +, -, /, *, (, ).
I..
How would I go about keeping my header from scrolling with the rest of the page? I thought about utilizing frame-sets and iframes, just wondering if there is a easier and more user friendly way, what ..
function leapYear(year){
var result;
year = parseInt(document.getElementById("isYear").value);
if (years/400){
result = true
}
else if(years/100){
result = false
..
A program logs some message in directory /var/mobile/Containers/Data/Application on iPhone. Is there any way I can get access to this directory without jailbreaking iPhone? If no, is there any directo..
I'm hoping someone here can point me in the right direction - I'm trying to create a fairly robust utility program to read the data from an Excel sheet (may be .xls OR .xlsx) into a DataTable as quick..
I can not locate the correct method to make the first item in a combo box visible.
The app starts with an empty combo box. The user makes a radio box selection then clicks Go! (how original). The com..
I've only just started working with bootstrap and unsure about how to achieve my goal.
I would like the gutters to all be even, like they are in this image:
by default, they look like this, the ve..
I need to redirect to specific url after 5 seconds after putting an error message. First i have used Javascript as below.
document.ready(window.setTimeout(location.href = "https://www.google.co.in",5..
Let's assume an iteration in which we call a function without a return value. The way I think my program should behave is explained in this pseudocode:
for element in some_list:
foo(element)
def..
In SQL Server we can use this:
DECLARE @variable INT;
SELECT @variable= mycolumn from myTable;
How can I do the same in Oracle? I'm currently attempting the following:
DECLARE COMPID VARCHAR2(20);..
Hi I am starting with Web Services in Spring, so I am trying to develop small application in Spring + JSON + Hibernate. I have some problem with HTTP-POST. I created a method:
@RequestMapping(value="..
I am building an application and would like to automatically post to craigslist with a click of a button. Is there any way to do this?
I have an account and will pay for each post...
Would it be possible to construct SQL to concatenate column values from
multiple rows?
The following is an example:
Table A
PID
A
B
C
Table B
PID SEQ Desc
A 1 Have
A 2 ..
What is the proper method to set the focus to a specific field within a dynamically loaded DIV?
$("#display").load("?control=msgs"); // loads the HTML into the DIV
$('#display').fadeIn("fast"); // di..
I am writing a script for customising a configuration file. I want to replace multiple instances of strings within this file, and I tried using PowerShell to do the job.
It works fine for a single re..
When I try to run my application with in-app billing I am getting the error: "This version of the application is not configured for billing through Google Play. Check the help center for more informat..
I had Eclipse Indigo installed on my computer with the Android plugin and it was working perfectly for about two weeks. Today, I updated java and quicktime then restarted my computer. When it booted b..
I'm trying to build a simple API using Flask, in which I now want to read some POSTed JSON. I do the POST with the Postman Chrome extension, and the JSON I POST is simply {"text":"lalala"}. I try to r..
I have a standard Rails3 environment, RVM 1.2.9, Rails 3.0.5, Ruby 1.9.2p180, MySQL2 Gem 0.2.7, mysql-5.5.10-osx10.6-x86_64
Error I get when running rake db:migrate to create database is:
Can't con..
I am on Oracle 10g. In a requirement I need to increase the size of a pl/sql VARCHAR2 variable. It is already at 4000 size. I have read that
in PL/SQL, VARCHAR2 can be up to 32767 bytes. For SQL ..
Final update:
I had forgotten to run the initdb command.
By running this command
ps auxwww | grep postgres
I see that postgres is not running
> ps auxwww | grep postgres
remcat 1789 0...
What is the purpose of Node.js module.exports and how do you use it?
I can't seem to find any information on this, but it appears to be a rather important part of Node.js as I often see it in source c..
I changed the root password to test and now I cannot login in phpMyAdmin page in XAMPP. I looked for help here and here which basically says changed config.inc.php file in XAMPP\PHPMYADMIN folder.
/*..
I am trying to validate the password using regular expression. The password is getting updated if we have all the characters as alphabets. Where am i going wrong ? is the regular expression right ?
f..
I want to open external storage directory path for saving file programatically.I tried but not getting sdcard path.
How can i do this?is there any solution for this??
private File path = new File(Env..
I can't figure out how to get the [X] button into the top right corner of my custom css box.
Here's the result so far:
_x000D_
_x000D_
#wrapper {_x000D_
height: 100px;_x000D_
width: 500px;_x00..
I want to post a file with some JSON data using Spring MVC. So I've developed a rest service as
@RequestMapping(value = "/servicegenerator/wsdl", method = RequestMethod.POST,consumes = { "multipart/m..
Recently in a interview I was asked a very general question "what is abstract in java".I gave the definition and it was followed with some other question on abstract as what is abstract method and dif..
In Java 8, you can use a method reference to filter a stream, for example:
Stream<String> s = ...;
long emptyStrings = s.filter(String::isEmpty).count();
Is there a way to create a method ref..
Say I have a C function which takes a variable number of arguments: How can I call another function which expects a variable number of arguments from inside of it, passing all the arguments that got i..
Is it possible to change the default background color of a select list option on hover?
HTML:
<select id="select">
<option value="1">One</option>
<option value="2">Tw..
I have a div in my php page that uses jQuery to hide it once the page has loaded. But is there a way to hide it from the very start of loadup?
The reason I ask is because for a brief second, you can ..
I want to make a file uploader. And I hence I need a file chooser but I don't want to write this by myself. I find OI file manager and I think it suits me.
But how can I force user to install OI file ..
I want to train a deep network starting with the following layer:
model = Sequential()
model.add(Conv2D(32, 3, 3, input_shape=(32, 32, 3)))
using
history = model.fit_generator(get_training_data()..
Please i need a script that can work with the HTML code bellow to disable/enable the button when a checkbox is checked or unchecked,
<input type="submit" name="sendNewSms" class="inputButton" id=..
I can't compile because of this part in my code:
if command == 'HOWMANY':
opcodegroupr = "A0"
opcoder = "85"
elif command == 'IDENTIFY':
opcodegroupr = "A0"
opcoder = "81"
I have th..
grep is used to search within a file to see if any line matches a given regular expression. However, I have this situation - I want to write a regular expression that will match the filename itself (a..
How do I make plots of a 1-dimensional Gaussian distribution function using the mean and standard deviation parameter values (µ, s) = (-1, 1), (0, 2), and (2, 3)?
I'm new to programming, using Pytho..
I am trying to get to and from date where ToDate will have previous date and FromDate will have first date of the current month. For January it would be 1/1/2013 and so on. How to get the first date o..
I was wondering what is your recommended way to compute the inverse of a matrix?
The ways I found seem not satisfactory. For example,
> c=rbind(c(1, -1/4), c(-1/4, 1))
> c
[,1] [,2..
I have a table with 21638 unique* rows:
vocabulary <- read.table("http://socserv.socsci.mcmaster.ca/jfox/Books/Applied-Regression-2E/datasets/Vocabulary.txt", header=T)
This table has five colum..
How can I call SubGraphButton_Click(object sender, RoutedEventArgs args) from another method?
private void SubGraphButton_Click(object sender, RoutedEventArgs args)
{
}
private void ChildNode_Click..
The opposite of visibility: hidden is visibility: visible. Similarly, is there any opposite for display: none?
Many people become confused figuring out how to show an element when it has display: no..
How do I return 3 separate data values of the same type(Int) from a function in swift?
I'm attempting to return the time of day, I need to return the Hour, Minute and Second as separate integers, but..
Ideally, I would be able to use a program like
find [file or directory name]
to report the paths with matching filenames/directories. Unfortunately this seems to only check the current directory, ..
I am using jQuery in my web application. I want to use arrays, but I am not able to find out functions for arrays (add, remove or append elements in array) in jQuery. Is there any link related to jQue..
I have to download a file from an SFTP server everyday. I have the program which retrieves the file from the server but I was thinking of setting up a cron job (or anything similar) to automate that. ..
It appears my InfoWindow, when you click on the home icon on my Google Maps v3, is not properly auto-sizing to the content of the InfoWindow.
It gives scrollbars when it should not. The InfoWindow sh..
As I'm pretty new to C#, I struggle with the following piece of code. When I click to button 'knop', the method 'klik' has to be executed. The method has to draw the Bitmap 'b', generated by 'DrawMand..
Say I have a Python function that returns multiple values in a tuple:
def func():
return 1, 2
Is there a nice way to ignore one of the results rather than just assigning to a temporary variable..
I'm trying to deploy a WCF service to my server, hosted in IIS. Naturally it works on my machine :)
But when I deploy it, I get the following error:
This collection already contains an
address..
What is the difference between functional and non-functional requirements in the context of designing a software system?
Give examples for each case...
I am about to create a new ASP.Net MVC5 web application. I would like to use a theme from bootswatch or wrapbootstrap in the application, but cannot find a set of instructions on how to do this...
For example, can I take this script (from mozilla tutorial):
<html>
<head>
<script type="application/javascript">
function draw() {
var canvas = document.getElementById..
I have a string in base64 format, which represents PNG image. Is there a way to save this image to the filesystem, as a PNG file?
I encoded the image using flex. Actually this is what I get on serv..
I'm trying to create a circle with CSS, which looks exactly like on the following picture:
...with only one div:
<div class="myCircle"></div>
and by using only CSS definitions. No SV..
In a word press twenty eleven theme. I want to change the size of headings
When I wrap my headings around h1 and h2 tags as follows
<h1>My h1 heading </h1>
<h2> My h2 heading <..
I am trying to set command line arguments in a Netbeans 7.1 Java project on Windows 7 64 bit.
Netbeans is not passing the arguments I give it.
I go to Project --> Properties --> Run --> and type th..
In an Android application, how do you start a new activity (GUI) when a button in another activity is clicked, and how do you pass data between these two activities?..
I have a table with two fields - datetime and int. I want to do a group by on the datetime only on the date ignoring the hour and minute. The SELECT statement should return a date that maps to the sum..
I am trying to call a method of second controller in first controller by using scope variable. This is a method in my first controller:
$scope.initRestId = function(){
var catapp = document.g..
Simulating a button click seems like a very easy/standard operation. Yet, I can't get it to work in Jest.js tests.
This is what I tried (and also doing it using jQuery), but it didn't seem to trigger ..
I have three activities A,B and C where A and B are forms and after filling and saving the form data in database(SQLITE). I am using intent from A to B and then B to C.What i want is that every time I..
I am trying to create a batch (.bat) file for windows XP to do the following:
If (file.txt contains the string 'searchString') then (ECHO found it!)
ELSE(ECHO not found)
So far, I have found a way..
Is there a way to have all links on a page be relative to the root directory?
For example, on www.example.com/fruits/apples/apple.html I could have a link saying:
<a href="fruits/index.html">B..
Under what conditions would one favor apps talking via a message queue instead of via web services (I just mean XML or JSON or YAML or whatever over HTTP here, not any particular type)?
I have to tal..
One frequently finds expressions of this type in python questions on SO. Either for just accessing all items of the iterable
for i in range(len(a)):
print(a[i])
Which is just a clumbersome way ..
Without using string manipulation (checking for an occurrence of the . or , character) by casting the product of an int calculation to string.
and
without using try / catch scenarios relying on err..
I want to get a specific output iterating a Ruby Hash.
This is the Hash I want to iterate over:
hash = {
1 => ['a', 'b'],
2 => ['c'],
3 => ['d', 'e', 'f', 'g'],
4 => ['h']
}
..
How can I configure my (embedded) Tomcat Session Timeout in a Spring Boot Application?
public class SessionListener implements HttpSessionListener{
@Override
public void sessionCreated(HttpSessionEv..
I am trying out the new Microsoft Visual Studio Code editor in Linux Fedora environment. I would like to know how to replace new line (\n) in place of some other text.
For example, I have html text ..
I have a EditText and button aligned to parent's bottom.
When I enter text in it and press the button to save data, the virtual keyboard does not disappear.
Can any one guide me how to hide the keyb..
I am using the following code to fire the iexplore process. This is done in a simple console app.
public static void StartIExplorer()
{
var info = new ProcessStartInfo("iexplore");
info.UseSh..
In C, I did not notice any effect of the extern keyword used before function declaration.
At first, I thought that when defining extern int f(); in a single file forces you to implement it outside of ..
With cURL, we can pass a username with an HTTP web request as follows:
$ curl -u <your_username> https://api.github.com/user
The -u flag accepts a username for authentication, and then cURL ..
I want to declare a variable in SQLite and use it in insert operation.
Like in MS SQL:
declare @name as varchar(10)
set name = 'name'
select * from table where name = @name
For example, I will nee..
I am having a problem importing classes and setting variables and I need help with a test program I am doing. So I am testing out a program that just simply outputs what your input was and puts a time..
In python how can you extend a class? For example if I have
color.py
class Color:
def __init__(self, color):
self.color = color
def getcolor(self):
return self.color
color_..
Based on this answer
Regular Expressions: Is there an AND operator?
I tried the following on http://regexpal.com/ but was unable to get it to work. What am missing? Does javascript not support it?
..
I have a Postgres schema which looks like:
The problem is that whenever I save text longer than 500 characters in the description column I get the error:
value too long for type character varying(..
Using "Import Project" in Android Studio for an Eclipse project used to change the project structure and generate Gradle files, but right now (I'm using AS 0.5.3) it's only generating IDEA files (.iml..
I'm having a hard time understanding why
#include <iostream>
using namespace std;
int fib(int x) {
if (x == 1) {
return 1;
} else {
return fib(x-1)+fib(x-2);
}
}
..
If I've got a multi-level column index:
>>> cols = pd.MultiIndex.from_tuples([("a", "b"), ("a", "c")])
>>> pd.DataFrame([[1,2], [3,4]], columns=cols)
a
---+--
b | c
--..
With the following declaration
int array[ROW][COLUMN]={0};
I get the array with all zeroes but with the following one
int array[ROW][COLUMN]={1};
I don’t get the array with all one value. The..
I need to add the current year as a variable in an SQL statement, how can I retrieve the current year using SQL?
i.e.
BETWEEN
TO_DATE('01/01/**currentYear** 00:00:00', 'DD/MM/YYYY HH24:MI:SS..
What is the correct/best/simplest way to convert a c-style string to a std::string.
The conversion should accept a max_length, and terminate the string at the first \0 char, if this occur before max_..
I want to alter a table column to be nullable. I have used:
ALTER TABLE Merchant_Pending_Functions Modify NumberOfLocations NULL
This gives an error at Modify. What is the correct syntax?..
I have a container that is running the Apache service in the foreground. I would like to be able to access the container from another shell in order to "poke around" inside it and examine the files. A..
I have a text file which contains a table comprised of numbers e.g:
5 10 6
6 20 1
7 30 4
8 40 3
9 23 1
4 13 6
if for example I want the numbers contained only in the second column, how do i extract ..
I am trying to install the Scrapy package (among others) for python using pip. I have tried doing the installation using python 3 and python 2, I have installed/upgraded the setuptools like so: $ pip3..
Possible Duplicate:
How to align a <div> to the middle of the page
I need is to show the content of a web page in the middle of the screen, no matter what screen size it is, big or sm..
this might be one of those days my brain just does not work, or i'm incredibly dumb. i've been trying to copy files (which are actually directories .app, .bundle, etc.) but consistently get an error '..
I have the simplest form possible and all I want to do is echo whatever is written in text box.
HTML:
<form action="" method="post">
<input type="text" name="firstname">
<input ty..
I've been trying to create a simple prototype web application that uses RestSharp to call Rest API.
I've not been able to find one good example of it. Could anyone please share and direct me to right..
I'm trying to create a randomized string in PHP, and I get absolutely no output with this:
<?php
function RandomString()
{
$characters = '0123456789abcdefghijklmnopqrstuvwxyzABCDEF..
The compression algorithm used in zlib is essentially the same as that in gzip and zip. What are gzip and zip? How are they different and how are they same?..
I'm trying to open a page in new tab/window on button click.I tried in the google got this code but its not working.
Can anybody help me with this?
<asp:Button ID="btn" runat="Server" Text="SUBMI..
I've read the global installation documentation for Composer, but it's for *nix systems only:
curl -s https://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/composer
I would..
I would like to set the initial month to an arbitrary month when I call the function to display the calendar.
Say for example the user selects a date last june (June 2011) somewhere else and I want ..
I don't know much about Javascript, and the other questions I found are related to operations on dates, not only getting the information as I need it.
Objective
I wish to get the date as below-forma..
I have a Nexus 4 with Android 4.3 and I am trying to connect the device to a computer with Windows 7 64bit.
I installed the latest drivers and the latest adb version. I think I tried almost everythin..
Go's standard library does not have a function solely intended to check if a file exists or not (like Python's os.path.exists). What is the idiomatic way to do it?..
I have made my plots inline on my Ipython Notebook with "%matplotlib inline."
Now, the plot appears. However, it is very small. Is there a way to make it appear larger using either notebook setting..
Could anyone give an example program that explains Java Threads in a simple way? For example, say I have three threads t1, t2 and t3. I want a code that demonstrates that the threads execute simultane..
I need javascript to add 5 to an integer variable, but instead it treats the variable as a string, so it write out the variable, then add 5 onto the end of the "string". How can I force it to do math ..
i have the following two entities:
1- PlayList:
@OneToMany(fetch = FetchType.EAGER, mappedBy = "playlist", orphanRemoval = true, cascade = CascadeType.ALL)
@OrderBy("adOrder")
private Set<Playl..
I want to be able to create a custom AngularJS service that makes an HTTP 'Get' request when its data object is empty and populates the data object on success.
The next time a call is made to this se..
I am trying to set/get the text of my RichTextBox, but Text is not among list of its properties when I want to get test.Text...
I am using code behind in C# (.net framework 3.5 SP1)
RichTextBox test..
Possible Duplicate:
How to round a number to n decimal places in Java
I am having difficulties rounding a float to two decimal places. I have tried a few methods I have seen on here includ..
I am starting to learn SQL and I have a book that provides a database to work on. These files below are in the directory but the problem is that when I run the query, it gives me this error:
Msg 5..
All hell broke loose after i uninstalled my java 6 and installed java 7 (both jdk and jre). On opening eclipse it gave the error that "No JVM found at.....". So, i explicitly gave the location of java..
I'd like to rename a large number of files within a folder on a WinXP system, preferably using a batch file.
The files are currently named like this:
Vacation2010 001.jpg
Vacation2010 002.jpg
..
MySQL 5.0.45
What is the syntax to alter a table to allow a column to be null, alternately what's wrong with this:
ALTER mytable MODIFY mycolumn varchar(255) null;
I interpreted the manual as jus..