Most voted questions
150,413 questions
Sort by count of
-
4
votes2
answers567
viewsTest without "fouling" (adding data) the database
I am having trouble doing integration testing. I test my database functions. My web application does not use any framework database connection and I am unable to do tests without fouling my…
-
4
votes1
answer85
viewsEfficient execution of PHP PDO queries
Is there any performance difference in the codes below? $result = $pdo->query($sql); foreach($result as $reg){ ... } and... foreach($pdo->query($sql) as $reg){ ... } I’ve run some tests, but…
-
4
votes2
answers3727
viewsGreater and lesser number
I need to sort three numbers I can’t use for and neither vectors. I know it’s easy but I can’t do it. My problem is, I can’t keep the highest value. public static void main(String[] args) { Scanner…
-
4
votes1
answer1161
viewsHow to set UTF8 charset?
I have a database that was created using Firebird 1.0, at this time there was no UTF8 charset available, only from version 2.0 was having this possibility, so we left the None charset. Doubts: 1°…
-
4
votes4
answers832
viewsCreate layout for PHP and . NET applications
Work in a public body and we have numerous web applications in PHP and .NET. I’m working on a standard layout so we can maintain visual identity across all systems. Is there any way…
-
4
votes1
answer1041
viewsWhat is the elegant way to read this PHP Object?
I have the Result of a Webservice below, I’m doing a "foreachs" to read each level of the Class, but I think it should have a more elegant way to read and get the values of the object, follows the…
-
4
votes5
answers6065
viewsGet input array value
I need to redeem the input array value that the user clicks, these inputs are dynamic values. HTML/PHP <label> <i class="fa fa-lg fa-times-circle"><input value="<?=$fs_value?>"…
-
4
votes3
answers171
viewsHow to simplify this comparison?
I often fall into the following situation : For example in c#: string variavel= "x"; boolean b = (variavel == "a" || variavel == "d" ||.....|| variavel== "y"); Is there any way to simplify something…
c#asked 8 years, 9 months ago John Diego 1,067 -
4
votes2
answers959
viewsJquery hover function in dynamic elements
Is there any way to use the hover with jQuery in dynamically created selects options. I tried to use the function on() and the live() but it didn’t work out. I tried so: $(document).on('hover',…
-
4
votes1
answer3164
viewsError "There is already an Object named '#TEMP' in the database"
I’m performing a load, using a temporary table on Microsoft SQL Server 2008. SELECT CAMPO1, CAMPO2, CAMPO3, CAMPO4 INTO #TEMP FROM DADOS In the query, I use the following command, to check if the…
sql-serverasked 8 years, 9 months ago WASBOARD 77 -
4
votes1
answer253
viewsDoes the Netbeans Builder GUI Code affect application performance?
Netbeans has a user interface creation tool using the swing, which greatly facilitates the development of desktop applications, however, the tool seems to create numerous lines of code even for…
-
4
votes1
answer1126
viewsFilling out data.frame from another date.frame
I have two data.frames: "a" and "df" a <- data.frame(x=seq(13,37,1),rep(c(1,2,3,4,5),each=5),seq(21,105,21)) colnames(a)<-c("values","date","term") b<-data.frame(x,21,42,63,84,105)…
-
4
votes1
answer904
viewsGrab the image of a Wordpress post from an external file
I have the titles of my last posts, but I also need to search and display the images along with the title. This is a file outside the Wordpress folder, a static page I made in HTML and CSS: <?php…
-
4
votes1
answer84
viewsJPA does not reflect the changed data in the BD manually
I have a Javafx application with Hibernate (JPA). In this application I update a Tableview with the data I search from BD (Mysql). Every time I click for the system to search in the BD some data, it…
-
4
votes1
answer657
viewsRandomized and ascending order query in MYSQL
I have a table where I have the student’s name and his score, I need to pick up 5 random students and display them in ascending order of the score. I tried to do it this way, but he’s just randomly…
-
4
votes1
answer1911
views#if DEBUG always runs, even in release mode
I’m trying to use the directive #if for a given method to be executed only after publication (in release mode). The code is something like #if !DEBUG AlgumMetodo(); #endif I’ve also tried to add the…
-
4
votes4
answers3915
viewsKnowing if there are blanks
Good community! I have the following doubt. How can I alert the user that there are blanks in the field username? This is how I’m validating username now: if (empty($_POST["username"])) { $nameErr =…
phpasked 8 years, 9 months ago David Concha 539 -
4
votes1
answer242
viewsIs testing the interaction with html and Javascript using Jasmine wrong?
Javascript code has some interactions with html like this example: function retornaListaDeItens(argument) { return document.getElementsByClassName(argument); } I use the return of this function to…
-
4
votes1
answer987
viewsConvert a String Arraylist to a Json
I need to convert one ArrayList of String on a JSON. I have a method in which I get a list of apps installed on the mobile device. This method returns me the data in a String Arraylist. I was able…
-
4
votes0
answers545
viewsMaterial design status bar android Delphi-10
Is there any way or some style to change the color of the status bar of the Android smartphone as material current design in Delphi? The image below illustrates what I want: .…
-
4
votes1
answer514
viewsSelect data from two tables to display in one column?
Consider the tables for customer registration : Table Person |ID|NOME|TIPO|EMAIL| Table Person Physical |ID|CPF| Person Juridical Table |ID| CNPJ| inscricao_municipal| inscricao_estadual| My goal is…
-
4
votes2
answers213
viewsErase everything except the smallest one per day
I have a space problem and there are many useless things being stored, but they are useful during the same day (you will understand). Real problem: There are more than 2 million "lines" and this is…
-
4
votes1
answer118
viewsHow to use Google Glass in Android Studio
I’m trying to install Google Glass in my Android Studio, but I’m not getting it. When I create a new project, it does not provide me with the Glass option and informs me that it is not installed. I…
-
4
votes1
answer117
views -
4
votes2
answers4557
viewsHow to compare two arrays and return the difference between them?
I have 2 arrays that come from 2 different banks, one comes from sql server other mysql. The Mysl query returns like this.. array (size=6) 0 => string 'ultimoteste3' (length=12) 1 => string…
-
4
votes1
answer49
viewsWhat is the best way to perform a dependent addition/subtraction operation?
It is common when one is at the beginning to come across this doubt. I have to perform an operation that is dependent on a condition : Example 1 $operacao = 'somar'; $valor1 = 5; $valor2 = 10;…
-
4
votes2
answers216
viewsError in php data return in Ionic
I’m making an Ionic app in which I place the zip in a field and the backend returns me all other data such as state, city, street... But something strange happens, it returns the whole structure of…
-
4
votes1
answer237
views -
4
votes1
answer1222
viewsScanf is not stopping on repeat
I have a loop while which will only end when 0 (zero) is entered. I have a variable which will receive a command option. Inside the loop I own a switch marry where: 0) exits the program (returns to…
-
4
votes2
answers582
viewsPrint two arrays side by side
How to join two arrays being the index of the array 1 follow the index of the array 2. Data for joining: descricao array1= datacol1, datacol2, datacol3, datacol4 array2= collinha1, collinha2,…
-
4
votes1
answer1116
viewshow to pass data to a php function by ajax url?
People try to give me a force around here, I’ve searched and I can’t find an answer that answers me. Come on! I am working with php classes, I would like to pass data from a form through ajax.…
-
4
votes1
answer197
viewsHow to add unpaid installments with SQL?
I have 3 tables faturas, parcelas and pagamentos. Now I need to mount an SQL to count the installments that are not paid. I have tried a SUM(CASE but it didn’t work out. Table structure faturas:…
-
4
votes1
answer578
viewsHandle services with powershell
I created a script to start and stop a service. My intention is to be able to start or stop a service by simply clicking on a desktop shortcut. I created a shortcut for the script and in the…
-
4
votes1
answer1282
viewsRegular expression formatted as internet domain
How to create a regular expression to validate an internet domain? The rules are below: Minimum size 2 and maximum 26 characters; Valid characters are letters from "a" to "z", numbers from "0" to…
-
4
votes2
answers1693
viewsWhy can’t I open the Mongodb interface on port : 28017?
I installed Mongo in the C drive and did some data creation tests and persisted,then consulted and there they were perfectly listed at the prompt. So far so good! I open the browser and type…
-
4
votes1
answer260
viewsPagination hasMany Laravel 5.1
I have the following relationship in my Model Client: public function Usuario(){ return $this->hasMany('SIST\Models\Admin\Usuario', 'id_cliente'); } I pass the customer data through my…
-
4
votes1
answer1321
viewsHow to embed exe in Project Delphi?
Setting: I have a system developed in Delphi 5 and another in Delphi EX8. In Delphi 5 I call the EX8 executable, so far so good, because it would only be an extra program for the user to download…
delphiasked 8 years, 9 months ago Gabriel Rodrigues 15,969 -
4
votes1
answer1993
viewsHow to calculate currency by appearing decimal places in JS?
I have a dynamic calculation to do, without having to click buttons. I did, but the part I don’t know how to make it appear like decimal places, since we’re talking about currency. function…
javascriptasked 8 years, 9 months ago gezer 421 -
4
votes1
answer845
viewsSIGEP WSDL problem
I am at a time with a project of the post office, I had to make a connection with the webservice SIGEP WEB, I found something already in development in, I was using the same and everything OK, from…
-
4
votes2
answers53
viewsDoes using Alternative Syntax change performance?
Use the Alternative syntax for control structures brings huge changes in the amount of code lines of a project, but there is some change in security?…
-
4
votes1
answer5523
viewsProblems returning a large amount of data through WCF
Good Afternoon, I have a web service done in WCF, when I do a query in the bank and return a large amount of records it gives me the following error: An unhandled Exception of type…
-
4
votes1
answer1369
viewsPDF Data Import in PHP
It may be a stupid question, but I still have to ask: You can import data from a file in pdf in the php and save in bank mysql?
-
4
votes1
answer715
viewsFile comparison
I need to compare files from different directories and show the differences. But I don’t want to list the name of the files, I just want you to make a comparison of the directories and show the…
-
4
votes1
answer108
viewsImprove rating script (star rating)
There’s a way to improve this code ? <?php if ($calculation >= 5) { for ($i=1;$i<=5;$i++) { echo '<img src="'.$linkSite.'/img/star1_16x16.png"> '; } } elseif ($calculation >=3…
phpasked 8 years, 9 months ago William Alvares 384 -
4
votes1
answer976
viewsHow do I make an application available only on my wireless network?
I’m developing an app, and I want it to only be available to devices connected to my Wi-Fi network. I can even leave running on my personal computer and access via ip, something like…
-
4
votes1
answer9720
viewsHow to list folder files on the network
Context: Sometimes every day I need to gather information from folders on the network, where it has several subfolders and files. Need: I need to gather that information faster, so I thought put a .…
-
4
votes0
answers102
viewsCreate an array/Arrays based on a TXT file
I am new to using the Fortran/95 language and want to extract some data from a txt file (http://1drv.ms/20gSNKb), are flow data available in the Hidroweb portal. Whereas they are separated by ";" as…
-
4
votes1
answer90
viewsQuery displaying less result than actually exists in export
I rode a query with a list resulting from a selection of checkbox made by the user, the list is with the correct values, as selected, but when checking the content of the result after consultation…
phpasked 8 years, 9 months ago adventistapr 5,498 -
4
votes1
answer986
viewsHow to create runtime formulas in C#?
There are many advantages when things change for the better, so were the changes from the Clipper to Delphi and C#, actually only in the visual part. There was in the Clipper a fantastic feature…
-
4
votes3
answers19347
viewsHow to align text to the right in a list
I’m trying to make a change to a code I have and what seemed relatively easy to me became a difficulty, what I have is this: <div class="top-bar"> <div class="container"> <div…
cssasked 8 years, 9 months ago adventistapr 5,498