My Filter
   28 tags on

My Filter

  • All Sites
  • Arqade

0 answers

Performance issue with stored procedure

I have a stored procedure that uses the while loop temp table and cursor by which I gets the aging balance of customer, however my SP is working fine but I have some performance concerns as its take ...

3 answers

Reuse results of SELECT query inside a stored procedure

This is probably a very simple question, but my attempts to search for an answer are thwarted by Google finding answers showing how to reuse a query by making a stored procedure instead. I want to ...

2 answers

Can this query about finding missing keys be improved? (either SQL or LINQ)

I am developing a ASP.NET MVC website and is looking a way to improve this routine. It can be improved either at LINQ level or SQL Server level. I hope at best we can do it within one query call. ...

2 answers | 4 mins ago by DatVM on Stack Overflow stackoverflow.com
2 answers

Update Value Based On Value In Another Table

I am looking to modify the value of a column on one table based on the condition of the value of a column of another table. I am using the code: UPDATE ORDERDETAIL SET ORDERDETAIL.PRODUCTID = ...

2 answers | 7 mins ago by Matt Johnson on Stack Overflow stackoverflow.com
0 answers

Grid view via DatePicker

I'm creating an online reservation. My question is how to view the reservations or the save reservations in grid view by selecting the date in date picker. Example: I select a date in date picker ...

1 answer

Create User in SQL Server database

I want to create a user in the database. And I am using this stored procedure to create it: CREATE PROCEDURE uspCreateUser @Name varchar(50) AS BEGIN CREATE USER [@Name] WITHOUT LOGIN ...

1 answer

Need query to get function execution stats in SQL Server 2008 R2

Like below query, is there any query which can return the execution status of a function in SQL server using sys.dm_exec_? SELECT TOP 1 d.object_id, d.database_id, ...

3 answers

SQL: How can I add to a table without some duplicates?

So I am currently trying to take one table and add it into another table but for some reason it is not working the way I want it to. There are three columns in both the tables and I only want to add ...

2 answers

Running SQL job: The login is from an untrusted domain and cannot be used with Windows authentication

I have two databases in different servers (server1 , server2) server1: Login : login1 / password :123 /member of sysadmin (user user1,password:pass) server2 : Login :login1 / password :123 ...

1 answer

Remove duplicate product with lower price using mysql query

I have many duplicate products that I need to delete. Is there a query to delete these "Duplicates" with the "lower price" and/or "Same Price" an just keep 1 of each product? The duplicates have ...

1 answers | 13 mins ago by user1703803 on Stack Overflow stackoverflow.com
0 answers

Headers and footers for Crystal Reports

I have three tables: Employee [EMPNAME, EMPID] ProductList [ProductName, ProductCode] Orders [EMPNAME, ProductCode, ProductName, DeliveryDate, OrderDate, TOTAMT] I am trying to ...

2 answers

How to insert seven kind of ids in a column to all values

I have column data. I need to insert ids in another column. Total i have 7 ids. For first 7 values i have to insert these ids and next 7 values, i have to insert same ids and so on.. Can any one ...

1 answer

Calculating the distance between two location coordinates fetching from SQL server

I am creating an android application where it should fetch the data from sql table. In my sql table I have latitude and longitude coordinates stored in it. And i am able to pass current location co ...

0 answers

SQL command to convert all tags in lowercase?

I'm looking for a SQL query command to convert every single tag in every post ever used to be converted into lowercase.

1 answer

How not to mess up a customers SQL database?

Next week I will create some simple select queries for PowerBI for a new customer who wants to have more insight in his business. Until now I have only done this for our own company. I am afraid that ...

1 answer

Verificar se o SQL Server está instalado C#

Estou a finalizar uma aplicação em C# que contém uma database em SQL Server. Como posso saber se o user tem o SQL Server 2012 Express Local DB instalado? É possível verificar via registry em x86 e ...

1 answer

Tweaking Stored Procedure for High Performance across 300,000+ records

