Posts by Claudio Lopes • 380 points
13 posts
-
2
votes2
answers195
viewsA: What is the logic behind the switch case in Javascript?
That’s how it works: The commutator expression is evaluated once. The expression value is compared with the values of each case. If there is a match, the associated code block will be executed. If…
-
1
votes1
answer202
viewsA: Error run UPDATE SQL Server
The problem is in Subquery, only performs select field1, field2, etc. You do not need to use Select because the GETDATE() function can be invoked without problem. SET EstTarTitulo =…
-
3
votes2
answers1339
viewsA: Remove first element from a simple chained list
When passing by reference, you do not need to return to the List. void deletefirst (struct Lista **head) { struct Lista *tmp = *head; if (tmp == NULL) return; *head = tmp->next; free (tmp); }…
-
1
votes1
answer540
viewsA: Routine to clear checkbox from listview C#
Change Checkeditems to Items private void limpacheck() { foreach (ListViewItem item in lsvRecebeGrupoLayout.Items) { item.Checked = false; } }
c#answered Claudio Lopes 380 -
8
votes1
answer221
viewsA: What is a T-SQL query?
Transact-SQL, abbreviated as T-SQL is owned by Microsoft and Sybase for the SQL extension. What is a T-SQL query? One query of SQL adapted for SQL Server. How it differs from a normal query? Control…
-
1
votes3
answers1241
viewsA: Statement Where comparing Date(type date) variable with current date
Converts monitoring.datetime and sysdate to date and in the same notation. SELECT inst_name, dateTime FROM monitoracao, gv$sqlarea sqla WHERE TO_DATE(monitoracao.DATETIME, 'DD-MM-YYYY') =…
-
0
votes1
answer518
viewsA: Files For Structs/C Pointers
I don’t currently have a C compiler, but from what I saw, the problem was how you were accessing the struct. When Random variables appear it means that you were accessing something other than your…
-
0
votes2
answers61
viewsA: Is it possible to add extra classes to a dll?
The code structure is not the right one, you should have a cpp file (c plus plus/c++) and an h file (header) for each class. Your problem (without seeing the error) would say that this is circular…
-
3
votes2
answers2465
viewsA: 2 decimal places using double
Can use a NumberFormat along with DecimalFormat. As for the validation, you only want to validate two values, but in the condition you had the three values to be validated. So I removed the…
-
0
votes5
answers988
viewsA: Error Split by 0
Change the code piece for this: def calculo(operacao, x, y) if operacao == "Adição" return resultado = x + y elsif operacao == "Subtração" return resultado = x - y elsif operacao == "Multiplicação"…
-
2
votes3
answers13919
viewsA: List folders and subfolders cmd
Updated - when using Sort set as desired : dir /a:d /s /b | sort
cmdanswered Claudio Lopes 380 -
0
votes2
answers107
viewsA: SQL result in columns
Here I have found several examples of what you are looking to do. I think the simplest is using the LISTAGG function, but groups all the information in one column. Check the link if this is not what…
-
0
votes2
answers349
viewsA: Java code help (Beginner)
I saw the question and I don’t think anyone noticed that there were no builders for the Employee class. Getters and Setters are also useful and good practices for assigning the value of variables…
javaanswered Claudio Lopes 380