date
stringlengths
10
10
nb_tokens
int64
60
629k
text_size
int64
234
1.02M
content
stringlengths
234
1.02M
2018/03/12
1,208
3,906
<issue_start>username_0: I first want to show a **question** then its respective **answers** from two different tables. My code is as follows: ``` $reg = $_SESSION['reg']; $sql1="select users.reg,questions.question,questions.id from users,questions where users.reg=questions.reg and questio...
2018/03/12
6,083
21,688
<issue_start>username_0: I am using spring cloud to configure microservices. I used Jhipster to generate the application. I have three applications JHipster-Registry, Gateway, and admin application All three application are deployed on separate machine/ip-address. admin and gateway are configured with registry. Follo...
2018/03/12
404
1,312
<issue_start>username_0: for the first problem of my homework it involves printing out a string of asterisks via a void method using recursion. The number of asterisks printed is based on 2 to the power of n (with n being the parameter of the method). i.e. print(1) prints out "\*\*" print(2) prints out "\*\*\*\*" e...
2018/03/12
1,830
4,695
<issue_start>username_0: I would like to explore a dictionary with multiple values For example, function\_test(groups) would give me as a result: ``` {153: {’sport’, ’travaux manuels’, ’cinephiles’, ’cuisine’}, 538: {’sport’}, 147: {’cinephiles’, ’cuisine’}, 802: {’sport’, ’travaux manuels’, ’cinephiles’, ’cuisine’}, ...
2018/03/12
1,306
4,534
<issue_start>username_0: I was trying to read from a file in vs17. But here system("pause") isn't working. The console window here just pops up and vanishes. The input.txt file contains only one integer. ``` #include #include #include #pragma warning(disable:4996) using namespace std; int main() { freopen("input.txt"...
2018/03/12
1,279
4,792
<issue_start>username_0: I'm building a Vue web application with Vue Router and Vuex, using vue-cli for scaffolding. The majority of the project structure is very simple, with one main store and simple routing: ``` project/ ├── src/ │ ├── components/ │ │ ├── Hosting/ │ │ └── Website/ │ ├── router/ │ ├─...
2018/03/12
775
2,613
<issue_start>username_0: Here is the screenshot of my issue: [![enter image description here](https://i.stack.imgur.com/X5eRe.jpg)](https://i.stack.imgur.com/X5eRe.jpg)<issue_comment>username_1: I've done this like following code. ``` func scrollViewDidScroll(scrollView: UIScrollView) { if currentIndex == 0 && scroll...
2018/03/12
2,763
10,154
<issue_start>username_0: The following code uses a struct with generic type. While its implementation is only valid for the given trait bound, the struct can be defined with or without the same bound. The struct's fields are private so no other code could create an instance anyway. ``` trait Trait { fn foo(&self);...
2018/03/12
917
2,708
<issue_start>username_0: I am trying to train word embeddings(word2vec) on my own dataset using gensim library. `model = Word2Vec(sentences=alp[:20],size=100, window=6, min_count=5)` where alp is a list of list containing tokens of individual sentences in my corpus. I get the following error whenever I try to train t...
2018/03/12
1,208
3,542
<issue_start>username_0: I'm trying to combine two files at certain locations using `awk`/`sed`/`forloop`/`foreach`... whichever is the most simple. First, I have file 1 which has ... ``` # # > # # > ``` etc.. And in my second file, I have just numbers (as many numbers as >'s in the other file)....
2018/03/12
1,111
3,262
<issue_start>username_0: I tried this one, but not working ``` @Html.EditorFor(model => model.discount, new { htmlAttributes = new { @class = "form-control", @type = "number", @step = "0.01", @min = "1", @max = "99999" } }) ```<issue_comment>username_1: Let's consider `file1` and `file2` that we need to merge with y...
2018/03/12
1,182
4,667
<issue_start>username_0: I am currently reading *cracking the coding interview* and looking at questions on *leetcode* and have encountered the same confusion in both places. Specifically with LinkedList problems, which often involve using nodes and creating custom class implementations of Linked Lists. Now I understan...
2018/03/12
962
2,601
<issue_start>username_0: for example, csv file is as below ,(1,2,3) is header! ``` 1,2,3 0,0,0 ``` I read csv file using pd.read\_csv and print ``` import pandas as pd df = pd.read_csv('./test.csv') print(df[1]) ``` it occur error `key error:1` it seems like that `read_csv` parse header as string.. is there any...
2018/03/12
1,360
4,755
<issue_start>username_0: I am trying to determine commits introduced to parent branch due to a merge using merge id.<issue_comment>username_1: You can checkout the branch and use git log to view the commits and the commit Id in the branch. `git log -n10 --oneline` will give you the history of previous 10 commits in th...
2018/03/12
1,611
5,763
<issue_start>username_0: My requirement is on phase change I have to construct method names and call the methods and subsequent methods also,here I am able to construct method name but it is as String and not able to call the method. I have followed some of the suggestion given but I couldn't achieve. Please help. ```...
2018/03/12
536
1,764
<issue_start>username_0: I'm new here as well as new to coding. I got the piece of code and wanted to check if it word work. It pretty simple but since I'm new at this i'm having a lot of issues. I keep getting some random numbers when I try to output the array after calling the function. Would appreciate it if someone...
2018/03/12
1,053
4,748
<issue_start>username_0: I have tried to read similar thread in here [How to make your push notification Open a certain view controller?](https://stackoverflow.com/questions/37753063/how-to-make-your-push-notification-open-a-certain-view-controller) but the information is not complete. I am trying to implement push n...
2018/03/12
743
3,061
<issue_start>username_0: I have a setup where, I have a user\_roles table. Then the administrator, will be able to update these, by adding new role, updating the name of an old role, and lastly delete. ``` ------------------ | id | user_role | | 1 | admin | | 2 | role 1 | | 3 | role 3 | -----------------...
2018/03/12
946
2,848
<issue_start>username_0: I am trying to compare the numbers in the `Reachability Set` column with the numbers in the same row of the `Antecedent Set` column and return the common values in the corresponding cells of the `Intersection Set` column. ***Screenshot:*** [![enter image description here](https://i.stack.imgur...
2018/03/12
1,003
2,866
<issue_start>username_0: I am struggling to do a group by. I have the following list: ``` Date = 10/03 06:40 AM, Val = 10 Date = 10/03 08:55 PM, Val = 5 Date = 11/03 06:40 AM, Val = 5 Date = 11/03 10:50 AM, Val = 9 Date = 11/03 06:40 PM, Val = 14 ``` And I want this list: ``` Date = 10/03, Val = 5...
2018/03/12
957
3,396
<issue_start>username_0: I have a carousel plugin I've created and I need a way to have it run a function that moves the image to the side and brings in the next image. I have this working with navigation arrows but I want to implement a way for it to do this on its own. I'm having trouble finding information on this ...
2018/03/12
534
1,649
<issue_start>username_0: Getting the following error when trying to drop a PostgreSQL DB say "test" ``` postgres=# DROP DATABASE test; ERROR: database "test" is being accessed by other users DETAIL: There is 1 other session using the database. ```<issue_comment>username_1: 1) Run the following command and findout ...
2018/03/12
764
2,723
<issue_start>username_0: I am using Asp.net Identity for token based authentication in my web api application. The problem is I have to **perform some operations after the token is generated** and the user is authenticated **and before the redirection to client** side occurs. I have a login page which uses /token toke...
2018/03/12
525
2,619
<issue_start>username_0: ``` $output = Curl::httpGet("https://bhleh.com/emailstorage", "POST", $params); return $output; ``` this is in my laravel but when ever i try to run this i get an error saying ``` 411. That’s an error. POST requests require a Content-length header. That’s ...
2018/03/12
312
1,009
<issue_start>username_0: If I write same method in two class how interpreter decides which one to execute. ``` class A: method1(): pass class B: method1(): class C(A,B): ``` The class C is inherites both class A and B How do I call Method1() of B class.<issue_comment>username_1: It takes the first insta...
2018/03/12
2,042
10,250
<issue_start>username_0: I have multiple clients registered for my oauth2 auth server. lets say **user1** have roles such as `ROLE_A`, `ROLE_B` for **client1**, same user has roes such as `ROLE_C`, `ROLE_D` for **client2**. now when the user logins either using **client1** or **client2** he is able to see all the four ...
2018/03/12
537
2,011
<issue_start>username_0: I'm having a problem with this query. I want to search in Column4 like example "Ongoing" ``` OleDbDataAdapter da = new OleDbDataAdapter("SELECT Column4 FROM Table WHERE Column1 ='" + textBox1.Text + "', Column2 ='" + textBox2.Text + "'AND Column3 ='" + textBox3.Text + "'" , conn); ```<issue_...
2018/03/12
1,626
5,431
<issue_start>username_0: I was working with ugettext for translation and it was ok , but i dont know what has happened that when i write `django-admin makemessages` on command, it shows this lots of errors: ``` CommandError: errors happened while running msguniq C:\Users\pouyasystem\Desktop\Project\BallBearingProjec...
2018/03/12
1,186
4,556
<issue_start>username_0: I have a function which returns the result of a LINQ statement. Please check piece of code which is throwing an error. ``` var result = devices .Select(d => new { deviceName = d.SystemDevice...
2018/03/12
752
2,535
<issue_start>username_0: I want to extract the length of a dress from a pandas dataframe .The row of that dataframe looks like this : `A-line dress with darting at front and back | Surplice neckline | Long sleeves | About 23" from shoulder to hem | Triacetate/polyester | Dry clean | Imported | Model shown is 5'10" (17...
2018/03/12
884
2,964
<issue_start>username_0: I am trying to create a `SectionList` from a json file named `notes.json`. Basically one object in the `notes` json array will correspond to one `SectionList` entry. I already load the json array in `notesData`. However, when i try to use `notesData` as a source for my `SectionList` i get the e...
2018/03/12
785
2,737
<issue_start>username_0: I'm trying to mock arraylist to verify the add method but I'm getting the message: ``` FAILED: testInit Wanted but not invoked: arrayList.add(); -> at AsyncRestTemplateAutoConfigurationTest.testInit(AsyncRestTemplateAutoConfigurationTest.java:95) Actually, there were zero interactions with thi...
2018/03/12
739
2,467
<issue_start>username_0: I have used responsive jquery data table in my project, i am facing issue in the tabs and popup **Issue list** 1. Responsive jquery data table not working in tabs, working only first tab not on second tab(plus symbol not come in the jquery data table). 2. Bootstrap modal window also responsiv...
2018/03/12
362
1,296
<issue_start>username_0: So, I was searching for ways to round off all the numbers in a numpy array. I found 2 similar functions, numpy.round and numpy.around. Both take seemingly same arguments for a beginner like me. So what is the difference between these two in terms of: * General difference * Speed * Accuracy *...
2018/03/12
665
1,981
<issue_start>username_0: I am trying to take a text file with dates and reformat them. Ex: '1/31/2017' becomes '2017-1-31T:00:00:00Z' Code: ``` with open('dateformat.txt', 'r') as f, open('output2.txt','w') as myfile: data = f.readlines() for line in data: a,b,c = line.split("/") if len(a) < ...
2018/03/12
366
1,445
<issue_start>username_0: Hey guys I've been building my own app for my project in that I created fragments in one of my fragment I need to set a value by clicking a whole linear layout. But when I done that I got error in fragment java code `findViewById` (**cannot resolve method `findViewById(init)`**). I'm stuck at...
2018/03/12
463
1,747
<issue_start>username_0: I'm trying to show what the user inputted on a new modal but it's not showing up. This gets the input (first modal) ``` × ### **Shipping Information** **First Name** **Last Name** **Address** Final Invoice Close ``` This outputs the info ``` × ### **Final Invoice** First...
2018/03/12
819
2,948
<issue_start>username_0: I use woocommerce for wholesale customers who order containers of furniture - normally 40 foot containers with a volume of 68 cubic meters. Is there a way I can show somewhere on the website - maybe in the header area a box with showing the total m3 of products in their basket? I need to show ...
2018/03/12
777
2,777
<issue_start>username_0: I am trying to read NFC tags but the antenna location is different for different mobiles. Users typically don't know where exactly to tap the phone on a tag. So I want to know the location of the NFC antenna within my app. I would then want to notify the user through a some info graphic/image a...
2018/03/12
1,036
3,246
<issue_start>username_0: Oracle database configurations with Django and while migrating the application facing the error > > django.db.migrations.exceptions.MigrationSchemaMissing: Unable to > create the dja ngo\_migrations table (ORA-02000: missing ALWAYS > keyword) > > > ``` application environment 1.window...
2018/03/12
1,228
3,737
<issue_start>username_0: I am working with multiple audio files using Python 3.xx . I have listed all of files' absolute path in a txt file. There are 4 instrument type, Brass, String, Percussion, and Woodwind. The folder structure of the files look like this: ``` F:\Brass\Bass Trombone\BassTrombone.ff.stereo\BassTrom...
2018/03/12
1,025
3,233
<issue_start>username_0: I have a file which I am processing using apache pig. I have a chararray field which I am casting to float, if the value of that field is less than 0, I want to make it integer 0 and if it is greater than zero, then keep the float number as it is. For ex: if number is -1234.56, make it intege...
2018/03/12
1,251
4,144
<issue_start>username_0: We want to transliterate sentences from English to Hindi using google cloud services or any other similar/scaled platform. Currently we started using google translate as its transliterate api is deprecated now. But the issue is, its translating it basis actual sentiments that we don't want: ...
2018/03/12
839
2,343
<issue_start>username_0: Here when I hover on the some image I want to show up this `img-overlay`(Change opacity to 1) only on those images which are not hovered. ```html Bootstrap Example .img-overlay { position: absolute; top: 0; bottom: 0; left: 0; right: 0; height: 210px; width: 100%; opacity: 0; trans...
2018/03/12
1,779
5,255
<issue_start>username_0: This is a repost of my previous request ([Summing up the total based on the random number of inputs of a column](https://stackoverflow.com/questions/49132301/summing-up-the-total-based-on-the-random-number-of-inputs-of-a-column)). But in this question, I had requested to provide the solution wi...
2018/03/12
1,311
4,118
<issue_start>username_0: i am lossing my css in some post in my site. i donot know why? but this does not happen in all posts!. The page I need help with: <https://orhansarikaya.com/index.php/2018/03/05/ihaleakpfeto/><issue_comment>username_1: You can use pandas library in python. It has a functionality for grouping ...
2018/03/12
272
923
<issue_start>username_0: I have a sql query which creates a pivot table. Now I've have executed this query in PHP using 'multiquery' and have converted it into JSON using 'json\_encode'. The JSON data is consists of around 25million records and the format of each record is ``` { timestamp: .....; value 1: .....; valu...
2018/03/12
496
1,866
<issue_start>username_0: I have created a recurssive tree in **Angular2** by go through some references , There i got toggle property in my template and i haven't declared any toggle property or method in used model but still its working , can some one explain how it is working. ``` - {{childNode.dname }} {{childNod...
2018/03/12
1,090
3,723
<issue_start>username_0: i want chart on Results Page. i have a class Results ``` using System; namespace PersonalArea.DAL.Models { public class Result { public string Id { get; set; } public string PatientId { get; set; } public string GameName { get; set; } public stri...
2018/03/12
301
1,357
<issue_start>username_0: Need update the file. I see two ways: first - rewrite file (merge content), second - delete previous file and then create new file with new content. I pass content for all file and its weight around 1 KB. What's the way faster?<issue_comment>username_1: Not sure practically but in theory merge ...
2018/03/12
701
1,789
<issue_start>username_0: We were going through the `Array.prototype.sort()` MDN documentation, where we saw an example:  ``` var array1 = [1, 2,3,4,5,6,7,8,9,10]; array1.sort(); console.log(array1); ``` So the expected output is ``` [1, 2, 3 , 4, 5, 6, 7, 8, 9, 10]  ``` But insted of this we got  ``` [1, 10, 2, ...
2018/03/12
416
1,111
<issue_start>username_0: I have not enough experience in writing rules in `.htaccess`. My site url is like `http://exampletest.com/detail.php?i=my-url` I want to rewrite that url to `http://exampletest.com/my-url` **What I have tried so far:** ``` RewriteEngine on RewriteBase / RewriteCond %{THE_REQUEST} /det...
2018/03/12
1,441
3,873
<issue_start>username_0: I'm using Odoo v11 in windows localhost and I'm still beginner. Recently, i tried to edit posticket and suddenly, the point of sale module stops loading it keep blank page. I have cleared cache for browser and restart odoo service, it worked. But, the receipt not showing and error message ap...
2018/03/12
822
2,992
<issue_start>username_0: I have a requirement where I am running a for loop to incrementally load data from excel to a dictionary followed by passing this to another dictionary. I am using the following code for that: ``` var contr = new Dictionary>(); contr.Add("Contributor" + (j + 1), contributor\_dictionary); item....
2018/03/12
611
1,798
<issue_start>username_0: I am trying to delete empty elements of a list named report info split but keep getting list out of range errors. The list looks similar to this : ``` reportinfosplit = [[1,,g,5,44,f][1,5,4,f,g,,g]] ``` I have found many answers to this for 1d arrays but not 2d. Is there a way to prevent t...
2018/03/12
1,101
3,840
<issue_start>username_0: As I understand the scope of `const` is curly braces (block). However, when I run the following code in browser (FF) it doesn't give any error. Is the following JS code right? Please, explain. ``` { const Foo = "foo"; } { Foo = null; } ```<issue_comment>username_1: You will not get e...
2018/03/12
662
2,309
<issue_start>username_0: I'm little wonder please help me out. My query is :- `Invoice::join('orders', 'orders.invoice_id', '=', 'invoices.id')->groupBy('invoices.id')->get();` > > Then I have got an error: Syntax error or access violation: 1055 'invoices.reference\_number' isn't in GROUP BY > > > When I updated...
2018/03/12
761
2,818
<issue_start>username_0: I need to use a tenant (directory tenant) name in my ARM templates (especially when creating Web Apps). [![enter image description here](https://i.stack.imgur.com/Yx2jC.png)](https://i.stack.imgur.com/Yx2jC.png) It is possible to get subscription name using `subscription().displayName` howev...
2018/03/12
1,111
4,041
<issue_start>username_0: I am facing a critical problem in angular I have the following arrays ``` dataArray (3) [21, 21, 23] ``` and the below is actual Data from API ``` ViewData = [ { "id":5, "name":"Private", "description":"", }, { "id":7, "...
2018/03/12
1,661
5,945
<issue_start>username_0: Consider a scenario where I am displaying a START and END YEARs in a `p-dataTable` column. Here is the column code snippet: ``` {{record.startYear}} - {{record.endYear}} ``` Which displays as: ``` |--------------| | ActivePeriod | |--------------| |2015 - 2017 | |--------------| |2012...
2018/03/12
1,105
3,475
<issue_start>username_0: `Datepicker` is an option for user easy to pick the date to fill the form. In coldfusion, there is a fill form that need to use `datepicker` and after user selected the date and fill the form with format yyyy/mm/dd by default format which is MySql can read. If i change into dd/mm/yyyy and click...
2018/03/12
898
3,913
<issue_start>username_0: I am running a Qualys scan on a Windows EC2 instance and it reports some vulnerabilities. One of them is "SSL Certificate - Subject Common Name Does Not Match Server FQDN". Solution for this, as recommended by Qualys, is to "Please install a server certificate whose Subject commonName or subje...
2018/03/12
895
3,772
<issue_start>username_0: My application is behind a corporate firewall and proxy. I am able to add new packages but somehow I cannot update the catalog. Probably because websockets are not allowed through the firewall. Is there a method to manually get the latest catalog? The proxy variables HTTPS\_PROXY and HTTP\_PRO...
2018/03/12
1,000
3,897
<issue_start>username_0: I am trying to create a time-plot and therefore I have to use date-data from excel. The data is in the first column of my excelsheet and therefore I use the following code: ``` import xlrd import numpy as np import matplotlib.pyplot as plt import datetime #Define xlsfiles wb = xlrd.open_workb...
2018/03/12
249
827
<issue_start>username_0: I try to change the `preload` type. First I set `preload` to `none` in HTML. Then I try to change it via jQuery: ``` //script var video_section = $('video'); video_section.attr('preload','auto'); ``` But with this code it doesn’t change the `preload` value from `none` to `auto`.<issue_com...
2018/03/12
287
1,198
<issue_start>username_0: In my react JS web application, I use the error boundary to catch errors in the component tree using the componentDidCatch(error, info) function. But the error information (info.componentStack) which I receive in the development server and production(build) server are totally different. The de...
2018/03/12
355
1,209
<issue_start>username_0: If I use ``` request.get(imageUrl).pipe(resposne) ``` then, does it return response with all data received from `request.get()` including headers and all the other data ?<issue_comment>username_1: You will use pipe when you want to stream a response. For example ``` request('http://google...
2018/03/12
449
1,514
<issue_start>username_0: i want to get data status wise as shown in my query, ``` select Zipcode, (CASE pobox WHEN 1 THEN 'Available' WHEN 2 THEN 'Reserved' WHEN 3 THEN 'Assigned' WHEN 4 THEN 'Closed' END) as ' Status' from custom_pobox where pobox=@Status ``` Suppose @status = 0 or 1...
2018/03/12
1,137
4,508
<issue_start>username_0: This question has come up quite a few times on here, I know, but none of the solutions have worked for me. So, I'm making a call to the iTunes API with a `fetch` request, based on user input in a React app. The initial call/submit works just fine. However, when I try to do a second search, I ge...
2018/03/12
546
1,874
<issue_start>username_0: Here is my html code: ``` * ![](img/s1.jpg) ``` And Here is my Javascript code: ``` $(document).ready(function(){ $('.slider').slider(); }); ``` Slider works perfectly but the height is 400px by default. How can I change it to 300px? EDIT: Changing image size doesn't change the he...
2018/03/12
610
2,191
<issue_start>username_0: ``` writeln(is(Tuple!(string, int) == struct)); // true ``` What is real user case when I should use `Tuple` instead of `struct`?<issue_comment>username_1: `Tuple` is mostly for convenience as it's often shorter to write `tuple(0, "bar")` than defining the struct. There are a few use cases w...
2018/03/12
493
1,958
<issue_start>username_0: How to validate specific attribute using `ActiveModel::EachValidator`. I have written the below snippet of code. This validation will not call on saving or validating object. ``` class EmailValidator < ActiveModel::EachValidator def validate_each(record,attribute,value) # Logic to ...
2018/03/12
539
2,043
<issue_start>username_0: What is the use of `clone()` here? ``` String[] arg0 = (String[]) this.command.toArray(new String[this.command.size()]); // List command; arg0 = (String[]) arg0.clone(); //Line#2 String[] arg1 = arg0; ``` I am not getting what is line#2 trying to achieve after all? I checked how `clone()`...
2018/03/12
753
2,572
<issue_start>username_0: I have a table where i should validate certain columns. I would like to know if we can write one query that gives all such records instead of validating each column separately. Lets say i have this table. ``` id | x | y | z ----+-----+-----+---- 1 | null| 200 | 2 | 100 | | 42 ...
2018/03/12
246
998
<issue_start>username_0: The following is the code I used to launch qtp, It is working well with IE but not in chrome. What are the changes I shd Make to open through Chrome ``` var qtApp = new ActiveXObject("QuickTest.Application"); qtApp.Launch(); // Start QuickTest qtApp.Visible = true; ```<issue_comme...
2018/03/12
196
818
<issue_start>username_0: i am trying to find out total "**size of each individual collection**" in **Dspace** for my MIS report.<issue_comment>username_1: Microsoft's VBScript is integrated with COM and UFT also exposes a COM interface, this is why you were able to launch UFT from HTML using VBScript. However VBScript ...
2018/03/12
4,189
6,743
<issue_start>username_0: I have an Encrypted Private Key(say,servenc.key) in below format: ``` -----BEGIN ENCRYPTED PRIVATE KEY----- <KEY> -----END ENCRYPTED PRIVATE KEY----- ``` TH above key is in PKCS#8 format. I want to convert it into a RSA Private Key PKCS#1 format The command I use is: ``` openssl rsa -in s...
2018/03/12
888
3,244
<issue_start>username_0: Sorting and pagination is not working after getting the value from backend using Ajax. I am using following version: Angular: 5.2.7 Material: 5.2.4 TypeScript: 2.5.3 **My Code snippet:** ``` ID {{row.id}} Name {{row.name}} export class FormCreatedByMeComponent { cratedForm...
2018/03/12
247
755
<issue_start>username_0: I am trying to build my angular-cli project with AOT ``` ng build --aot ``` but it failes with error > > "FATAL ERROR: CALL\_AND\_RETRY\_LAST Allocation failed - JavaScript heap out of memory" > > > The same thing happens if I build with the `--prod` flag. Any idea?<issue_comment>us...
2018/03/12
227
707
<issue_start>username_0: I am just wondering if use `=` sign operator with sub-query instead of `IN` Is it correct way ? and meet the oracle standard ? **Example** ``` select column_name from my_table_1 where id = (select max(id) from my_table_2); ```<issue_comment>username_1: There is already an issue opened on gi...
2018/03/12
761
2,172
<issue_start>username_0: I want to display the users that have used a value. ``` import pandas as pd user = ['alice', 'bob', 'tim', 'alice'] val = [['a','b','c'],['a'],['c','d'],['a','d']] df = pd.DataFrame({'user': user, 'val': val}) user val 'alice' [a, b, c] 'bob' [a] 'tim' [c, d] 'alice' ...
2018/03/12
919
3,160
<issue_start>username_0: I am trying to choose and display multiple images (approx. 5 images) but for some reason I am only able to select and display a single image at a time. I have tried to implement the below code for displaying multiple images. Please help guys. Thanks in advance. ``` import UIKit import Alamofir...
2018/03/12
835
2,494
<issue_start>username_0: For example ``` set a abc.def.efg.hij.jkl ``` I need string after `def` uptil the next dot (`.`) i.e: `efg` Could you please help me with that? Can I get a regex expression?<issue_comment>username_1: Here's three regex examples in Tcl: ``` set a abc.def.efg.hij.jkl # Get next token after ...
2018/03/12
1,280
4,799
<issue_start>username_0: I'm trying to add some objects to an array if a checkbox is checked. But I can't seem to make it work. What I would like is to add an object depending on the values of the checked checkboxes. I hope you guys can understand it. Let me show you in code : This is the code to check if a checkbox i...
2018/03/12
1,098
3,931
<issue_start>username_0: I have the following input file: ``` xml version="1.0" encoding="UTF-8"? aaa bbb ccc ``` Expected output: ``` xml version="1.0" encoding="UTF-8"? * aaa * bbb * ccc ``` How should the XSLT file look like? I tried the following: ``` xml version="1.0" encoding="UTF-8"? * ``` but...
2018/03/12
1,813
7,930
<issue_start>username_0: I want to apply background color to row of jqGrid row based on value of company attributes, however the basic rowattr is not applying class to rows. Below is the code,have added \*\*\* against the condition. ``` function drawGrid() { $("#grid").jqGrid("GridUnload"); ...
2018/03/12
475
1,686
<issue_start>username_0: I'm generating random numbers between 1-100, and I just want to know if its possible to set a bigger percentage to get some numbers. For example: The range is 1-100, but i want that there will be a 70% chance to get a number between 40-50.<issue_comment>username_1: It is not a computer science ...
2018/03/12
872
2,253
<issue_start>username_0: Here's my data ``` No Body 1 DaTa Analytics 2 2 StackOver 67 ``` Here's my expected output ``` No Body Uppercase Lowercase 1 DaTa Analytics 2 3 10 2 StackOver 67 2 7 ```<issue_comment>username_1: Use [`str.findal...
2018/03/12
1,452
5,078
<issue_start>username_0: I have tried to upload image in multiple folders using following code but i have faced a problem is uploaded image showing black. It's upload successfully in main folder but in thumbnail folder it's showing black. Code ``` $target_dir = "uploads/"; $target_file = $target_dir . basename($_FIL...
2018/03/12
705
2,548
<issue_start>username_0: I am trying to track code coverage for C++ and I would like to specify what functions a particular test covers. I would like to have a macro or template that gives me the mangled name of the function so in the test I can specify which methods are covered and I can match this up with the mangled...
2018/03/12
1,198
4,083
<issue_start>username_0: From my understanding, sqlite's datatype isn't associated to its column but to the data themselves: this practically means that you can insert any data to any column. Is it possible to prohibit such a behaviour? I mean, I want sqlite to raise an error (or at least a warning) when I accidentall...
2018/03/12
823
3,022
<issue_start>username_0: I am trying to feed a table with errors we get from a virtual machine, I use json to read the database outputs from the server. Listing one item is fine but If i want to do it for last 5 items of the database, I would repeat the code again and again which doesn't seem any efficient to me. Copy ...
2018/03/12
948
2,353
<issue_start>username_0: My data set in R looks like the one below, where I have multiple IDs and Years but not always the information for Street, State, and Country. ``` ID Year Street State Country 1 2000 123 Main St CA USA 1 2001 N/A N/A N/A 1 2002 N/A ...
2018/03/12
513
1,980
<issue_start>username_0: The requirement is to display the logged in username and his role in the organization in all the pages at the top right corner. The role can be identified by the permissions he is given. My approach: I thought of creating a user-defined function in `views.py` and call it in each and every oth...
2018/03/12
273
1,002
<issue_start>username_0: I have a script written and have been able to code for buttons that have html but this button that I inspected on this link, doesn't have one. This is the element for the login button. ``` ``` How would I write this line of script to click on this button using selenium & python?<issue_comm...
2018/03/12
269
963
<issue_start>username_0: I'm using AutoIt to parse HTML. I want to get all HTML elements by an attribute's value. Example: ``` The div content XXX The div content of ZZZ ``` The div -element containing the attribute-value pair `data-source="xxx"` should be selected.<issue_comment>username_1: your element has few at...
2018/03/12
707
2,205
<issue_start>username_0: Currently, I am beginning to write the firmware by Verilog for one idea. It is comparing bit by bit between two variables and then using one binary counter to count the number of different bits. For example: I have two variables in verilog A : 8'b0**01**0000**1**; B : 8'b0**10**0000**0**; ...
2018/03/12
371
1,257
<issue_start>username_0: ``` def first_and_last(list_1): new_list = [i for i in list_1 if i ==(list_1[0] or list_1[len(list_1 - 1)])] return new_list ``` after i enter the sequence of numbers, the output stays the same as the original list. I think there would be something wrong with my list comprehension `...
2018/03/12
294
1,097
<issue_start>username_0: I have an application writes the keys into Redis without specifying the expirations for keys. It is not possible changing the application, but I want to configure Redis to keep only the keys for past 24 hours and delete the old keys. HOW?<issue_comment>username_1: You are driving `NUM_ERR` (a ...
2018/03/12
584
1,861
<issue_start>username_0: I have a mysql table, which is as follows: ``` image_id imagename brandname x y 143 00003.jpg Pirelli 147 265 125 00003.jpg Pirelli 500 259 ``` Through mouse clicks I am generating x and y positions on a html canvas which I want to use to...