I am trying to build a T-SQL stored procedure for use with a jQuery DataTables front-end API. The front-end UI provides the calling procedure with the orderby, filter, display starting row, and ...

1 answer

How do I grant sql permission to an object in a different schema as dbo?

This GRANT EXECUTE ON OBJECT::[test].[someTable] TO [MyUser] AS [dbo]; fails with error Msg 15151, Level 16, State 1, Line 1 Cannot find the object 'someTable', because it does not exist or you ...

1 answer

Check if SQL Server is installed C#

I'm finishing a application in C# which contains a SQL Server database. How can I check if the user has SQL Server 2012 Express Local DB installed? Is it possible to check via registry both on x86, ...

1 answers | 35 mins ago by Chirag Geiantilal on Stack Overflow stackoverflow.com
1 answer

Native way of performing this hours of operation query in PostgreSQL

I'm in the RoR stack and I had to write some actual SQL to complete this query for all records that are "open", meaning that the current time is within the specified hours of operation. In the ...

1 answer

Issue ending receipt (String) to Database in C#

I am trying to add a receipt of string type into my SQL Server database from my C# program but I get an exception: An unhandled exception of type 'System.Data.SqlClient.SqlException' occurred in ...

1 answers | 42 mins ago by Chua Bing Quan on Stack Overflow stackoverflow.com
0 answers

Eloquent methods to calculate the average rent of apartments

I am working on a Laravel 5.1 website where I am counting the average rent of apartments in a specific area. Besides of that I want to get the average rent by amount of rooms in the apartment. The ...

0 answers

Como percorrer linhas de um SELECT em uma STORED PROCEDURE no SQL Server?

Sem ser com a utilização de CURSOR e WHILE no SQL Server, que outras formas seriam possível percorrer as linhas de resultado de um SELECT em uma STORED PROCEDURE?

0 answers

SQL Server restore differential without original full backup

Here is the situation: I had a full backup, and a differential backup. I have restored the full backup into the database. But accidentally lost that backup file. Now I would like to apply the ...

1 answer

Conditional count using CASE WHEN

I have table like below CID ITEM FLAG C_1 ITEM_1 0 C_1 ITEM_2 1 C_1 ITEM_2 1 C_1 ITEM_2 0 C_2 ITEM_2 0 C_3 ITEM_2 1 C_3 ITEM_2 1 C_3 ITEM_3 1 and I want to produce table like CID ...

1 answers | 54 mins ago by user3682096 on Stack Overflow stackoverflow.com
12 answers

How do I dump the data of some SQLite3 tables?

How do I dump the data, and only the data, not the schema, of some SQLite3 tables of a database (not all the tables)? The dump should be in SQL format, as it should be easily re-entered into the ...

12 answers | 55 mins ago by Pablo on Stack Overflow stackoverflow.com
0 answers

Different SQL Datasource on Dropdownlist Selected Index Change

I have a Grid view and I want to use Two different Sql DataSources on Selecting different values from DropDownList i.e. On Selected Index Change. Please help me How should I implement that??? I don't ...

6 answers

Fast way to discover the row count of a table

I want to do some statistical analysis in a table in my database. First, I need to know the number of rows in that table, if the total count is greather than some predefined constant, I will use the ...

1 answer

How to combine two query in single query in mysql byusing subquery or inner query

select sub.sub_product_image_path, sub.sub_product_id from `portal_products(sub category)` sub , `portal_products(main category)`main where sub.product_id=main.product_id ; select ...

1 answers | 1 hour ago by Nilesh T. Kashid on Stack Overflow stackoverflow.com
1 answer

Sparql query to find football clubs in Spain and their stadiums

I would like to retrieve football clubs in Spain and their stadiums.Below is the query that I have written for retrieving clubs , but can not retrieve with appropriate stadiums.Here is my code ...

1 answers | 1 hour ago by Programmer on Stack Overflow stackoverflow.com
15 30 50 per page
1 2 3