All Questions

1
answer

Query to sort by two dates Mysql

I have my table tbl_noticias with two dates of type date : data_criacao_noticia and data_atualizada_noticia . The purpose is for the listing to be sorted as follows: If data_atualizada_noticia is different...
asked on 26.01.2015 / 19:00
2
answers

Map method does not work as expected

I'm studying Ruby (without Rails, for now). And I have the following scenario: agenda.rb require 'set' class Agenda def initialize @contatos = Set.new end def contatos @contatos.to_a end def query_...
asked on 10.02.2015 / 18:42
1
answer

Count in two tables

I'm having trouble counting neighborhood items. I need to list all of the neighborhoods in City X and show the available cars and motorcycles items. In the example I just used a city for easy illustration. I used group by and left join...
asked on 31.01.2015 / 22:38
2
answers

Show session time remaining

I'm working with JSP and Servlet. I want to display on the jsp page the time remaining to expire the session I set in my web.xml: <session-config> <session-timeout>30</session-timeout> </session-config> Has anyon...
asked on 04.02.2015 / 20:38
1
answer

How to display multiple values of a JSON in PHP

How can I display all the values of a JSON in PHP ?? I'll give you an example, I use the Code below to request the JSON $json_file = file_get_contents("http://backpack.tf/api/IGetUsers/v3/?steamids=76561198012598620"); $json_str = j...
asked on 04.02.2015 / 19:00
2
answers

App style in pure CSS3 breaks while running on Android

I'm making an app with Cordova + Sammy.js and pure CSS3. I can make the app perfectly responsive and with all styles working on Chrome and FireFox . It turns out that when I build the cork and open APK in Genymotion (running Android 4.4+...
asked on 15.02.2015 / 02:57
2
answers

SQL Grouping by name, date and quantity per month

I am not able to group this resulting per month (FIELD "PP.PAPELETA_DATA"). Type the amount (count (PD.PessoaId) as Total) separated per month! Could someone give me a help? Use SQL SERVER 2012. SELECT PE2.PessoaNome, count(PD.PessoaId) as To...
asked on 14.02.2015 / 23:54
5
answers

How to create composite key with Entity Framework 6

I have my base model that all classes inherit from it: public class Base { public int Id {get;set;} public int ClienteId {get;set;} } And an example model: public class Grupo: Base { public string Nome {get;set;} } And a subg...
asked on 12.02.2015 / 13:50
1
answer

In Django why is the is_authenticated method always returns True?

I saw that in the documentation it indicates the is_authenticated method as being responsible for telling the templates if there is a logged in user. I also saw in the method code that it contains only the following: def is_authenticate...
asked on 19.02.2015 / 01:09
1
answer

How to fix serrated fonts in chrome?

I have a problem with Google Chrome. I do not know if it's CSS, but the fonts declared in CSS are getting serrated mostly in Chrome. I have already tried the following anti-alarming properties: -webkit-font-smoothing; font-smooth; text-stroke;...
asked on 13.02.2015 / 14:31