qid int64 1 74.7M | question stringlengths 0 58.3k | date stringlengths 10 10 | metadata list | response_j stringlengths 2 48.3k | response_k stringlengths 2 40.5k |
|---|---|---|---|---|---|
892,262 | I am facing problem in loading data. I have to copy 800,000 rows from one table to another in Oracle database.
I tried for 10,000 rows first but the time it took is not satisfactory. I tried using the "BULK COLLECT" and "INSERT INTO SELECT" clause but for both the cases response time is around 35 minutes. This is not ... | 2009/05/21 | [
"https://Stackoverflow.com/questions/892262",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] | Anirban,
Using an "INSERT INTO SELECT" is the fastest way to populate your table. You may want to extend it with one or two of these hints:
* APPEND: to use direct path loading, circumventing the buffer cache
* PARALLEL: to use parallel processing if your system has multiple cpu's and this is a one-time operation or ... | I would agree with Rob. Insert into () select is the fastest way to do this.
What exactly do you need to do? If you're trying to do a table rename by copying to a new table and then deleting the old, you might be better off doing a table rename:
```
alter table
table
rename to
someothertable;
``` |
892,262 | I am facing problem in loading data. I have to copy 800,000 rows from one table to another in Oracle database.
I tried for 10,000 rows first but the time it took is not satisfactory. I tried using the "BULK COLLECT" and "INSERT INTO SELECT" clause but for both the cases response time is around 35 minutes. This is not ... | 2009/05/21 | [
"https://Stackoverflow.com/questions/892262",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] | Anirban,
Using an "INSERT INTO SELECT" is the fastest way to populate your table. You may want to extend it with one or two of these hints:
* APPEND: to use direct path loading, circumventing the buffer cache
* PARALLEL: to use parallel processing if your system has multiple cpu's and this is a one-time operation or ... | try to drop all indexes/constraints on your destination table and then re-create them after data load.
use `/*+NOLOGGING*/` hint in case you use NOARCHIVELOG mode, or consider to do the backup right after the operation. |
892,262 | I am facing problem in loading data. I have to copy 800,000 rows from one table to another in Oracle database.
I tried for 10,000 rows first but the time it took is not satisfactory. I tried using the "BULK COLLECT" and "INSERT INTO SELECT" clause but for both the cases response time is around 35 minutes. This is not ... | 2009/05/21 | [
"https://Stackoverflow.com/questions/892262",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] | INSERT INTO SELECT is the fastest way to do it.
If possible/necessary, disable all indexes on the target table first.
If you have no existing data in the target table, you can also try CREATE AS SELECT. | try to drop all indexes/constraints on your destination table and then re-create them after data load.
use `/*+NOLOGGING*/` hint in case you use NOARCHIVELOG mode, or consider to do the backup right after the operation. |
892,262 | I am facing problem in loading data. I have to copy 800,000 rows from one table to another in Oracle database.
I tried for 10,000 rows first but the time it took is not satisfactory. I tried using the "BULK COLLECT" and "INSERT INTO SELECT" clause but for both the cases response time is around 35 minutes. This is not ... | 2009/05/21 | [
"https://Stackoverflow.com/questions/892262",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] | INSERT INTO SELECT is the fastest way to do it.
If possible/necessary, disable all indexes on the target table first.
If you have no existing data in the target table, you can also try CREATE AS SELECT. | As with the above, I would recommend the `Insert INTO ... AS select ....` or `CREATE TABLE ... AS SELECT ...` as the fastest way to copy a large volume of data between two tables.
You want to look up the direct-load insert in your oracle documentation. This adds two items to your statements: parallel and nologging. R... |
892,262 | I am facing problem in loading data. I have to copy 800,000 rows from one table to another in Oracle database.
I tried for 10,000 rows first but the time it took is not satisfactory. I tried using the "BULK COLLECT" and "INSERT INTO SELECT" clause but for both the cases response time is around 35 minutes. This is not ... | 2009/05/21 | [
"https://Stackoverflow.com/questions/892262",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] | I would agree with Rob. Insert into () select is the fastest way to do this.
What exactly do you need to do? If you're trying to do a table rename by copying to a new table and then deleting the old, you might be better off doing a table rename:
```
alter table
table
rename to
someothertable;
``` | Is the table you are copying to the same structure as the other table? Does it have data or are you creating a new one? Can you use exp/imp? Exp can be give a query to limit what it exports and then imported into the db. What is the total size of the table you are copying from? If you are copying most of the data from ... |
892,262 | I am facing problem in loading data. I have to copy 800,000 rows from one table to another in Oracle database.
I tried for 10,000 rows first but the time it took is not satisfactory. I tried using the "BULK COLLECT" and "INSERT INTO SELECT" clause but for both the cases response time is around 35 minutes. This is not ... | 2009/05/21 | [
"https://Stackoverflow.com/questions/892262",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] | Anirban,
Using an "INSERT INTO SELECT" is the fastest way to populate your table. You may want to extend it with one or two of these hints:
* APPEND: to use direct path loading, circumventing the buffer cache
* PARALLEL: to use parallel processing if your system has multiple cpu's and this is a one-time operation or ... | INSERT INTO SELECT is the fastest way to do it.
If possible/necessary, disable all indexes on the target table first.
If you have no existing data in the target table, you can also try CREATE AS SELECT. |
892,262 | I am facing problem in loading data. I have to copy 800,000 rows from one table to another in Oracle database.
I tried for 10,000 rows first but the time it took is not satisfactory. I tried using the "BULK COLLECT" and "INSERT INTO SELECT" clause but for both the cases response time is around 35 minutes. This is not ... | 2009/05/21 | [
"https://Stackoverflow.com/questions/892262",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] | I would agree with Rob. Insert into () select is the fastest way to do this.
What exactly do you need to do? If you're trying to do a table rename by copying to a new table and then deleting the old, you might be better off doing a table rename:
```
alter table
table
rename to
someothertable;
``` | As with the above, I would recommend the `Insert INTO ... AS select ....` or `CREATE TABLE ... AS SELECT ...` as the fastest way to copy a large volume of data between two tables.
You want to look up the direct-load insert in your oracle documentation. This adds two items to your statements: parallel and nologging. R... |
892,262 | I am facing problem in loading data. I have to copy 800,000 rows from one table to another in Oracle database.
I tried for 10,000 rows first but the time it took is not satisfactory. I tried using the "BULK COLLECT" and "INSERT INTO SELECT" clause but for both the cases response time is around 35 minutes. This is not ... | 2009/05/21 | [
"https://Stackoverflow.com/questions/892262",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] | INSERT INTO SELECT is the fastest way to do it.
If possible/necessary, disable all indexes on the target table first.
If you have no existing data in the target table, you can also try CREATE AS SELECT. | Is the table you are copying to the same structure as the other table? Does it have data or are you creating a new one? Can you use exp/imp? Exp can be give a query to limit what it exports and then imported into the db. What is the total size of the table you are copying from? If you are copying most of the data from ... |
9,046,596 | I have admin user with following five roles[ROLE\_ADMIN,ROLESWITCHUSER,ROLE\_DOCTOR,ROLE\_USER]
and some **normal users** with only one role i.e ROLE\_USER ,now my question is how can i get only normal users from my secuser table i tried with somne iterations
```
def roleId=SecRole.findByAuthority("ROLE_USER")
userIns... | 2012/01/28 | [
"https://Stackoverflow.com/questions/9046596",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1170646/"
] | One thing that would help is to use hierarchical roles - see section "14 Hierarchical Roles" at <http://grails-plugins.github.com/grails-spring-security-core/docs/manual/> - and then you wouldn't grant `ROLE_USER` to anyone but "real" users. If you define your hierarchy like this:
```
grails.plugins.springsecurity.rol... | Oh, you've choosen really complicated way, can understand your algorhitm :( Maybe this is enough:
```
List selectUserList = userInstance.findAll {
List roles = it.authorities*.authority
return roles.contains('ROLE_USER') && !roles.contains('ROLE_ADMIN')
}
```
I guess you can build `selectUserMap` from this `se... |
42,437,889 | I am unable to read checkbox value in ionic 2
i tried following code
```
<div class="form-group">
<label ></label>
<div *ngFor="let mydata of activity" >
<label>
<input type="checkbox"
name="activity"
... | 2017/02/24 | [
"https://Stackoverflow.com/questions/42437889",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7477025/"
] | All you need to do is to use `.map` and fetch products
```
var product = json.OrderLine.map(function(el){
return {"Product": el.Product, "TotalValue":el.TotalValue, "Quantity":el.Quantity};
});
var rebuild = {
"Message": "string",
"Balance": 0,
"OrderId": 10,
"SiteId": 1234,
"OrderLine": product,
"Cus... | You can access object using key.. Try this
```
var product = $.map(oldJson, function (data, key) {
if (key == "OrderLine") return data;
});
``` |
42,437,889 | I am unable to read checkbox value in ionic 2
i tried following code
```
<div class="form-group">
<label ></label>
<div *ngFor="let mydata of activity" >
<label>
<input type="checkbox"
name="activity"
... | 2017/02/24 | [
"https://Stackoverflow.com/questions/42437889",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7477025/"
] | You can try the following each loop:
```js
var json = {
"Message": "string",
"Balance": 0,
"OrderId": 94,
"SiteId": 1234,
"OrderLine": [{
"Id": "e672f84e-4b97-4cd7-826a-d0e57247ffe3",
"Product": {
"Id": 21,
"Codes": [
"1112"
],
"Sku": "CS1112"... | You can access object using key.. Try this
```
var product = $.map(oldJson, function (data, key) {
if (key == "OrderLine") return data;
});
``` |
39,971,264 | Good Day!
I have a dropdown menu which select employee number and shows table data on basis of that particular selection. I have save as pdf code which saves table data in pdf. It is working fine but my table column headers are only shown not the values.
I have dropdown in one file having javascript which is sent to ... | 2016/10/11 | [
"https://Stackoverflow.com/questions/39971264",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3478450/"
] | You can disable the csrf check on the login uri by editing the `VerifyCsrfToken` class of your Laravel app:
```
class VerifyCsrfToken extends BaseVerifier
{
/**
* The URIs that should be excluded from CSRF verification.
*
* @var array
*/
protected $except = [
'login/*', // Your rout... | If you need to send more information with javascript try this
```
jQuery.support.cors = true;
$.ajax({
url: 'http://192.168.1.78/myproject/login',
type: 'POST',
dataType: dataType,
data: data,
crossDomain: true,
cotentType: YOUR_CONTENT_TYPE,
success: succe... |
2,185,188 | Here is my query:
```
select *
from (select *, 3956 * 2 * ASIN(SQRT(POWER(SIN(RADIANS(45.5200077 - lat)/ 2), 2) + COS(RADIANS(45.5200077)) * COS(RADIANS(lat)) * POWER(SIN(RADIANS(-122.6942014 - lng)/2),2))) AS distance
from stops
order by distance, route asc) as p
group by route, dir
order by di... | 2010/02/02 | [
"https://Stackoverflow.com/questions/2185188",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] | I would suggest that you take a look at Vanilla Forums:
<http://vanillaforums.org/> | I'm biased but I'd recommend looking at Drupal - you seem to want to build a customized system out of existing components and Drupal's module architecture lets you do this quite easily. There are lots of resources on the web for learning how to build community sites with Drupal that a quick Google search will bring up.... |
2,185,188 | Here is my query:
```
select *
from (select *, 3956 * 2 * ASIN(SQRT(POWER(SIN(RADIANS(45.5200077 - lat)/ 2), 2) + COS(RADIANS(45.5200077)) * COS(RADIANS(lat)) * POWER(SIN(RADIANS(-122.6942014 - lng)/2),2))) AS distance
from stops
order by distance, route asc) as p
group by route, dir
order by di... | 2010/02/02 | [
"https://Stackoverflow.com/questions/2185188",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] | I would suggest that you take a look at Vanilla Forums:
<http://vanillaforums.org/> | Pligg, open source, seems pretty useful for features such as voting up and down posts <http://www.pligg.com/about.php> .
BBpress <http://bbpress.org/> , integrates with Wordpress and allows for plug ins.
Also, <https://stackexchange.com/> looks interesting! |
28,207,101 | How to make ListView Item Selection remain stable ?
```
<ListView
android:id="@+id/list_slidermenu"
android:layout_height="0dp"
android:layout_width="match_parent"
android:layout_weight="8"
android:layout_gravity="start"
android:scrollbars="none"
... | 2015/01/29 | [
"https://Stackoverflow.com/questions/28207101",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1859489/"
] | You've to make `getSelectedIndex()` and `setSelectedIndex()` method in your adapter.
```
private int selectedIndex;
public int getSelectedIndex() {
return selectedIndex;
}
public void setSelectedIndex(int index) {
this.selectedIndex = index;
// Re-draw the list by informing the view of the changes
n... | >
> You need to keep track of selected item and accordingly change the background of the list row.
>
>
>
1.Change the selected item's position in item click :
```
@Override
public void onItemSelected(AdapterView<?> arg0, View arg1,int position, long arg3) {
adapter.setSelectedItem(position);
}
```
2.G... |
28,207,101 | How to make ListView Item Selection remain stable ?
```
<ListView
android:id="@+id/list_slidermenu"
android:layout_height="0dp"
android:layout_width="match_parent"
android:layout_weight="8"
android:layout_gravity="start"
android:scrollbars="none"
... | 2015/01/29 | [
"https://Stackoverflow.com/questions/28207101",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1859489/"
] | You've to make `getSelectedIndex()` and `setSelectedIndex()` method in your adapter.
```
private int selectedIndex;
public int getSelectedIndex() {
return selectedIndex;
}
public void setSelectedIndex(int index) {
this.selectedIndex = index;
// Re-draw the list by informing the view of the changes
n... | I have used gradient to make list selection remain stable
gradient\_bg.xml:-
```
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:startColor="#7ecce8"
android:centerColor="#7ecce8"
android:endC... |
28,207,101 | How to make ListView Item Selection remain stable ?
```
<ListView
android:id="@+id/list_slidermenu"
android:layout_height="0dp"
android:layout_width="match_parent"
android:layout_weight="8"
android:layout_gravity="start"
android:scrollbars="none"
... | 2015/01/29 | [
"https://Stackoverflow.com/questions/28207101",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1859489/"
] | I have used gradient to make list selection remain stable
gradient\_bg.xml:-
```
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:startColor="#7ecce8"
android:centerColor="#7ecce8"
android:endC... | >
> You need to keep track of selected item and accordingly change the background of the list row.
>
>
>
1.Change the selected item's position in item click :
```
@Override
public void onItemSelected(AdapterView<?> arg0, View arg1,int position, long arg3) {
adapter.setSelectedItem(position);
}
```
2.G... |
24,624,098 | In Eclipse, I just imported an external `JAR`. Viewing any of the classes in the Package Explorer will instead of showing a source code open a Class File Editor with saying "Source not found". The folder of the JAR I have downloaded, however, has only `JAR`, no `lib`, no `src`, no `docs`.
Is there still a way how to ... | 2014/07/08 | [
"https://Stackoverflow.com/questions/24624098",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1079484/"
] | Try this :
* Download java decompiler from <http://jd.benow.ca/> and now double
click on *jd-gui* and click on open file.
* Then open .jar file from that folder.
* Now you get class files and save all these class files (click on file
then click "save all sources" in jd-gui) by src name. | .jar files don't contain source code but are more like binary files for Java.
You can either get the source code from the projects page (if it is an OpenSource project of course)
An other possible way to view the source code of a .jar file is by using a decompiler (<http://jd.benow.ca/>; Also has a Eclipse plugin I t... |
24,624,098 | In Eclipse, I just imported an external `JAR`. Viewing any of the classes in the Package Explorer will instead of showing a source code open a Class File Editor with saying "Source not found". The folder of the JAR I have downloaded, however, has only `JAR`, no `lib`, no `src`, no `docs`.
Is there still a way how to ... | 2014/07/08 | [
"https://Stackoverflow.com/questions/24624098",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1079484/"
] | .jar files don't contain source code but are more like binary files for Java.
You can either get the source code from the projects page (if it is an OpenSource project of course)
An other possible way to view the source code of a .jar file is by using a decompiler (<http://jd.benow.ca/>; Also has a Eclipse plugin I t... | If possible I suggest you to use Maven for manage dependencies of your project, in most cases it did the trick for you.
See: [Get source JARs from Maven repository](https://stackoverflow.com/questions/2059431/get-source-jars-from-maven-repository) |
24,624,098 | In Eclipse, I just imported an external `JAR`. Viewing any of the classes in the Package Explorer will instead of showing a source code open a Class File Editor with saying "Source not found". The folder of the JAR I have downloaded, however, has only `JAR`, no `lib`, no `src`, no `docs`.
Is there still a way how to ... | 2014/07/08 | [
"https://Stackoverflow.com/questions/24624098",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1079484/"
] | Try this :
* Download java decompiler from <http://jd.benow.ca/> and now double
click on *jd-gui* and click on open file.
* Then open .jar file from that folder.
* Now you get class files and save all these class files (click on file
then click "save all sources" in jd-gui) by src name. | You cannot view the source form a .jar files as it contains binaries.Use a java decompiler instead to decompile the .class files and view their sources. |
24,624,098 | In Eclipse, I just imported an external `JAR`. Viewing any of the classes in the Package Explorer will instead of showing a source code open a Class File Editor with saying "Source not found". The folder of the JAR I have downloaded, however, has only `JAR`, no `lib`, no `src`, no `docs`.
Is there still a way how to ... | 2014/07/08 | [
"https://Stackoverflow.com/questions/24624098",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1079484/"
] | Try this :
* Download java decompiler from <http://jd.benow.ca/> and now double
click on *jd-gui* and click on open file.
* Then open .jar file from that folder.
* Now you get class files and save all these class files (click on file
then click "save all sources" in jd-gui) by src name. | If possible I suggest you to use Maven for manage dependencies of your project, in most cases it did the trick for you.
See: [Get source JARs from Maven repository](https://stackoverflow.com/questions/2059431/get-source-jars-from-maven-repository) |
24,624,098 | In Eclipse, I just imported an external `JAR`. Viewing any of the classes in the Package Explorer will instead of showing a source code open a Class File Editor with saying "Source not found". The folder of the JAR I have downloaded, however, has only `JAR`, no `lib`, no `src`, no `docs`.
Is there still a way how to ... | 2014/07/08 | [
"https://Stackoverflow.com/questions/24624098",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1079484/"
] | You cannot view the source form a .jar files as it contains binaries.Use a java decompiler instead to decompile the .class files and view their sources. | If possible I suggest you to use Maven for manage dependencies of your project, in most cases it did the trick for you.
See: [Get source JARs from Maven repository](https://stackoverflow.com/questions/2059431/get-source-jars-from-maven-repository) |
32,792,299 | I have following route explicitly defined in my routes.rb
```
map.book_preview_v2 '/books/v2/:id', :controller => 'books', :action => 'show_v2'
```
But, in the logs, I see following message:
```
2015-09-25 16:49:04 INFO (session: f561ebeab121cd1c8af38e0482f176b8)
method /books/v2/519869.json (user: xxx:669052) para... | 2015/09/26 | [
"https://Stackoverflow.com/questions/32792299",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/929701/"
] | >
> ActionController::UnknownAction (No action responded to v2. Actions:
> some\_method\_1, some\_method\_2, some\_method\_3, some\_method\_4,
> some\_method\_5, **show\_v2**, some\_method\_6, and some\_method\_7):
>
>
> Why in the logs I see action as "v2" instead of "show\_v2"?
>
>
>
As per the [***Rails 2**... | **UPDATE**
This is how to create [routes](http://guides.rubyonrails.org/v2.3.11/routing.html#regular-routes) for rails v2.3.8
Please revised the routes into.
```
map.connect '/books/v2/:id', :controller => 'books', :action => 'show_v2'
```
I hope It can help you. |
111,729 | In John Carpenter's [*They Live*](https://en.wikipedia.org/wiki/They_Live) we hear the famous line
>
> I have come here to chew bubble gum and kick ass, and I'm all outta bubble gum.
>
>
>
It obviously made it into the general vernacular, but was it ad-libbed by Mr. Piper as some suggest, or did it originate el... | 2015/12/22 | [
"https://scifi.stackexchange.com/questions/111729",
"https://scifi.stackexchange.com",
"https://scifi.stackexchange.com/users/55937/"
] | When asked this directly, Roddy Piper said that he ad-libbed it.
From a 2013 [interview](https://web.archive.org/web/20190831133511/https://my.xfinity.com/blogs/movies/2013/07/17/%E2%80%98rowdy%E2%80%99-roddy-piper-stocked-up-on-bubble-gum-reflects-on-%E2%80%98they-live%E2%80%99/):
>
> Onda: Did you really ad-lib th... | *Five on the Black Hand Side* (1973), 15 years before *They Live* (1988). Timestamp 1:49 in this clip.
>
> I ain’t giving up nothing for bubblegum and hard time, and I’m fresh out of bubblegum.
>
>
>
Not saying this is the original, or that Piper actually had a line. All I'm saying is that this was a saying befor... |
9,019,846 | At the moment I have a MasterPage in an ASP.NET MVC3 project with a animesearch function
```
function AnimeSearch() {
alert(document.getElementById('anime').value);
window.location = "Paging/AnimeBySearch?searchstring=" + (document.getElementById('anime').value);
}
```
Wh... | 2012/01/26 | [
"https://Stackoverflow.com/questions/9019846",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/928867/"
] | ```
function getBaseUrl()
{
return "@Url.Content("~/")";
}
function AnimeSearch(baseUrl) {
alert(document.getElementById('anime').value);
window.location = getGetBaseUrl() + "/Paging/AnimeBySearch?searchstring=" + (document.getElementById('anime').value);
}
``` | i would suggest that you think about a rewrite of the implementation and setup a controller and view that queries the anime model. this controller would implement an action method that allowed for paging and would return a partialview that was emitted into a predefined div on your anime search view. i'm in transit on i... |
2,747,928 | I am working on migrating the ASP.NET apllication to MVC Framework.
I have implemented session timeout for InActiveUser using JQuery idleTimeout plugin.
I have set idletime for 30 min as below in my Master Page. So that After the user session is timedout of 30 Min, an Auto Logout dialog shows for couple of seconds and... | 2010/04/30 | [
"https://Stackoverflow.com/questions/2747928",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/254913/"
] | How about instead of redirecting to a url, you redirect to a javascript function which does whatever you want it to do first, then redirect to the url from within the javascript.
```
function logout() {
alert('You are about to be signed out due to Inactivity');
window.location = '/Account/Logout';
}
$(documen... | Try This [Seesion Alert Using Jquery](http://sumeshparakkat.blogspot.in/2010/11/session-timeout-with-warning-and-jquery.html) from my blog:
* Session set to time out (e.g. 30 minutes).
* When session times out, the user is logged out.
* Display a countdown so the user knows how long is left.
* Inform the user when the... |
3,043,418 | How to handle multiple event in web control using javascript for ex handling onpaste and on keyup event in textarea | 2010/06/15 | [
"https://Stackoverflow.com/questions/3043418",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/400962/"
] | There's no special trick to assigning different event handlers to an element, just define them as you would:
```
var tArea = document.getElementById("myTextArea");
// Define `onpaste` handler - note that Opera doesn't support `onpaste`
tArea.onpaste = function (evt) {
}
// Define `onkeyup` handler
tArea.onkeyup = fu... | You can add as many event handlers as you need to an element.
```
element.addEventListener('event-type', handler1, true);
element.addEventListener('another-type', handler2, true);
element.addEventListener('third-type', handler3, true);
function handler1( e ){}
function handler2( e ){}
function handler3( e ){}
```
O... |
1,624,338 | I have an android application with a LOT of activities, think of something like a book where every page is a new activity. The user can make changes in each activity, for example highlight certain texts with different colored markers etc. and it's crucial that I'll remember this information as long as the application s... | 2009/10/26 | [
"https://Stackoverflow.com/questions/1624338",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/101334/"
] | Try to use startActivity() with flags such as Intent.FLAG\_ACTIVITY\_CLEAR\_TOP.
You could read the full story here:
<http://developer.android.com/reference/android/content/Intent.html#setFlags(int>) | I had exactly the same problem and after I thought and tried a lot, IMHO I found the most feasible solution. I inherited the Activity and adds a static method to kill if exists only. So, instead of killing the activity whenever it exits. I kill it whenever it is called again. For example,
```
MyActivity.killIfExists()... |
319,488 | I'm a software engineer. There are many times when I write a good chunk, or even the entirety of, a feature, but opt not to make it actually run in the program for some reason or another. This code is still there, and could theoretically work, but it never will because it's inaccessible.
What's a good one-word term fo... | 2016/04/14 | [
"https://english.stackexchange.com/questions/319488",
"https://english.stackexchange.com",
"https://english.stackexchange.com/users/51742/"
] | I'm rather thinking of the word **unused**.
Edit: Unused should be understandable for non technical persons. Other possibilities include **unnecessary** (you often see this in change logs, as in *removed unnecessary lines*) or maybe **orphaned** (although I haven't seen this in a real coding situation. It's rather a t... | legacy code, used primarily for informal pseudocode |
319,488 | I'm a software engineer. There are many times when I write a good chunk, or even the entirety of, a feature, but opt not to make it actually run in the program for some reason or another. This code is still there, and could theoretically work, but it never will because it's inaccessible.
What's a good one-word term fo... | 2016/04/14 | [
"https://english.stackexchange.com/questions/319488",
"https://english.stackexchange.com",
"https://english.stackexchange.com/users/51742/"
] | When discussing code or functionality that is either in progress or completed but has not been approved or won't be used, we often use the term
[shelved](http://www.oxforddictionaries.com/us/definition/american_english/shelve)
----------------------------------------------------------------------------------
>
> dec... | legacy code, used primarily for informal pseudocode |
319,488 | I'm a software engineer. There are many times when I write a good chunk, or even the entirety of, a feature, but opt not to make it actually run in the program for some reason or another. This code is still there, and could theoretically work, but it never will because it's inaccessible.
What's a good one-word term fo... | 2016/04/14 | [
"https://english.stackexchange.com/questions/319488",
"https://english.stackexchange.com",
"https://english.stackexchange.com/users/51742/"
] | It's called [**unreachable code**](https://en.wikipedia.org/wiki/Unreachable_code).
"Unreachable code" is different from dead code, dead code is code that when executed will result in no change, for example:
```
x = 5;
/* Dead Code Begin */
x = 6;
x = 5;
/* Dead Code End */
```
Unreachable code however is code that... | [RTCA DO-178C](http://www.rtca.org/store_product.asp?prodid=803) - the standard for safety critical code in aircraft - uses the terms "*dead code*" for code that is never reached in any path through the code. The term "*deactivated code*" is for code that is deliberately never used in a particular configuration, but co... |
319,488 | I'm a software engineer. There are many times when I write a good chunk, or even the entirety of, a feature, but opt not to make it actually run in the program for some reason or another. This code is still there, and could theoretically work, but it never will because it's inaccessible.
What's a good one-word term fo... | 2016/04/14 | [
"https://english.stackexchange.com/questions/319488",
"https://english.stackexchange.com",
"https://english.stackexchange.com/users/51742/"
] | It's called [**unreachable code**](https://en.wikipedia.org/wiki/Unreachable_code).
"Unreachable code" is different from dead code, dead code is code that when executed will result in no change, for example:
```
x = 5;
/* Dead Code Begin */
x = 6;
x = 5;
/* Dead Code End */
```
Unreachable code however is code that... | I would use [inactive](http://www.merriam-webster.com/dictionary/inactive) to indicate that it is not being executed in any existing code path.
From your example:
>
> "This is *inactive* code."
>
>
> "I am going to *activate/deactivate* this code".
>
>
> |
319,488 | I'm a software engineer. There are many times when I write a good chunk, or even the entirety of, a feature, but opt not to make it actually run in the program for some reason or another. This code is still there, and could theoretically work, but it never will because it's inaccessible.
What's a good one-word term fo... | 2016/04/14 | [
"https://english.stackexchange.com/questions/319488",
"https://english.stackexchange.com",
"https://english.stackexchange.com/users/51742/"
] | How about **auxiliary** code (**auxiliary**/**auxiliarize**): something that's useful but unused, held in reserve in case it's needed.
(I also like **vestigial** code, but that's not as good an answer, since it might imply obsoleteness). | I do believe this is called **Dormant Code**, a variant term from **Unreachable code**, because **Unreachable code** is most of the times an error effect as stated above as programming errors in complex conditional branches;
a consequence of the internal transformations performed by an optimizing compiler;
incomplete t... |
319,488 | I'm a software engineer. There are many times when I write a good chunk, or even the entirety of, a feature, but opt not to make it actually run in the program for some reason or another. This code is still there, and could theoretically work, but it never will because it's inaccessible.
What's a good one-word term fo... | 2016/04/14 | [
"https://english.stackexchange.com/questions/319488",
"https://english.stackexchange.com",
"https://english.stackexchange.com/users/51742/"
] | It's called [**unreachable code**](https://en.wikipedia.org/wiki/Unreachable_code).
"Unreachable code" is different from dead code, dead code is code that when executed will result in no change, for example:
```
x = 5;
/* Dead Code Begin */
x = 6;
x = 5;
/* Dead Code End */
```
Unreachable code however is code that... | I would use the word [hidden](https://www.google.com/webhp?ion=1&espv=2&ie=UTF-8#q=define%3A%20hidden):
>
> kept out of sight; concealed.
>
>
> synonyms: concealed, secret, undercover, invisible, unseen, out of sight, closeted, covert; secluded, tucked away; camouflaged, disguised, masked, cloaked
>
>
>
"This f... |
319,488 | I'm a software engineer. There are many times when I write a good chunk, or even the entirety of, a feature, but opt not to make it actually run in the program for some reason or another. This code is still there, and could theoretically work, but it never will because it's inaccessible.
What's a good one-word term fo... | 2016/04/14 | [
"https://english.stackexchange.com/questions/319488",
"https://english.stackexchange.com",
"https://english.stackexchange.com/users/51742/"
] | You might consider ***disabled*** or ***deactivated***:
>
> **disable**: to cause (something) to be unable to work in the normal way
>
> **deactivate**: to make (something) no longer active or effective
>
> definitions from [merriam-](http://www.merriam-webster.com/dictionary/disable)[webster](http://www.merria... | Depends on *why* you disabled it. You could perhaps be more descriptive about why you disabled it rather than looking for a generic "\_\_\_\_ code". Here's a few generic words:
* Disabled
* Unused
* Stashed
And a few specific ones:
* Uncontrolled
* Untested
* Deprecated
* Obsolete
* Non-production ready |
319,488 | I'm a software engineer. There are many times when I write a good chunk, or even the entirety of, a feature, but opt not to make it actually run in the program for some reason or another. This code is still there, and could theoretically work, but it never will because it's inaccessible.
What's a good one-word term fo... | 2016/04/14 | [
"https://english.stackexchange.com/questions/319488",
"https://english.stackexchange.com",
"https://english.stackexchange.com/users/51742/"
] | [RTCA DO-178C](http://www.rtca.org/store_product.asp?prodid=803) - the standard for safety critical code in aircraft - uses the terms "*dead code*" for code that is never reached in any path through the code. The term "*deactivated code*" is for code that is deliberately never used in a particular configuration, but co... | My view is that such code should not exist in the code base and is a code or process smell.
>
> This is **cluttering** code. I am going to **clutter up the codebase with** this code.
>
>
> |
319,488 | I'm a software engineer. There are many times when I write a good chunk, or even the entirety of, a feature, but opt not to make it actually run in the program for some reason or another. This code is still there, and could theoretically work, but it never will because it's inaccessible.
What's a good one-word term fo... | 2016/04/14 | [
"https://english.stackexchange.com/questions/319488",
"https://english.stackexchange.com",
"https://english.stackexchange.com/users/51742/"
] | Since the code is inaccessible, most compilers will eliminate it through *[Dead Code Elimination](http://www.compileroptimizations.com/category/dead_code_elimination.htm)*, or *DCE*. So you can refer to it as *dead code*, or simply *dead*.
Nullstone's compendium of [compiler optimizations](http://www.compileroptimizat... | How about **auxiliary** code (**auxiliary**/**auxiliarize**): something that's useful but unused, held in reserve in case it's needed.
(I also like **vestigial** code, but that's not as good an answer, since it might imply obsoleteness). |
319,488 | I'm a software engineer. There are many times when I write a good chunk, or even the entirety of, a feature, but opt not to make it actually run in the program for some reason or another. This code is still there, and could theoretically work, but it never will because it's inaccessible.
What's a good one-word term fo... | 2016/04/14 | [
"https://english.stackexchange.com/questions/319488",
"https://english.stackexchange.com",
"https://english.stackexchange.com/users/51742/"
] | **moth-balled**
verb (used with object)
2. to put into storage or reserve; inactivate.
adjective
3. inactive; unused; stored away: | Depends on *why* you disabled it. You could perhaps be more descriptive about why you disabled it rather than looking for a generic "\_\_\_\_ code". Here's a few generic words:
* Disabled
* Unused
* Stashed
And a few specific ones:
* Uncontrolled
* Untested
* Deprecated
* Obsolete
* Non-production ready |
29,083,343 | I'm trying to search in an database for records with a specific date. I've tried to search in the following ways:
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE=01/01/2015
```
and
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE='01/01/2015'
```
I'm working with an Access database, and in the table, the dates are showing in ... | 2015/03/16 | [
"https://Stackoverflow.com/questions/29083343",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4344054/"
] | Try using CDATE function on your filter:
```
WHERE CAL_DATE = CDATE('01/01/2015')
```
This will ensure that your input is of date datatype, not a string. | SELECT \* from Table1 WHERE (CDATE(ColumnDate) BETWEEN #03/26/2015# AND #03/19/2015#)
if this works .. vote for it.. we use above query for searching records from 26th march to 19 the march.. change the dates accordingly.. |
29,083,343 | I'm trying to search in an database for records with a specific date. I've tried to search in the following ways:
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE=01/01/2015
```
and
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE='01/01/2015'
```
I'm working with an Access database, and in the table, the dates are showing in ... | 2015/03/16 | [
"https://Stackoverflow.com/questions/29083343",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4344054/"
] | Any of the options below should work:
Format the date directly in your query.
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE=#01/01/2015#;
```
The DateValue function will convert a string to a date.
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE=DateValue('01/01/2015');
```
The CDate function will convert a value to a dat... | Try using CDATE function on your filter:
```
WHERE CAL_DATE = CDATE('01/01/2015')
```
This will ensure that your input is of date datatype, not a string. |
29,083,343 | I'm trying to search in an database for records with a specific date. I've tried to search in the following ways:
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE=01/01/2015
```
and
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE='01/01/2015'
```
I'm working with an Access database, and in the table, the dates are showing in ... | 2015/03/16 | [
"https://Stackoverflow.com/questions/29083343",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4344054/"
] | SELECT \* from Table1 WHERE (CDATE(ColumnDate) BETWEEN #03/26/2015# AND #03/19/2015#)
if this works .. vote for it.. we use above query for searching records from 26th march to 19 the march.. change the dates accordingly.. | SELECT \* from Table1 WHERE (CDATE(ColumnDate) BETWEEN #03/26/2015# AND #03/19/2015#)
if this works .. vote for it.. we use above query for searching records from 26th march to 19 the march.. change the dates accordingly.. |
29,083,343 | I'm trying to search in an database for records with a specific date. I've tried to search in the following ways:
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE=01/01/2015
```
and
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE='01/01/2015'
```
I'm working with an Access database, and in the table, the dates are showing in ... | 2015/03/16 | [
"https://Stackoverflow.com/questions/29083343",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4344054/"
] | Any of the options below should work:
Format the date directly in your query.
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE=#01/01/2015#;
```
The DateValue function will convert a string to a date.
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE=DateValue('01/01/2015');
```
The CDate function will convert a value to a dat... | SELECT \* from Table1 WHERE (CDATE(ColumnDate) BETWEEN #03/26/2015# AND #03/19/2015#)
if this works .. vote for it.. we use above query for searching records from 26th march to 19 the march.. change the dates accordingly.. |
29,083,343 | I'm trying to search in an database for records with a specific date. I've tried to search in the following ways:
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE=01/01/2015
```
and
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE='01/01/2015'
```
I'm working with an Access database, and in the table, the dates are showing in ... | 2015/03/16 | [
"https://Stackoverflow.com/questions/29083343",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4344054/"
] | Any of the options below should work:
Format the date directly in your query.
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE=#01/01/2015#;
```
The DateValue function will convert a string to a date.
```
SELECT *
FROM TABLE_1
WHERE CAL_DATE=DateValue('01/01/2015');
```
The CDate function will convert a value to a dat... | SELECT \* from Table1 WHERE (CDATE(ColumnDate) BETWEEN #03/26/2015# AND #03/19/2015#)
if this works .. vote for it.. we use above query for searching records from 26th march to 19 the march.. change the dates accordingly.. |
70,932 | i am an CS student and i got an job-offer as an Linux Administrator.
I took this job to get deeper into Linux in order to understand and use Linux more wise.
So :
Do you have any suggestions (books,links) to Linux System Administration.
For Example : installing software over ssh , creating a mailinglist, installing a... | 2009/10/02 | [
"https://serverfault.com/questions/70932",
"https://serverfault.com",
"https://serverfault.com/users/12792/"
] | I keep the following two books on my shelf. When new editions come out I buy them.
Essential System Administration by Frisch; O'Reilly
Running Linux by Dalheimer;et.al.; O'Reilly
The Frisch book covers more than Linux. Multiple Unix variants are covered.
---
Unix Shell Programming by Kochan; Sams
Is adequate. Som... | [Linux from Scratch](http://www.linuxfromscratch.org/) will teach you everything you wanted to know about Linux, and the stuff you were too afraid to ask about. |
70,932 | i am an CS student and i got an job-offer as an Linux Administrator.
I took this job to get deeper into Linux in order to understand and use Linux more wise.
So :
Do you have any suggestions (books,links) to Linux System Administration.
For Example : installing software over ssh , creating a mailinglist, installing a... | 2009/10/02 | [
"https://serverfault.com/questions/70932",
"https://serverfault.com",
"https://serverfault.com/users/12792/"
] | As well as linux nitty gritty,I think getting meta about system administration is not just useful, but needed.
Technical knowledge is needed, but soft skills, organizational and operational context and processes place it in perspective.
try Mark Burgess' ["Principles of System and Network Admnistration"](http://rads.... | I keep the following two books on my shelf. When new editions come out I buy them.
Essential System Administration by Frisch; O'Reilly
Running Linux by Dalheimer;et.al.; O'Reilly
The Frisch book covers more than Linux. Multiple Unix variants are covered.
---
Unix Shell Programming by Kochan; Sams
Is adequate. Som... |
70,932 | i am an CS student and i got an job-offer as an Linux Administrator.
I took this job to get deeper into Linux in order to understand and use Linux more wise.
So :
Do you have any suggestions (books,links) to Linux System Administration.
For Example : installing software over ssh , creating a mailinglist, installing a... | 2009/10/02 | [
"https://serverfault.com/questions/70932",
"https://serverfault.com",
"https://serverfault.com/users/12792/"
] | I can very highly recommend the [Linux Administration Handbook](http://rads.stackoverflow.com/amzn/click/0131480049).
Also, see the answers to [this question](https://serverfault.com/questions/1046/what-is-the-single-most-influential-book-every-sysadmin-should-read).
And commit the contents of [BashFAQ](http://mywiki... | [Linux from Scratch](http://www.linuxfromscratch.org/) will teach you everything you wanted to know about Linux, and the stuff you were too afraid to ask about. |
70,932 | i am an CS student and i got an job-offer as an Linux Administrator.
I took this job to get deeper into Linux in order to understand and use Linux more wise.
So :
Do you have any suggestions (books,links) to Linux System Administration.
For Example : installing software over ssh , creating a mailinglist, installing a... | 2009/10/02 | [
"https://serverfault.com/questions/70932",
"https://serverfault.com",
"https://serverfault.com/users/12792/"
] | [How Linux Works](http://rads.stackoverflow.com/amzn/click/1593270356) on No Starch Press is a fantastic introduction to Linux administration. | [Linux from Scratch](http://www.linuxfromscratch.org/) will teach you everything you wanted to know about Linux, and the stuff you were too afraid to ask about. |
70,932 | i am an CS student and i got an job-offer as an Linux Administrator.
I took this job to get deeper into Linux in order to understand and use Linux more wise.
So :
Do you have any suggestions (books,links) to Linux System Administration.
For Example : installing software over ssh , creating a mailinglist, installing a... | 2009/10/02 | [
"https://serverfault.com/questions/70932",
"https://serverfault.com",
"https://serverfault.com/users/12792/"
] | I like [The linux Documentation Project](http://www.tldp.org) for basic information. Although the entry I go to most on that site is [The Advanced Bash Scripting Guide](http://www.tldp.org/LDP/abs/html/index.html). I've also found that google is your friend when it comes to man pages `man <command>` in google will gene... | I keep the following two books on my shelf. When new editions come out I buy them.
Essential System Administration by Frisch; O'Reilly
Running Linux by Dalheimer;et.al.; O'Reilly
The Frisch book covers more than Linux. Multiple Unix variants are covered.
---
Unix Shell Programming by Kochan; Sams
Is adequate. Som... |
70,932 | i am an CS student and i got an job-offer as an Linux Administrator.
I took this job to get deeper into Linux in order to understand and use Linux more wise.
So :
Do you have any suggestions (books,links) to Linux System Administration.
For Example : installing software over ssh , creating a mailinglist, installing a... | 2009/10/02 | [
"https://serverfault.com/questions/70932",
"https://serverfault.com",
"https://serverfault.com/users/12792/"
] | As well as linux nitty gritty,I think getting meta about system administration is not just useful, but needed.
Technical knowledge is needed, but soft skills, organizational and operational context and processes place it in perspective.
try Mark Burgess' ["Principles of System and Network Admnistration"](http://rads.... | [Linux from Scratch](http://www.linuxfromscratch.org/) will teach you everything you wanted to know about Linux, and the stuff you were too afraid to ask about. |
70,932 | i am an CS student and i got an job-offer as an Linux Administrator.
I took this job to get deeper into Linux in order to understand and use Linux more wise.
So :
Do you have any suggestions (books,links) to Linux System Administration.
For Example : installing software over ssh , creating a mailinglist, installing a... | 2009/10/02 | [
"https://serverfault.com/questions/70932",
"https://serverfault.com",
"https://serverfault.com/users/12792/"
] | I keep the following two books on my shelf. When new editions come out I buy them.
Essential System Administration by Frisch; O'Reilly
Running Linux by Dalheimer;et.al.; O'Reilly
The Frisch book covers more than Linux. Multiple Unix variants are covered.
---
Unix Shell Programming by Kochan; Sams
Is adequate. Som... | Have a look at the [how2forge](http://www.howtoforge.com/) for basic lamp functions
or maybe if Redhat/Centos/fedora is your thing [RHCT/e](http://www.redhat.com/certification/rhce/)
or maybe a Comptia [Linux+](http://www.comptia.org/certifications/listed/linux.aspx)
don't really know what your background is so basi... |
70,932 | i am an CS student and i got an job-offer as an Linux Administrator.
I took this job to get deeper into Linux in order to understand and use Linux more wise.
So :
Do you have any suggestions (books,links) to Linux System Administration.
For Example : installing software over ssh , creating a mailinglist, installing a... | 2009/10/02 | [
"https://serverfault.com/questions/70932",
"https://serverfault.com",
"https://serverfault.com/users/12792/"
] | [How Linux Works](http://rads.stackoverflow.com/amzn/click/1593270356) on No Starch Press is a fantastic introduction to Linux administration. | I keep the following two books on my shelf. When new editions come out I buy them.
Essential System Administration by Frisch; O'Reilly
Running Linux by Dalheimer;et.al.; O'Reilly
The Frisch book covers more than Linux. Multiple Unix variants are covered.
---
Unix Shell Programming by Kochan; Sams
Is adequate. Som... |
70,932 | i am an CS student and i got an job-offer as an Linux Administrator.
I took this job to get deeper into Linux in order to understand and use Linux more wise.
So :
Do you have any suggestions (books,links) to Linux System Administration.
For Example : installing software over ssh , creating a mailinglist, installing a... | 2009/10/02 | [
"https://serverfault.com/questions/70932",
"https://serverfault.com",
"https://serverfault.com/users/12792/"
] | I know that you asked for books, but since you desire to learn...
One of the best learning tools that you'll find is a good virtual machine manager, such as VMWare or VirtualBox. You can set up a complete virtual learning environment right on your pc, and experiment without the worry of making a mistake in a productio... | I can very highly recommend the [Linux Administration Handbook](http://rads.stackoverflow.com/amzn/click/0131480049).
Also, see the answers to [this question](https://serverfault.com/questions/1046/what-is-the-single-most-influential-book-every-sysadmin-should-read).
And commit the contents of [BashFAQ](http://mywiki... |
70,932 | i am an CS student and i got an job-offer as an Linux Administrator.
I took this job to get deeper into Linux in order to understand and use Linux more wise.
So :
Do you have any suggestions (books,links) to Linux System Administration.
For Example : installing software over ssh , creating a mailinglist, installing a... | 2009/10/02 | [
"https://serverfault.com/questions/70932",
"https://serverfault.com",
"https://serverfault.com/users/12792/"
] | I like [The linux Documentation Project](http://www.tldp.org) for basic information. Although the entry I go to most on that site is [The Advanced Bash Scripting Guide](http://www.tldp.org/LDP/abs/html/index.html). I've also found that google is your friend when it comes to man pages `man <command>` in google will gene... | I know that you asked for books, but since you desire to learn...
One of the best learning tools that you'll find is a good virtual machine manager, such as VMWare or VirtualBox. You can set up a complete virtual learning environment right on your pc, and experiment without the worry of making a mistake in a productio... |
42,491,374 | My problem is when I try to add margin bottom to all elements of columns:2 list, i've added margin-bottom:5px for spacing but for some reason it doubles the spacing. One in the third element bottom and the fourth element top (which gives me the problem)

Is there any solutio... | 2017/02/27 | [
"https://Stackoverflow.com/questions/42491374",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3157171/"
] | I have just hit this bug in Chrome.
With a little investigation, it seems the bottom of the last `<li>` in the first column gets placed at the top of the 2nd column.
[](https://i.stack.imgur.com/BtN4T.jpg)
The solution was to apply the follwing to the `<li>`'s:... | Actually it was bug inside an old version of Chrome.
I tried Firefox and Chrome current versions; neither of them had this problem. |
42,491,374 | My problem is when I try to add margin bottom to all elements of columns:2 list, i've added margin-bottom:5px for spacing but for some reason it doubles the spacing. One in the third element bottom and the fourth element top (which gives me the problem)

Is there any solutio... | 2017/02/27 | [
"https://Stackoverflow.com/questions/42491374",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3157171/"
] | I have just hit this bug in Chrome.
With a little investigation, it seems the bottom of the last `<li>` in the first column gets placed at the top of the 2nd column.
[](https://i.stack.imgur.com/BtN4T.jpg)
The solution was to apply the follwing to the `<li>`'s:... | I recently had a similar issue too and the solution is in MDN [docs](https://developer.mozilla.org/en-US/docs/Web/CSS/break-inside).
```
.card {
break-inside: avoid;
page-break-inside: avoid;
}
```
And an example from [MDN](https://developer.mozilla.org/en-US/docs/Learn/CSS/CSS_layout/Multiple-column_Layout). |
26,350,212 | I am trying to generate a random sequence from a fixed number of characters that contains at least one of each character.
For example having the ensemble
`m = letters[1:3]`
I would like to create a sequence of N = 10 elements that contain at least one of each `m` characters, like
```
a
a
a
a
b
c
c
c
c
a
```
I ... | 2014/10/13 | [
"https://Stackoverflow.com/questions/26350212",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3036416/"
] | ```
f <- function(x, n){
sample(c(x, sample(m, n-length(x), replace=TRUE)))
}
f(letters[1:3], 5)
# [1] "a" "c" "a" "b" "a"
f(letters[1:3], 5)
# [1] "a" "a" "b" "b" "c"
f(letters[1:3], 5)
# [1] "a" "a" "b" "c" "a"
f(letters[1:3], 5)
# [1] "b" "c" "b" "c" "a"
``` | Josh O'Briens answer is a good way to do it but doesn't provide much input checking. Since I already wrote it might as well present my answer. It's pretty much the same thing but takes care of checking things like only considering unique items and making sure there are enough unique items to guarantee you get at least ... |
4,981,526 | For a project I'm working on, a stopwatch-like timer needs to be displayed to the form. If I remember correctly in VB, text could be outputted to a picture box, but I can't find a way to do it in c#. A label would work, if there is a way to prevent the resizing of the box. Thanks. | 2011/02/13 | [
"https://Stackoverflow.com/questions/4981526",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/614479/"
] | A Label would probably be the simplest option. I'm not sure why you would need to prevent resizing of the picturebox (which is also simple to do).
If you are worried about your picturebox being resized and your Label no longer being centered, or being the wrong size, you can just put code in the resize event which dy... | Using a TextBox is probably the most appropriate thing for this; just set `ReadOnly` to true. |
66,251,664 | I am trying to make a stock bot that checks if something is in stock and when I try to use:
`if ATC.isDisplayed():`
I get the error:
`AttributeError: 'list' object has no attribute 'isDisplayed'`
My whole code:
```
import time
import asyncio
import colorama
import subprocess
from colorama import Fore, Back, Style
... | 2021/02/17 | [
"https://Stackoverflow.com/questions/66251664",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/15231411/"
] | For solution, simple make this:
On models
```py
db = SQLAlchemy() #Remove the app here
```
On app
```py
from models import db
db.init_app(app) #Add this line Before migrate line
migrate = Migrate(app, db)
``` | I was able to find a workaround. In my models.py I substituted this line:
```
from app import app as app
```
for this:
```
try:
from app import app as app
except ImportError:
from __main__ import app
```
It works but it's ugly. I thought there must be a prettier way to do this. |
66,251,664 | I am trying to make a stock bot that checks if something is in stock and when I try to use:
`if ATC.isDisplayed():`
I get the error:
`AttributeError: 'list' object has no attribute 'isDisplayed'`
My whole code:
```
import time
import asyncio
import colorama
import subprocess
from colorama import Fore, Back, Style
... | 2021/02/17 | [
"https://Stackoverflow.com/questions/66251664",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/15231411/"
] | For solution, simple make this:
On models
```py
db = SQLAlchemy() #Remove the app here
```
On app
```py
from models import db
db.init_app(app) #Add this line Before migrate line
migrate = Migrate(app, db)
``` | Try to change app import in models.py to:
```py
from flask import current_app as app
``` |
66,251,664 | I am trying to make a stock bot that checks if something is in stock and when I try to use:
`if ATC.isDisplayed():`
I get the error:
`AttributeError: 'list' object has no attribute 'isDisplayed'`
My whole code:
```
import time
import asyncio
import colorama
import subprocess
from colorama import Fore, Back, Style
... | 2021/02/17 | [
"https://Stackoverflow.com/questions/66251664",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/15231411/"
] | I was able to find a workaround. In my models.py I substituted this line:
```
from app import app as app
```
for this:
```
try:
from app import app as app
except ImportError:
from __main__ import app
```
It works but it's ugly. I thought there must be a prettier way to do this. | Try to change app import in models.py to:
```py
from flask import current_app as app
``` |
41,005,412 | When using the pickle lib with some classes that i have created, the output is fairly easily readable to the user. For example, if i have a fill called saves, and save all my class data into a .save file inside it, when opening the file with a text editor, you can vaguely see all the variables and without too much stru... | 2016/12/06 | [
"https://Stackoverflow.com/questions/41005412",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4440588/"
] | Instead of trying to make your data *unreadable*, you could simply sign the data and then authenticate it when read.
### Saving
Here use [`hmac`](https://docs.python.org/3/library/hmac.html) to compute a hash. We then save the hash along with the data:
```
import hmac, pickle
# pickle the data
pickled = pickle.dump... | One idea to obfuscate just a little bit is a simple hex conversion or an encoding of your choosing. For hex I'd do (+12 is random noise I guess)
```
mylist_obf = map(lambda item:int(item.encode('hex'))+12,mylist)
```
Get the original back by doing the reverse
```
my_original_list = map(lambda item: str(int(item)-12... |
22,322,038 | I've a c application that uses a remote axis web service, when I connect to service using http protocol there is no problem, but when I want to use ssl, I can't call service operations & it just returns NULL.
here is part of my axis2.xml for client application:
```
<transportReceiver name="http" class="axis2_http_... | 2014/03/11 | [
"https://Stackoverflow.com/questions/22322038",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/183652/"
] | Delete the folder "D:\WORK\target\tomcat\" and try again, the tomcat-maven-plugin would re-create this folder and the file "tomcat-users.xml". | Create a file for Tomcat users in:
```
D:\WORK\target\tomcat\conf\tomcat-users.xml
```
and add the following:
```
<?xml version="1.0" encoding="UTF-8"?>
<tomcat-users>
<role rolename="tomcat"/>
<role rolename="admin"/>
<role rolename="manager"/>
<user username="admin" password="admin" roles="tomcat,admin,manag... |
22,322,038 | I've a c application that uses a remote axis web service, when I connect to service using http protocol there is no problem, but when I want to use ssl, I can't call service operations & it just returns NULL.
here is part of my axis2.xml for client application:
```
<transportReceiver name="http" class="axis2_http_... | 2014/03/11 | [
"https://Stackoverflow.com/questions/22322038",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/183652/"
] | Create a file for Tomcat users in:
```
D:\WORK\target\tomcat\conf\tomcat-users.xml
```
and add the following:
```
<?xml version="1.0" encoding="UTF-8"?>
<tomcat-users>
<role rolename="tomcat"/>
<role rolename="admin"/>
<role rolename="manager"/>
<user username="admin" password="admin" roles="tomcat,admin,manag... | 1. Use tomcat maven plugin, start the web application
2. Rebuild the project
3. Restart tomcat maven plugin.
4. The error must occur
**Solution:** Before rebuilding the project, you must stop tomcat maven plugin first. |
22,322,038 | I've a c application that uses a remote axis web service, when I connect to service using http protocol there is no problem, but when I want to use ssl, I can't call service operations & it just returns NULL.
here is part of my axis2.xml for client application:
```
<transportReceiver name="http" class="axis2_http_... | 2014/03/11 | [
"https://Stackoverflow.com/questions/22322038",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/183652/"
] | Delete the folder "D:\WORK\target\tomcat\" and try again, the tomcat-maven-plugin would re-create this folder and the file "tomcat-users.xml". | 1. Use tomcat maven plugin, start the web application
2. Rebuild the project
3. Restart tomcat maven plugin.
4. The error must occur
**Solution:** Before rebuilding the project, you must stop tomcat maven plugin first. |
8,574,968 | I am creating Google integrated asp.net Application. i want to retrieve all the information
of a friend of logged in user in gmail. I got the list of contacts in gridview. But I am
not able to get the profile pic of any contact. I am adding datacolumns dynamically in the
gridview.
Here is my code of retrieving ... | 2011/12/20 | [
"https://Stackoverflow.com/questions/8574968",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1099303/"
] | The following code works fine for me:
```
public static List<ContactDetail> GetAllContact(string username, string password)
{
List<ContactDetail> contactDetails = new List<ContactDetail>();
ContactsQuery query = new ContactsQuery(ContactsQuery.CreateContactsUri("default"));
RequestSettings rs = new Request... | I Have managed to successfully retrieve photographs using the GData Library. Photographs are returned as a stream.
The following code retrieves the stream
```
requestFactory = new GOAuthRequestFactory("c1", ApplicationName, parameters);
service = new ContactsService(ApplicationName);
... |
39,131,713 | I'd like to know why ternary conditional-statements like these:
`on_actu.boolean ? IMG1 = "on-actu.png" : IMG1 = "off-actu.png";`
give me the following JSLint error :
>
> expected an assignment or function call and instead saw an expression
>
>
> | 2016/08/24 | [
"https://Stackoverflow.com/questions/39131713",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6524096/"
] | You're using the ternary operator wrong.
```
ValueToAssign = BooleanConditional ? valueOne : valueTwo;
```
More information here: <https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Conditional_Operator> | On the left you can specify variable to which you are setting value, and on the right the actual value;
```
IMG1 = on_actu.boolean ? "on-actu.png" : "off-actu.png";
``` |
39,131,713 | I'd like to know why ternary conditional-statements like these:
`on_actu.boolean ? IMG1 = "on-actu.png" : IMG1 = "off-actu.png";`
give me the following JSLint error :
>
> expected an assignment or function call and instead saw an expression
>
>
> | 2016/08/24 | [
"https://Stackoverflow.com/questions/39131713",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6524096/"
] | You're using the ternary operator wrong.
```
ValueToAssign = BooleanConditional ? valueOne : valueTwo;
```
More information here: <https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Conditional_Operator> | You should use this example
```
var IMG1 = on_actu.boolean ? "on-actu.png" : "off-actu.png";
```
Regars |
39,131,713 | I'd like to know why ternary conditional-statements like these:
`on_actu.boolean ? IMG1 = "on-actu.png" : IMG1 = "off-actu.png";`
give me the following JSLint error :
>
> expected an assignment or function call and instead saw an expression
>
>
> | 2016/08/24 | [
"https://Stackoverflow.com/questions/39131713",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6524096/"
] | On the left you can specify variable to which you are setting value, and on the right the actual value;
```
IMG1 = on_actu.boolean ? "on-actu.png" : "off-actu.png";
``` | You should use this example
```
var IMG1 = on_actu.boolean ? "on-actu.png" : "off-actu.png";
```
Regars |
66,842,297 | I have a function like so:
```
const x = y(callback);
x();
```
It may be called with a synchronous or asynchronous callback:
```
const a = y(() => 42);
const b = y(async () => Promise.resolve(42));
```
The function `y` should take a callback, that can be synchronous or asynchronous. Is it possible to catch a thro... | 2021/03/28 | [
"https://Stackoverflow.com/questions/66842297",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2483271/"
] | An async function also emits a promise, you might consider to also wrap the async inside a promise, which on resolution emits the value | Well you can do something like this by making all your code async... If I get your problem right.
UPD: understand the problem, here is my approach
```js
(async () => {
// Run fn
const fn = callback => {
return new Promise(async (resolve, reject) => {
const res = await callback().catch(err => reject(e... |
66,842,297 | I have a function like so:
```
const x = y(callback);
x();
```
It may be called with a synchronous or asynchronous callback:
```
const a = y(() => 42);
const b = y(async () => Promise.resolve(42));
```
The function `y` should take a callback, that can be synchronous or asynchronous. Is it possible to catch a thro... | 2021/03/28 | [
"https://Stackoverflow.com/questions/66842297",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2483271/"
] | Realised that it's not necessary to chain the `catch` immediately! So the following abomination allows me to determine if it is a promise and handle the error accordingly:
```
const y = (error, callback) => function () {
try {
const returnValue = callback(...arguments);
if (returnValue instanceof Promise) {... | An async function also emits a promise, you might consider to also wrap the async inside a promise, which on resolution emits the value |
66,842,297 | I have a function like so:
```
const x = y(callback);
x();
```
It may be called with a synchronous or asynchronous callback:
```
const a = y(() => 42);
const b = y(async () => Promise.resolve(42));
```
The function `y` should take a callback, that can be synchronous or asynchronous. Is it possible to catch a thro... | 2021/03/28 | [
"https://Stackoverflow.com/questions/66842297",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2483271/"
] | Realised that it's not necessary to chain the `catch` immediately! So the following abomination allows me to determine if it is a promise and handle the error accordingly:
```
const y = (error, callback) => function () {
try {
const returnValue = callback(...arguments);
if (returnValue instanceof Promise) {... | Well you can do something like this by making all your code async... If I get your problem right.
UPD: understand the problem, here is my approach
```js
(async () => {
// Run fn
const fn = callback => {
return new Promise(async (resolve, reject) => {
const res = await callback().catch(err => reject(e... |
66,842,297 | I have a function like so:
```
const x = y(callback);
x();
```
It may be called with a synchronous or asynchronous callback:
```
const a = y(() => 42);
const b = y(async () => Promise.resolve(42));
```
The function `y` should take a callback, that can be synchronous or asynchronous. Is it possible to catch a thro... | 2021/03/28 | [
"https://Stackoverflow.com/questions/66842297",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2483271/"
] | You can use `async/await` notation here.
Await will work with both synchronous and asnychronous functions.
Try to do:
```js
async function init() {
const x = y( async () => await callback() );
try {
await x();
}
catch(error) {
/.../
}
}
```
and your function can be simplified now to:
```js
const... | Well you can do something like this by making all your code async... If I get your problem right.
UPD: understand the problem, here is my approach
```js
(async () => {
// Run fn
const fn = callback => {
return new Promise(async (resolve, reject) => {
const res = await callback().catch(err => reject(e... |
66,842,297 | I have a function like so:
```
const x = y(callback);
x();
```
It may be called with a synchronous or asynchronous callback:
```
const a = y(() => 42);
const b = y(async () => Promise.resolve(42));
```
The function `y` should take a callback, that can be synchronous or asynchronous. Is it possible to catch a thro... | 2021/03/28 | [
"https://Stackoverflow.com/questions/66842297",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2483271/"
] | Realised that it's not necessary to chain the `catch` immediately! So the following abomination allows me to determine if it is a promise and handle the error accordingly:
```
const y = (error, callback) => function () {
try {
const returnValue = callback(...arguments);
if (returnValue instanceof Promise) {... | You can use `async/await` notation here.
Await will work with both synchronous and asnychronous functions.
Try to do:
```js
async function init() {
const x = y( async () => await callback() );
try {
await x();
}
catch(error) {
/.../
}
}
```
and your function can be simplified now to:
```js
const... |
28,862,708 | i have a bunch of nested HTML elements, like
```
<div>
<div>
<div>A</div>
</div>
<div>
<div><span>B</span></div>
</div>
</div>
```
Is there a way to only select the innermost divs, those that do not contain any other divs? Notice that div B does have descendants, but no other divs.
**Clarifi... | 2015/03/04 | [
"https://Stackoverflow.com/questions/28862708",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/256361/"
] | >
> Is there a way to only select the innermost divs, those that do not contain any other divs?
>
>
>
You could combine the [`:not()`](http://api.jquery.com/not-selector/)/[`:has()`](http://api.jquery.com/has-selector/) selectors in order to select the innermost `div` elements that don't contain other `div` elemen... | Can do something like:
```
$('div').not(':has(div)').css('color','red')
```
explanation is ambiguous though so not 100% clear that this is expected result
`**[DEMO](http://jsfiddle.net/m8t9Ljsp/)**` |
58,569,543 | This question is about my understanding of what kind of material design I should use so that I can implement something below in iOS. Please find a image of what we have in Android,
<https://www.filemail.com/d/jezaeiintbbjihn>
We call our location API every 10 secs which moves the icon. When the user clicks on the ico... | 2019/10/26 | [
"https://Stackoverflow.com/questions/58569543",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5738609/"
] | Google themselves has been open-sourcing the components they’ve used to build Material Design-powered apps on iOS. If you wish to have the almost same feel that you have in your android application you can try using the google's open sourced material components for iOS. You can refer the link to know more.
<https://ma... | You can check the following also:
<https://github.com/amr-abdelfattah/iOS-OptionMenu>
I have built it based on:
<https://material.io/develop/ios/components/bottom-sheet/>
It’s for easily and flexible creation of Material Bottom Sheet. |
26,770,307 | I am trying to create an app that will play some audio files. I was hoping to stream the audio from a web server, but so far am placing an mp3 directly into the project as I don't know how to link to http urls.
I have created a stop button and my understanding is that if you press stop and then play again, the mp3 fil... | 2014/11/06 | [
"https://Stackoverflow.com/questions/26770307",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3934210/"
] | ```
Write the code like this, when you click on the pause button the audio stopped then click on the play button the audio will resumed where the audio stopped.
- (void)viewDidLoad {
[super viewDidLoad];
// Do any additional setup after loading the view, typically from a nib.
NSURL *songU... | @user3934210
Take a array in .h file and write protocol delegate for Player
"AVAudioPlayerDelegate>"
```
NSMutableArray *songsArray;
```
in .m files
```
Add all the .mp3 songs to the array in viewDidLoad
songsArray = [[NSMutableArray alloc]initWithObjects:@“A”,@“B”,@“C”,nil]; //replace your files
then take on... |
18,343,955 | I have noticed similar repetition and trying to work around using a single for loop for this if I can to minimize the code length:
I wouldn't need to use a switch case if I can form a loop instead?
1. $returnNo variable starts at 5, each case multiplied by 2 then minus 1.
2. where it shows "$a<=", it starts at 5 and ... | 2013/08/20 | [
"https://Stackoverflow.com/questions/18343955",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2447836/"
] | I'll use the first two cases as an example:
```
switch ($max) {
case 80:
$returnNO = 5;
$loopCount = 5;
$winner = 7;
$thirdWinner = 8;
break;
case 160:
$returnNO = 9;
$loopCount = 13;
$winner = 15;
$thirdWinner = 16;
break;
...
}
... | If I understood well, here is an alternative solution which I think would work for all cases you specified, with no use of switch case.
```
$div10 = $max / 10;
$maxLoop = $div10 - 3;
$returnNO = $div10 / 2 + 1;
for($a = 1; $a<=$maxLoop; $a++) {
if($matchno == $a || $matchno == ($a+1)){
$matchinfo['matchno... |
597,875 | I am following the experiment in the popular electronics book - "Make: Electronics third edition". However, when replicating one of the experiments mentioned in the book (specifically Experiment 3 "Applying pressure", the part under the subheading "It's the law!", Pg 28), I am stuck.
I believe the experiment is trying... | 2021/12/04 | [
"https://electronics.stackexchange.com/questions/597875",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/301431/"
] | There is nothing wrong that I can see with your setup. I can think of two possibilities:
1. The fuse is blown. You cannot necessarily check it in-circuit because various parts are interconnected internally. If you don’t have another meter maybe try inspecting it visually to see if the element is intact.
2. You have a ... | Simplify. Get rid of the breadboard.
Jumper between the battery + and one end of the resistor. Another jumper from the other end of the resistor to the DMM. Finally, from the other DMM input to the battery -. |
597,875 | I am following the experiment in the popular electronics book - "Make: Electronics third edition". However, when replicating one of the experiments mentioned in the book (specifically Experiment 3 "Applying pressure", the part under the subheading "It's the law!", Pg 28), I am stuck.
I believe the experiment is trying... | 2021/12/04 | [
"https://electronics.stackexchange.com/questions/597875",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/301431/"
] | There is nothing wrong that I can see with your setup. I can think of two possibilities:
1. The fuse is blown. You cannot necessarily check it in-circuit because various parts are interconnected internally. If you don’t have another meter maybe try inspecting it visually to see if the element is intact.
2. You have a ... | Switch your multimeter to amps (not mA to protect the meter) and directly short a 9V alkaline through it. If the meter still shows nothing, and not even a teensy little spark is seen (internal resistance of the battery will limit current), it's the meter. |
597,875 | I am following the experiment in the popular electronics book - "Make: Electronics third edition". However, when replicating one of the experiments mentioned in the book (specifically Experiment 3 "Applying pressure", the part under the subheading "It's the law!", Pg 28), I am stuck.
I believe the experiment is trying... | 2021/12/04 | [
"https://electronics.stackexchange.com/questions/597875",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/301431/"
] | There is nothing wrong that I can see with your setup. I can think of two possibilities:
1. The fuse is blown. You cannot necessarily check it in-circuit because various parts are interconnected internally. If you don’t have another meter maybe try inspecting it visually to see if the element is intact.
2. You have a ... | Try adding an LED in series to the circuit (I see some in the corner of your picture!) to help verify the connection isn't broken somewhere. I'd recommend using the 470 ohm resistor you mentioned with it instead of the 1k. The longer lead of the LED should be on the positive side of the circuit.
If the bulb lights up ... |
597,875 | I am following the experiment in the popular electronics book - "Make: Electronics third edition". However, when replicating one of the experiments mentioned in the book (specifically Experiment 3 "Applying pressure", the part under the subheading "It's the law!", Pg 28), I am stuck.
I believe the experiment is trying... | 2021/12/04 | [
"https://electronics.stackexchange.com/questions/597875",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/301431/"
] | There is nothing wrong that I can see with your setup. I can think of two possibilities:
1. The fuse is blown. You cannot necessarily check it in-circuit because various parts are interconnected internally. If you don’t have another meter maybe try inspecting it visually to see if the element is intact.
2. You have a ... | Your multimeter is has a design that is prone to blowing fuses. The voltage and ohms input is also the mA input. This means any time in the history of your meter that you may connected to a voltage source and then rotated the switch past the current (amps) measurement selector, your fuse would have blown.
You need to ... |
597,875 | I am following the experiment in the popular electronics book - "Make: Electronics third edition". However, when replicating one of the experiments mentioned in the book (specifically Experiment 3 "Applying pressure", the part under the subheading "It's the law!", Pg 28), I am stuck.
I believe the experiment is trying... | 2021/12/04 | [
"https://electronics.stackexchange.com/questions/597875",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/301431/"
] | There is nothing wrong that I can see with your setup. I can think of two possibilities:
1. The fuse is blown. You cannot necessarily check it in-circuit because various parts are interconnected internally. If you don’t have another meter maybe try inspecting it visually to see if the element is intact.
2. You have a ... | Everything points to a blown fuse, which can easily be replaced. However, if replacing the fuse it does not work, maybe, because the current measuring circuit in the meter is damaged, you can always use the voltmeter part of the meter to measure current (don’t throw it out).
Use a one ohm resistor, or even the 1k you a... |
597,875 | I am following the experiment in the popular electronics book - "Make: Electronics third edition". However, when replicating one of the experiments mentioned in the book (specifically Experiment 3 "Applying pressure", the part under the subheading "It's the law!", Pg 28), I am stuck.
I believe the experiment is trying... | 2021/12/04 | [
"https://electronics.stackexchange.com/questions/597875",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/301431/"
] | Switch your multimeter to amps (not mA to protect the meter) and directly short a 9V alkaline through it. If the meter still shows nothing, and not even a teensy little spark is seen (internal resistance of the battery will limit current), it's the meter. | Simplify. Get rid of the breadboard.
Jumper between the battery + and one end of the resistor. Another jumper from the other end of the resistor to the DMM. Finally, from the other DMM input to the battery -. |
597,875 | I am following the experiment in the popular electronics book - "Make: Electronics third edition". However, when replicating one of the experiments mentioned in the book (specifically Experiment 3 "Applying pressure", the part under the subheading "It's the law!", Pg 28), I am stuck.
I believe the experiment is trying... | 2021/12/04 | [
"https://electronics.stackexchange.com/questions/597875",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/301431/"
] | Try adding an LED in series to the circuit (I see some in the corner of your picture!) to help verify the connection isn't broken somewhere. I'd recommend using the 470 ohm resistor you mentioned with it instead of the 1k. The longer lead of the LED should be on the positive side of the circuit.
If the bulb lights up ... | Simplify. Get rid of the breadboard.
Jumper between the battery + and one end of the resistor. Another jumper from the other end of the resistor to the DMM. Finally, from the other DMM input to the battery -. |
597,875 | I am following the experiment in the popular electronics book - "Make: Electronics third edition". However, when replicating one of the experiments mentioned in the book (specifically Experiment 3 "Applying pressure", the part under the subheading "It's the law!", Pg 28), I am stuck.
I believe the experiment is trying... | 2021/12/04 | [
"https://electronics.stackexchange.com/questions/597875",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/301431/"
] | Your multimeter is has a design that is prone to blowing fuses. The voltage and ohms input is also the mA input. This means any time in the history of your meter that you may connected to a voltage source and then rotated the switch past the current (amps) measurement selector, your fuse would have blown.
You need to ... | Simplify. Get rid of the breadboard.
Jumper between the battery + and one end of the resistor. Another jumper from the other end of the resistor to the DMM. Finally, from the other DMM input to the battery -. |
597,875 | I am following the experiment in the popular electronics book - "Make: Electronics third edition". However, when replicating one of the experiments mentioned in the book (specifically Experiment 3 "Applying pressure", the part under the subheading "It's the law!", Pg 28), I am stuck.
I believe the experiment is trying... | 2021/12/04 | [
"https://electronics.stackexchange.com/questions/597875",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/301431/"
] | Everything points to a blown fuse, which can easily be replaced. However, if replacing the fuse it does not work, maybe, because the current measuring circuit in the meter is damaged, you can always use the voltmeter part of the meter to measure current (don’t throw it out).
Use a one ohm resistor, or even the 1k you a... | Simplify. Get rid of the breadboard.
Jumper between the battery + and one end of the resistor. Another jumper from the other end of the resistor to the DMM. Finally, from the other DMM input to the battery -. |
72,658,664 | Really wired problem. My routing had been configured well and has been checked enough times.
However, page1, page3 and page5 works well.
And page2, page4, page6 don't redirect to themselves.
If I tap redirect button then instead of page2 go to the landing page.
If I write <https://example.com/page2> -> the same: <htt... | 2022/06/17 | [
"https://Stackoverflow.com/questions/72658664",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12623972/"
] | On android studio upper bar
File->settings->tools->emulator->
then check or uncheck -launch in tool window | File -> Settings -> Tools -> Emulator
And disable "Launch in a tool window" |
52,284,067 | Is there a way to authenticate a user with SAML token using firebase as a backend? The company I am working with requires that SAML is used within the authentication system and I am not sure if this is possible with firebase as a backend.
Thanks | 2018/09/11 | [
"https://Stackoverflow.com/questions/52284067",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2037909/"
] | Maybe new GCP service ["Cloud Identity for Customers and Partners"](https://cloud.google.com/identity-cp/) (in beta for now) could help you.
>
> Cloud Identity for Customers and Partners (CICP) provides an identity platform that allows users to authenticate to your applications and services, like multi-tenant SaaS a... | You can now use SAML provider with the new [Cloud Identity platform](https://cloud.google.com/identity-platform/). This platform works in combination with Firebase too.
Check [Thierry's answer](https://stackoverflow.com/a/55322424/209103) for more details.
---
**Old/outdated answer** below:
At the moment there is n... |
10,247,870 | I'm looking for a way to return an array from the database query, but only for the first row. I'd prefer not to use objects..
My current solution:
```
//Gather
$data = $this->db->from('view')->where('alias', $alias)->get()->result_array();
//Collect the first row only
$data = $data[0];
```
Which is pretty ugly to ... | 2012/04/20 | [
"https://Stackoverflow.com/questions/10247870",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1113435/"
] | Use the `row()` method instead:
```
$data = $this->db->from('view')->where('alias', $alias)->get()->row();
```
[Oh, you don't want to use objects. `row_array()` then. But consider objects.] | You can do this:
```
$data = $this->db->from('view')->where('alias', $alias)->get()->row_array();
```
This does the same as minitech's answer, only it returns an array (like you want) instead of an object. |
10,247,870 | I'm looking for a way to return an array from the database query, but only for the first row. I'd prefer not to use objects..
My current solution:
```
//Gather
$data = $this->db->from('view')->where('alias', $alias)->get()->result_array();
//Collect the first row only
$data = $data[0];
```
Which is pretty ugly to ... | 2012/04/20 | [
"https://Stackoverflow.com/questions/10247870",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1113435/"
] | Use the `row()` method instead:
```
$data = $this->db->from('view')->where('alias', $alias)->get()->row();
```
[Oh, you don't want to use objects. `row_array()` then. But consider objects.] | You can use the row\_array() function to grab data from a single row. Specify that row as the parameter.
For example, to get the first row of your result, do this:
```
$this->db->from('view')->where('alias', $alias)->get()->result_array(0);
``` |
10,247,870 | I'm looking for a way to return an array from the database query, but only for the first row. I'd prefer not to use objects..
My current solution:
```
//Gather
$data = $this->db->from('view')->where('alias', $alias)->get()->result_array();
//Collect the first row only
$data = $data[0];
```
Which is pretty ugly to ... | 2012/04/20 | [
"https://Stackoverflow.com/questions/10247870",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1113435/"
] | Use the `row()` method instead:
```
$data = $this->db->from('view')->where('alias', $alias)->get()->row();
```
[Oh, you don't want to use objects. `row_array()` then. But consider objects.] | If you want to get only first row as an array you can use this code too:
```
$data = $this->db->from('view')->where('alias', $alias)->get()->first_row('array');
```
But if you really want to get only 1 result, allways use select('TOP 1 ....') because this method improves your query returning time performance. When y... |
10,247,870 | I'm looking for a way to return an array from the database query, but only for the first row. I'd prefer not to use objects..
My current solution:
```
//Gather
$data = $this->db->from('view')->where('alias', $alias)->get()->result_array();
//Collect the first row only
$data = $data[0];
```
Which is pretty ugly to ... | 2012/04/20 | [
"https://Stackoverflow.com/questions/10247870",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1113435/"
] | You can do this:
```
$data = $this->db->from('view')->where('alias', $alias)->get()->row_array();
```
This does the same as minitech's answer, only it returns an array (like you want) instead of an object. | You can use the row\_array() function to grab data from a single row. Specify that row as the parameter.
For example, to get the first row of your result, do this:
```
$this->db->from('view')->where('alias', $alias)->get()->result_array(0);
``` |
10,247,870 | I'm looking for a way to return an array from the database query, but only for the first row. I'd prefer not to use objects..
My current solution:
```
//Gather
$data = $this->db->from('view')->where('alias', $alias)->get()->result_array();
//Collect the first row only
$data = $data[0];
```
Which is pretty ugly to ... | 2012/04/20 | [
"https://Stackoverflow.com/questions/10247870",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1113435/"
] | You can do this:
```
$data = $this->db->from('view')->where('alias', $alias)->get()->row_array();
```
This does the same as minitech's answer, only it returns an array (like you want) instead of an object. | If you want to get only first row as an array you can use this code too:
```
$data = $this->db->from('view')->where('alias', $alias)->get()->first_row('array');
```
But if you really want to get only 1 result, allways use select('TOP 1 ....') because this method improves your query returning time performance. When y... |
4,236,286 | Peace to all. Studying and trying to get a handle on how to calculate like-minded questions, I came across this [question](https://www.thoughtco.com/speed-of-light-in-miles-per-hour-609319) from the web. I don't understand how exactly it was solved. How were the units canceled out and with what exactly?
>
> ***Soluti... | 2021/08/30 | [
"https://math.stackexchange.com/questions/4236286",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/961761/"
] | Rather than tackling the problem at hand, here is a simpler example. Suppose we start with a speed of 60 mph and want to convert to miles per minute. Since 1 hour is 60 minutes, we have
$$60\text{ mph} = \frac{60\text{ miles}}{1\text{ hour}} = \frac{60\text{ miles}}{60\text{ min}} = 1\text{ mile/min}.$$ Note that we ha... | Notice how some units cancel when the proper terms are multiplied.
$$1\space \frac{m}{s}\approx 2.237\space mph \\
\implies 299792458 \space \frac{m}{s}
\space \times\space 2.237\space \frac{mph}{m}
\space\times\space 1\space h
\space \times\space 3600\space \frac{s}{h}\\
= \,2,414,288,622,766\space mph$$ |
22,297,101 | I am creating column charts using highchart its displaying 0 if all of the fields are 0. I want to display single 0 per category if all data in that particular category is 0 (i.e., total is 0)
Please refer <http://jsfiddle.net/rutup/6hxPU/18/>
```
function createBarChart(source, title, placeHolderId, sideText, xCo... | 2014/03/10 | [
"https://Stackoverflow.com/questions/22297101",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1266399/"
] | If that is enough to pick the middle column, and show a zero above, then something like this would do the trick:
<http://jsfiddle.net/6hxPU/20/>
Of course if you have even number of columns, the zero won't be centered. That case I think the best you can do is to find where to put the zero, based on the column heights... | You can use loop on each point, and remove stackLabel's SVG object. |
57,746,350 | I have an entity (named Parent) with a @OneToOne mapping to a Child entity. Currently defined with FetchType.EAGER, but it doesn't matter to the problem at hand here.
I am trying to perform a query on Parent that does a LEFT JOIN on the Child entity, rendering the FetchType setting useless (supposedly).
However, the q... | 2019/09/01 | [
"https://Stackoverflow.com/questions/57746350",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7732544/"
] | This is underline of first `<a>` tag.
Just apply `text-decoration: none` property to `<a>` tags in this block. | That black line in the underline of `a` tag. To remove it just use `text-decoration: none`, like this:
```css
.mid > a {
text-decoration: none;
}
.mid {
margin-top: 0px;
flex-wrap: wrap;
justify-content: center;
text-align: center;
}
.cfc-container {
display: inline-block;
width: 80%;
pa... |
57,746,350 | I have an entity (named Parent) with a @OneToOne mapping to a Child entity. Currently defined with FetchType.EAGER, but it doesn't matter to the problem at hand here.
I am trying to perform a query on Parent that does a LEFT JOIN on the Child entity, rendering the FetchType setting useless (supposedly).
However, the q... | 2019/09/01 | [
"https://Stackoverflow.com/questions/57746350",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7732544/"
] | This is because of the default behavior of tag - text-decoration,
```
.mid a {
text-decoration: none;
}
```
```css
.mid {
margin-top: 0px;
flex-wrap: wrap;
justify-content: center;
text-align: center;
}
.mid a {
text-decoration: none;
}
.cfc-container {
display: inline-block;
... | This is underline of first `<a>` tag.
Just apply `text-decoration: none` property to `<a>` tags in this block. |
57,746,350 | I have an entity (named Parent) with a @OneToOne mapping to a Child entity. Currently defined with FetchType.EAGER, but it doesn't matter to the problem at hand here.
I am trying to perform a query on Parent that does a LEFT JOIN on the Child entity, rendering the FetchType setting useless (supposedly).
However, the q... | 2019/09/01 | [
"https://Stackoverflow.com/questions/57746350",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7732544/"
] | kindly add below code in your css
```
a:-webkit-any-link
{
text-decoration: none;
}
``` | That black line in the underline of `a` tag. To remove it just use `text-decoration: none`, like this:
```css
.mid > a {
text-decoration: none;
}
.mid {
margin-top: 0px;
flex-wrap: wrap;
justify-content: center;
text-align: center;
}
.cfc-container {
display: inline-block;
width: 80%;
pa... |
57,746,350 | I have an entity (named Parent) with a @OneToOne mapping to a Child entity. Currently defined with FetchType.EAGER, but it doesn't matter to the problem at hand here.
I am trying to perform a query on Parent that does a LEFT JOIN on the Child entity, rendering the FetchType setting useless (supposedly).
However, the q... | 2019/09/01 | [
"https://Stackoverflow.com/questions/57746350",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7732544/"
] | This is because of the default behavior of tag - text-decoration,
```
.mid a {
text-decoration: none;
}
```
```css
.mid {
margin-top: 0px;
flex-wrap: wrap;
justify-content: center;
text-align: center;
}
.mid a {
text-decoration: none;
}
.cfc-container {
display: inline-block;
... | That black line in the underline of `a` tag. To remove it just use `text-decoration: none`, like this:
```css
.mid > a {
text-decoration: none;
}
.mid {
margin-top: 0px;
flex-wrap: wrap;
justify-content: center;
text-align: center;
}
.cfc-container {
display: inline-block;
width: 80%;
pa... |
57,746,350 | I have an entity (named Parent) with a @OneToOne mapping to a Child entity. Currently defined with FetchType.EAGER, but it doesn't matter to the problem at hand here.
I am trying to perform a query on Parent that does a LEFT JOIN on the Child entity, rendering the FetchType setting useless (supposedly).
However, the q... | 2019/09/01 | [
"https://Stackoverflow.com/questions/57746350",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7732544/"
] | This is because of the default behavior of tag - text-decoration,
```
.mid a {
text-decoration: none;
}
```
```css
.mid {
margin-top: 0px;
flex-wrap: wrap;
justify-content: center;
text-align: center;
}
.mid a {
text-decoration: none;
}
.cfc-container {
display: inline-block;
... | kindly add below code in your css
```
a:-webkit-any-link
{
text-decoration: none;
}
``` |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.